diff options
Diffstat (limited to 'doc-src')
-rw-r--r-- | doc-src/02-docstyle.css | 41 | ||||
-rw-r--r-- | doc-src/_layout.html | 7 | ||||
-rw-r--r-- | doc-src/_websitelayout.html | 40 | ||||
-rw-r--r-- | doc-src/index.html | 50 | ||||
-rw-r--r-- | doc-src/index.py | 24 | ||||
-rw-r--r-- | doc-src/library.html | 2 | ||||
-rw-r--r-- | doc-src/scripts.html | 2 | ||||
-rw-r--r-- | doc-src/ssl.html | 3 |
8 files changed, 110 insertions, 59 deletions
diff --git a/doc-src/02-docstyle.css b/doc-src/02-docstyle.css index b1a90727..5e45e0e7 100644 --- a/doc-src/02-docstyle.css +++ b/doc-src/02-docstyle.css @@ -1,28 +1,35 @@ -body { - -x-system-font:none; - font-family: Helvetica,Arial,Tahoma,Verdana,Sans-Serif; - color: #555555; - font-size: 1.2em; -} a { color: #3F8ED8; } -#hd { + +#hd.doc { + -x-system-font:none; + font-family: Helvetica,Arial,Tahoma,Verdana,Sans-Serif; + color: #555555; margin: 0; border-bottom: 1px solid #999; + margin-bottom: 1em; } -#hd h1 { +#hd.doc h1 { letter-spacing: 3px; - font-size: 2em; + font-size: 2.5em; line-height: 100%; margin: 0.3em 0; font-weight: normal; } +#hd.doc #nav { + font-size: 1.5em; +} + + #bd { - padding: 20px; + -x-system-font:none; + font-family: Helvetica,Arial,Tahoma,Verdana,Sans-Serif; + font-size: 1.6em; + color: #555555; } #bd h1 { @@ -37,7 +44,7 @@ a { margin-bottom: 5px; } -#ft { +#ft.doc { color: #aaa; border-top: 1px solid #aaa; clear: both; @@ -53,11 +60,10 @@ a { pre { padding: 10px; - background-color: #e0e0e0; margin: 10px; } -ul { +.docindex, .docindex ul { margin-top: 0.1em; margin-bottom: 0; margin-left: 2em; @@ -67,11 +73,6 @@ li a { text-decoration: none; } -#nav { - float: right; - - +.highlight { + font-size: 14px; } - - - diff --git a/doc-src/_layout.html b/doc-src/_layout.html index 6010c95c..b0e68abd 100644 --- a/doc-src/_layout.html +++ b/doc-src/_layout.html @@ -1,6 +1,5 @@ <div id="doc"> - <div style="" id="hd"> - + <div style="" id="hd" class="doc"> <div id="nav"> <!--(block pb)--> <a href="@!urlTo(previous)!@">prev</a> @@ -8,21 +7,19 @@ <!--(block nb)--> <a href="@!urlTo(next)!@">next</a> <!--(end)--> - $!pb if previous else "prev"!$ | <a href="@!urlTo('index.html')!@">index</a> | $!nb if next else "next"!$ </div> $!title!$ - </div> <div id="bd"> <div id="yui-main"> <div style="" class="yui-b">$!body!$</div> </div> </div> - <div style="" id="ft"> + <div style="" id="ft" class="doc"> <p>@!copyright!@</p> </div> </div> diff --git a/doc-src/_websitelayout.html b/doc-src/_websitelayout.html new file mode 100644 index 00000000..309c3de8 --- /dev/null +++ b/doc-src/_websitelayout.html @@ -0,0 +1,40 @@ +<a href="http://github.com/cortesi/mitmproxy"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://d3nwyuy0nl342s.cloudfront.net/img/e6bef7a091f5f3138b8cd40bc3e114258dd68ddf/687474703a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f7265645f6161303030302e706e67" alt="Fork me on GitHub"></a> +<div class="yui-t7" id="doc"> + <div style="" id="hd"> + <h1><a href="@!urlTo("/index.html")!@">mitmproxy</a> </h1> + <div class="HorizontalNavBar"> + <ul> + <li class="inactive"><a href="../index.html">home</a></li> + <li class="active"><a href="index.html">docs</a></li> + <li class="inactive"><a href="../development.html">development</a></li> + </ul> + </div> + <br> + <p>an SSL-capable intercepting proxy</p> + </div> + <div id="bd"> + <div id="yui-main"> + <div style="" class="yui-b"> + + <div id="nav"> + <!--(block pb)--> + <a href="@!urlTo(previous)!@">prev</a> + <!--(end)--> + <!--(block nb)--> + <a href="@!urlTo(next)!@">next</a> + <!--(end)--> + $!pb if previous and not previous.parent.root else "prev"!$ | + <a href="@!urlTo('doc/index.html')!@">index</a> | + $!nb if next and not next.parent.root else "next"!$ + </div> + $!title!$ + $!body!$ + </div> + </div> + </div> + <div style="" id="ft"> + <p>Copyright 2011 Aldo Cortesi</p> + </div> +</div> + +$!ga!$ diff --git a/doc-src/index.html b/doc-src/index.html index dbbee537..b7561350 100644 --- a/doc-src/index.html +++ b/doc-src/index.html @@ -1,26 +1,30 @@ - -* [Introduction](@!urlTo("intro.html")!@) -* [Interception](@!urlTo("interception.html")!@) -* [Client-side replay](@!urlTo("clientreplay.html")!@) -* [Server-side replay](@!urlTo("serverreplay.html")!@) -* [Sticky cookies](@!urlTo("stickycookies.html")!@) -* [Anticache](@!urlTo("anticache.html")!@) -* [Filter expressions](@!urlTo("filters.html")!@) -* [Scripting API](@!urlTo("scripts.html")!@) -* [SSL](@!urlTo("/ssl.html")!@) - * [Firefox](@!urlTo("certinstall/firefox.html")!@) - * [OSX](@!urlTo("certinstall/osx.html")!@) - * [Windows 7](@!urlTo("certinstall/windows7.html")!@) - * [iPhone/iPad](@!urlTo("certinstall/ios.html")!@) -* [libmproxy](@!urlTo("library.html")!@) -* Tutorials - * Client replay: a 30 second example - * Scripting: On-the-fly modifications to HTTP conversations [coming soon] - * Sticky cookies [coming soon] - * Breaking iPhone apps for fun and profit [coming soon] -* [FAQ](@!urlTo("faq.html")!@) -* [Administrivia](@!urlTo("admin.html")!@) - +<ul class="docindex"> + <li><a href="@!urlTo("intro.html")!@">Introduction</a></li> + <li><a href="@!urlTo("interception.html")!@">Interception</a></li> + <li><a href="@!urlTo("clientreplay.html")!@">Client-side replay</a></li> + <li><a href="@!urlTo("serverreplay.html")!@">Server-side replay</a></li> + <li><a href="@!urlTo("stickycookies.html")!@">Sticky cookies</a></li> + <li><a href="@!urlTo("anticache.html")!@">Anticache</a></li> + <li><a href="@!urlTo("filters.html")!@">Filter expressions</a></li> + <li><a href="@!urlTo("scripts.html")!@">Scripting API</a></li> + <li><a href="@!urlTo("ssl.html")!@">SSL</a></li> + <ul> + <li><a href="@!urlTo("certinstall/firefox.html")!@">Firefox</a></li> + <li><a href="@!urlTo("certinstall/osx.html")!@">OSX</a></li> + <li><a href="@!urlTo("certinstall/windows7.html")!@">Windows 7</a></li> + <li><a href="@!urlTo("certinstall/ios.html")!@">iPhone/iPad</a></li> + </ul> + <li><a href="@!urlTo("library.html")!@">libmproxy</a></li> + <li>Tutorials</li> + <ul> + <li> Client replay: a 30 second example [coming soon] </li> + <li> Scripting: On-the-fly modifications to HTTP conversations [coming soon] </li> + <li> Sticky cookies [coming soon] </li> + <li> Breaking iPhone apps for fun and profit [coming soon] </li> + </ul> + <li><a href="@!urlTo("faq.html")!@">FAQ</a></li> + <li><a href="@!urlTo("admin.html")!@">Administrivia</a></li> +</ul> diff --git a/doc-src/index.py b/doc-src/index.py index b6a0caca..0241e2f5 100644 --- a/doc-src/index.py +++ b/doc-src/index.py @@ -5,23 +5,34 @@ import countershape.grok, countershape.template sys.path.insert(0, "..") from libmproxy import filt -this.layout = countershape.Layout("_layout.html") +MITMPROXY_SRC = "~/git/public/mitmproxy" + +if ns.options.website: + ns.title = countershape.template.Template(None, "<h1>@!this.title!@ </h1>") + this.layout = countershape.Layout("_websitelayout.html") +else: + ns.title = countershape.template.Template(None, "<h1> @!docTitle!@ - @!this.title!@ </h1>") + this.layout = countershape.Layout("_layout.html") ns.docTitle = "mitmproxy" this.markup = markup.Markdown() ns.docMaintainer = "Aldo Cortesi" ns.docMaintainerEmail = "aldo@corte.si" ns.copyright = u"\u00a9 mitmproxy project, 2011" -ns.title = countershape.template.Template(None, "<h1> @!docTitle!@ - @!this.title!@ </h1>") ns.index = countershape.widgets.SiblingPageIndex('/index.html', divclass="pageindex") -ns.license = file("../LICENSE").read() -ns.index_contents = file("../README.mkd").read() +def mpath(p): + p = os.path.join(MITMPROXY_SRC, p) + return os.path.expanduser(p) + +ns.license = file(mpath("LICENSE")).read() +ns.index_contents = file(mpath("README.mkd")).read() + top = os.path.abspath(os.getcwd()) def example(s): - d = file(os.path.join(top, s)).read() + d = file(mpath(s)).read() return countershape.template.pySyntax(d) @@ -54,7 +65,7 @@ ns.filt_help = filt_help pages = [ - Page("index.html", "Index"), + Page("index.html", "docs"), Page("intro.html", "Introduction"), Page("interception.html", "Interception"), Page("clientreplay.html", "Client-side replay"), @@ -65,6 +76,7 @@ pages = [ Page("scripts.html", "External scripts"), Page("library.html", "libmproxy: mitmproxy as a library"), Page("ssl.html", "SSL"), + Directory("certinstall"), Page("faq.html", "FAQ"), Page("admin.html", "Administrivia") ] diff --git a/doc-src/library.html b/doc-src/library.html index 2266c077..5b19b61f 100644 --- a/doc-src/library.html +++ b/doc-src/library.html @@ -8,5 +8,5 @@ this lets you log in to a site using your browser, and then make subsequent requests using a tool like __curl__, which will then seem to be part of the authenticated session. -$!example("../examples/stickycookies.py")!$ +$!example("examples/stickycookies.py")!$ diff --git a/doc-src/scripts.html b/doc-src/scripts.html index 0b0b5f80..30f52ed8 100644 --- a/doc-src/scripts.html +++ b/doc-src/scripts.html @@ -8,7 +8,7 @@ The script interface is simple - scripts simply read, modify and return a single __libmproxy.flow.Flow__ object, using the methods defined in the __libmproxy.script__ module. Scripts must be executable. -$!example("../examples/simple_script")!$ +$!example("examples/simple_script")!$ diff --git a/doc-src/ssl.html b/doc-src/ssl.html index afe8f389..16dd9d8f 100644 --- a/doc-src/ssl.html +++ b/doc-src/ssl.html @@ -1,7 +1,4 @@ -SSL -=== - The first time __mitmproxy__ or __mitmdump__ is started, the following set of certificate files for a dummy Certificate Authority are created in the config directory (~/.mitmproxy by default): |