More documentation

This commit is contained in:
Christian Basler 2015-04-26 20:37:19 +02:00
parent f00c6018e7
commit 407c432f3c
10 changed files with 605 additions and 13 deletions

View File

@ -1,13 +1,278 @@
\NeedsTeXFormat{LaTeX2e} \NeedsTeXFormat{LaTeX2e}
\ProvidesClass{bfh}[2015/04/21 Class for my BFH reports] \ProvidesClass{bfh}[2015/04/21 Atricle Class for my BFH reports]
\DeclareOption{a4paper}{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\DeclareOption{11pt}{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\DeclareOption{oneside}{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\DeclareOption{titlepage}{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\ExecuteOptions{a4paper,11pt,oneside}
\ProcessOptions
\LoadClass{scrartcl}
\RequirePackage{remreset}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage{color}
\usepackage{lmodern}
\usepackage{url}
\usepackage{lastpage}
\LoadClass[12pt]{scrartcl}
\usepackage{mathtools} \usepackage{mathtools}
\usepackage{amsfonts} \usepackage{amsfonts}
\usepackage[utf8]{inputenc} %\usepackage{float}
\usepackage{hyperref}
\usepackage{graphicx}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{textgreek} \usepackage{textgreek}
\usepackage{centernot} %\usepackage{centernot}
\usepackage{hyphenat}
\usepackage[T1]{fontenc}
\usepackage[scaled]{helvet}
\usepackage{textcomp}
\usepackage{eurosym}
\usepackage{fancyhdr}
\usepackage{alltt}
\usepackage{verbatim}
\usepackage{aeguill}
%\usepackage{underscore}
\usepackage{ctable}
\usepackage[english]{babel}
\usepackage{tabularx}
\usepackage{wrapfig}
\usepackage{ifthen}
\usepackage[usenames,dvipsnames,svgnames]{xcolor}
\usepackage{hyperref}
\usepackage{listings}
\usepackage{attachfile}
\usepackage{enumitem}
\usepackage{wasysym}
\usepackage[absolute]{textpos}
%\usepackage{cite}
%\usepackage[backend=bibtex]{biblatex}
% Literatur- und Bilderquellen trennen
%\defbibheading{lit}{\section*{Literature}}
%\defbibheading{pic}{\section*{Pictures}}
\definecolor{bfhblue}{rgb}{0.396,0.49,0.56} % Blue
\definecolor{bfhorange}{rgb}{0.961,0.753,0.196} % Orange
\definecolor{bfhorangelight}{RGB}{246,216,136} % Orange Light
\hypersetup{
linkcolor=blue, % color of internal links
citecolor=green, % color of links to bibliography
filecolor=blue, % color of file links
urlcolor=blue, % color of external links
colorlinks=true
}
\urlstyle{same}
\typearea{12}
%\bibliographystyle{alpha}
\setcounter{secnumdepth}{4}
\setlength{\parskip}{12pt}
\setlength{\parindent}{0pt}
\renewcommand{\familydefault}{\sfdefault}
\let\oldtoc\tableofcontents
\renewcommand{\tableofcontents} {
\oldtoc
\newpage
}
\newcommand*{\tutor}[1]{\gdef\@tutor{#1}}
\renewcommand{\maketitle} {
\begin{titlepage}
\newlength{\unitlengthtmp}
\setlength{\unitlengthtmp}{\unitlength}
\setlength{\unitlength}{1mm}
\setlength{\TPHorizModule}{\textwidth}
\setlength{\TPVertModule}{\textheight}
%
% BFH Logo
\includegraphics[scale=1.25]{images/logo.pdf}
%
% Linien
\begin{textblock}{1}[0,0](0,0)
\begin{picture}(0,130)
\put(20,0){\color{bfhblue}\rule{\textwidth}{1.2mm}}
\put(20,40){\color{bfhblue}\rule{\textwidth}{1.2mm}} %28.5
\end{picture}
\end{textblock}
%
%Zentrierte Titel
\begin{flushleft}
\vspace*{4.08cm}
\textsf{\textbf{\noindent{\Huge{\textcolor{bfhblue}{\@title}}}}}\\[0.4cm]
\textsf{\huge{\textcolor{bfhblue}{\@subtitle}}}
%
%Angaben zum Dokument
\begin{vfill}
\begin{tabularx}{\textwidth}{lX}
\textsf{Author} & \@author\\
\textsf{Tutor} & \@tutor\\
% \textsf{Expert} & \textsf\DozentA\\
% \textsf{Studiengang} & \textsf{\Studiengang}\vspace{5pt}\\
% \textsf{Autoren} & \textsf\AutorA\\
% & \textsf\AutorB\vspace{5pt}\\
% \textsf{Betreuer} & \textsf\DozentA\\
% & \textsf\DozentB\vspace{5pt}\\
% \textsf{Experten} & \textsf\ExpertA\\
% & \textsf\ExpertB\vspace{5pt}\\
\textsf{Date} & \textsf{\@date}\vspace{5pt}\\
% &\\
% &\\
% \multicolumn{2}{p{\columnwidth-\tabcolsep}}{\textsf{\input{titlepage/titlepage_info}}}\\
\end{tabularx}
\end{vfill}
\end{flushleft}
\setlength{\unitlength}{\unitlengthtmp}
\end{titlepage}
}
\pagestyle{fancy}
\fancyhf{}
\fancyfoot[R]{\hrule\thepage/\pageref{LastPage}}
\fancyfoot[L]{\hrule\today}
\fancyhead[L]{\@title}
\fancyhead[R]{
\includegraphics[height=1.5\baselineskip]{images/logo.png}
}
\addtolength{\headheight}{2\baselineskip}
\addtolength{\headheight}{0.61pt}
\lstset{
language=XML, % Code langugage
basicstyle=\ttfamily\scriptsize,
keywordstyle=\color{OliveGreen}, % Keywords font ('*' = uppercase)
stringstyle=\color{blue}, % String font
commentstyle=\color{gray}, % Comments font
numbers=left, % Line nums position
numberstyle=\tiny, % Line-numbers fonts
stepnumber=1, % Step between two line-numbers
numbersep=10pt, % How far are line-numbers from code
backgroundcolor=\color{BackgroundBlue}, % Choose background color
frame=none, % A frame around the code
tabsize=4, % Default tab size
captionpos=b, % Caption-position = bottom
breaklines=true, % Automatic line breaking?
breakatwhitespace=false, % Automatic breaks only at whitespace?
%showspaces=false, % Dont make spaces visible
%showtabs=false, % Dont make tabls visible
columns=fixed, % Column format
morekeywords={Server, Listener, GlobalNamingResources,
Resource, ResourceLink, Service, Connector, Engine,
Host, Context, Environment,
beans, bean, broker, destinationPolicy, policyMap,
policyEntries, policyEntry, dispatchPolicy,
strictOrderDispatchPolicy, subscriptionRecoveryPolicy,
lastImageSubscriptionRecoveryPolicy, managementContext,
persistenceAdapter, systemUsage, memoryUsage,
storeUsage, tempUsage, transportConnectors,
transportConnector, property, jetty, connectors,
nioConnector, handlers, webAppContext},
}
% Shows a listing and creates an attachment with the source
\newcommand{\attachlisting}[2][]{
\hspace{0.95\textwidth}
\attachfile[icon=Paperclip]{#2}
\vspace{-5ex}
\lstinputlisting[#1]{#2}
}
% 1 line number(s)
% 2 variable name
% 3 description
% 4 example values
\newcommand{\listinginfo}[4]{
\colorbox{WhiteSmoke}{
\parbox[t]{0.25\textwidth}{
\printifnotempty{#1}{\texttt{#1:}\\}
\textit{#2}
}
\parbox[t]{0.715\textwidth}{
\printifnotempty{#3}{#3
}
\printifnotempty{#4}{
\par
\vspace{1ex}
\colorbox{BackgroundBlue}{
\parbox{0.69\textwidth}{
\vspace{-2ex}
\ttfamily
\flushleft{#4}
}
}
\par
\vspace{0.5ex}
}
}
}
\par
\vspace{-1.7ex}
}
\newcommand{\printifnotempty}[2]{
\ifthenelse{\equal{#1}{}}{}{#2}
}
% Makes a red box that highlights errors or very important warnings
\newcommand{\errorbox}[1]{
\fcolorbox{Red}{LightPink}{
\parbox{0.972\textwidth}{
\begin{wrapfigure}[2]{l}{0.05\textwidth}
\vspace{-12pt}
\includegraphics[width=0.05\textwidth]{images/error.pdf}
\vspace{12pt}
\end{wrapfigure}
#1
}
}
}
% Makes a yellow box that highlights warnings
\newcommand{\warningbox}[1]{
\fcolorbox{Goldenrod}{LightYellow}{
\parbox{0.972\textwidth}{
\begin{wrapfigure}[2]{l}{0.05\textwidth}
\vspace{-12pt}
\includegraphics[width=0.05\textwidth]{images/warning.pdf}
\vspace{12pt}
\end{wrapfigure}
#1
}
}
}
% Makes a blue box that highlights special information
\newcommand{\infobox}[1]{
\fcolorbox{CornflowerBlue}{AliceBlue}{
\parbox{0.972\textwidth}{
\begin{wrapfigure}[2]{l}{0.05\textwidth}
\vspace{-12pt}
\includegraphics[width=0.05\textwidth]{images/info.pdf}
\end{wrapfigure}
#1
}
}
}
\usepackage{listings}
\definecolor{BackgroundBlue}{cmyk}{0.05,0,0,0}
\let\olditemize=\itemize
\def\itemize{
\olditemize
\setlength{\itemsep}{-1.5ex}
}
\newcommand{\leadingzero}[1]{\ifnum #1<10 0\the#1\else\the#1\fi}
%YYYY-MM-DD
\newcommand{\todayI}{\the\year-\leadingzero{\month}-\leadingzero{\day}}
\endinput

8
docs/bibliography.bib Normal file
View File

@ -0,0 +1,8 @@
@ONLINE{wiki:protocol,
url = {https://bitmessage.org/wiki/Protocol_specification},
title = {Bitmessage Wiki: Protocol Specification},
publisher = {Bitmessage Wiki},
urldate = {2015-04-24},
author = {Atheros and Coe, Jonathan},
year = {2015},
}

123
docs/images/logo-de.svg Normal file
View File

@ -0,0 +1,123 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
id="svg2"
version="1.1"
inkscape:version="0.48.5 r10040"
width="116.25"
height="67.5"
xml:space="preserve"
sodipodi:docname="logo.pdf"><metadata
id="metadata8"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
id="defs6"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath18"><path
d="m 0,0 922.23,0 0,538.586 L 0,538.586 0,0 z"
id="path20" /></clipPath></defs><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="640"
inkscape:window-height="480"
id="namedview4"
showgrid="false"
inkscape:zoom="3.4962963"
inkscape:cx="58.125"
inkscape:cy="33.75"
inkscape:window-x="271"
inkscape:window-y="47"
inkscape:window-maximized="0"
inkscape:current-layer="g10" /><g
id="g10"
inkscape:groupmode="layer"
inkscape:label="logo"
transform="matrix(1.25,0,0,-1.25,0,67.5)"><g
id="g12"
transform="scale(0.1,0.1)"><g
id="g14"><g
id="g16"
clip-path="url(#clipPath18)"><path
d="m 185.602,538.586 c 77.55,0 140.449,-62.867 140.449,-140.449 0,-52.102 -24.153,-97.317 -63.223,-121.828 -0.765,-0.485 -1.32,-1.211 -1.32,-2.161 0,-1.714 1.359,-2.152 1.453,-2.191 50.684,-19.617 82.488,-71.375 82.488,-131.484 C 345.449,62.875 282.535,0 204.977,0 L 19.4961,0.0390625 C 8.73047,0.0390625 0,8.77344 0,19.5156 L 0,519.094 c 0,10.769 8.73047,19.492 19.4961,19.492 l 166.1059,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path22" /><path
d="m 117.695,95.3672 c -2.476,0 -4.593,2.1172 -4.593,4.5937 l 0,112.6291 c 0,2.469 2.117,4.594 4.593,4.594 l 7.071,0 c 2.468,0 4.613,-2.125 4.613,-4.594 l 0,-49.895 43.844,0 0,49.895 c 0,2.469 2.121,4.594 4.593,4.594 l 7.071,0 c 2.472,0 4.593,-2.125 4.593,-4.594 l 0,-112.6291 c 0,-2.4765 -2.121,-4.5937 -4.593,-4.5937 l -7.071,0 c -2.472,0 -4.593,2.1172 -4.593,4.5937 l 0,48.4181 -43.844,0 0,-48.4181 c 0,-2.4765 -2.145,-4.5937 -4.613,-4.5937 l -7.071,0"
style="fill:#fcd205;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path24" /><path
d="m 117.227,321.836 c -2.477,0 -4.594,2.117 -4.594,4.594 l 0,112.644 c 0,2.473 2.117,4.614 4.594,4.614 l 67.757,0 c 2.473,0 4.594,-2.141 4.594,-4.614 l 0,-4.773 c 0,-2.477 -2.121,-4.594 -4.594,-4.594 l -56.078,0 0,-39.148 47.754,0 c 2.488,0 4.613,-2.121 4.613,-4.598 l 0,-4.789 c 0,-2.477 -2.125,-4.594 -4.613,-4.594 l -47.754,0 0,-50.148 c 0,-2.477 -2.121,-4.594 -4.593,-4.594 l -7.086,0"
style="fill:#fcd205;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path26" /><path
d="m 410.621,489.852 8.406,0 c 7.207,0 9.758,2.777 9.758,9.086 0,6.226 -2.324,9.082 -9.461,9.082 l -8.703,0 0,-18.168 z m -0.078,24.027 8.559,0 c 6.078,0 7.429,2.547 7.429,7.957 0,5.398 -1.726,8.184 -7.804,8.184 l -8.184,0 0,-16.141 z m -4.879,-29.805 c -1.051,0 -1.953,0.895 -1.953,1.953 l 0,47.821 c 0,1.047 0.902,1.953 1.953,1.953 l 13.285,0 c 10.891,0 14.864,-5.711 14.864,-13.821 0,-5.398 -1.348,-8.328 -6.301,-10.429 5.027,-1.422 8.633,-5.332 8.633,-12.985 0,-10.285 -6.758,-14.492 -16.372,-14.492 l -14.109,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path28" /><path
d="m 462.32,517.559 c -4.355,0 -7.054,-2.258 -7.586,-11.27 l 14.946,0 c 0,8.645 -1.953,11.27 -7.36,11.27 z m 0.825,-34.465 c -9.832,0 -15.391,5.703 -15.391,19.824 0,14.258 5.855,19.738 14.719,19.738 8.929,0 14.035,-5.097 14.035,-18.691 l 0,-1.348 c 0,-0.672 -0.528,-1.203 -1.199,-1.203 l -20.645,0 c 0.145,-10.281 2.402,-12.84 8.633,-12.84 3.226,0 5.332,0.977 7.277,2.332 0.906,0.676 2.18,0.449 2.781,-0.379 l 1.2,-1.57 c 0.601,-0.832 0.449,-2.113 -0.45,-2.707 -3.074,-2.176 -6.23,-3.156 -10.96,-3.156"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path30" /><path
d="m 491.531,484.074 c -1.047,0 -1.953,0.895 -1.953,1.953 l 0,33.707 c 0,1.047 0.906,1.946 1.953,1.946 l 1.125,0 c 1.129,0 2.106,-0.821 2.328,-1.946 l 0.676,-3.379 c 2.778,3.45 6.231,6.008 10.586,6.008 0.223,0 0.527,0 0.75,-0.078 0.305,-0.078 0.602,-0.371 0.527,-0.676 l -0.527,-5.254 c -0.07,-0.523 -0.601,-0.972 -1.199,-0.906 -0.375,0.078 -0.824,0.078 -1.203,0.078 -3.449,0 -5.781,-1.277 -8.559,-3.828 l 0,-25.672 c 0,-1.058 -0.898,-1.953 -1.949,-1.953 l -2.555,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path32" /><path
d="m 521.055,484.074 c -1.051,0 -1.953,0.895 -1.953,1.953 l 0,33.707 c 0,1.047 0.902,1.946 1.953,1.946 l 1.125,0 c 1.125,0 2.101,-0.821 2.328,-1.875 l 0.597,-2.774 c 3.309,3.301 7.059,5.625 11.489,5.625 5.402,0 9.086,-2.773 9.086,-9.16 l 0,-27.469 c 0,-1.058 -0.907,-1.953 -1.953,-1.953 l -2.555,0 c -1.051,0 -1.949,0.895 -1.949,1.953 l 0,25.446 c 0,4.281 -1.2,5.48 -4.578,5.48 -3.004,0 -6.383,-2.098 -9.086,-4.5 l 0,-26.426 c 0,-1.058 -0.903,-1.953 -1.95,-1.953 l -2.554,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path34" /><path
d="m 573.313,517.559 c -4.36,0 -7.059,-2.258 -7.586,-11.27 l 14.941,0 c 0,8.645 -1.953,11.27 -7.355,11.27 z m 0.824,-34.465 c -9.836,0 -15.391,5.703 -15.391,19.824 0,14.258 5.859,19.738 14.715,19.738 8.934,0 14.039,-5.097 14.039,-18.691 l 0,-1.348 c 0,-0.672 -0.527,-1.203 -1.199,-1.203 l -20.649,0 c 0.153,-10.281 2.407,-12.84 8.633,-12.84 3.231,0 5.328,0.977 7.281,2.332 0.907,0.676 2.18,0.449 2.782,-0.379 l 1.199,-1.57 c 0.601,-0.832 0.449,-2.113 -0.449,-2.707 -3.082,-2.176 -6.231,-3.156 -10.961,-3.156"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path36" /><path
d="m 602.527,484.074 c -1.047,0 -1.953,0.895 -1.953,1.953 l 0,33.707 c 0,1.047 0.906,1.946 1.953,1.946 l 1.125,0 c 1.129,0 2.106,-0.821 2.328,-1.946 l 0.676,-3.379 c 2.778,3.45 6.231,6.008 10.586,6.008 0.223,0 0.528,0 0.75,-0.078 0.305,-0.078 0.602,-0.371 0.528,-0.676 l -0.528,-5.254 c -0.07,-0.523 -0.597,-0.972 -1.199,-0.906 -0.375,0.078 -0.824,0.078 -1.203,0.078 -3.449,0 -5.781,-1.277 -8.559,-3.828 l 0,-25.672 c 0,-1.058 -0.898,-1.953 -1.949,-1.953 l -2.555,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path38" /><path
d="m 406.41,394.07 c -1.051,0 -1.945,0.903 -1.945,1.953 l 0,47.825 c 0,1.047 0.894,1.953 1.945,1.953 l 21.852,0 c 1.051,0 1.949,-0.906 1.949,-1.953 l 0,-2.032 c 0,-1.043 -0.898,-1.953 -1.949,-1.953 l -16.895,0 0,-15.683 13.363,0 c 1.051,0 1.954,-0.91 1.954,-1.953 l 0,-2.032 c 0,-1.047 -0.903,-1.953 -1.954,-1.953 l -13.363,0 0,-22.219 c 0,-1.05 -0.898,-1.953 -1.949,-1.953 l -3.008,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path40" /><path
d="m 450.371,398.203 c 3.676,0 6.453,2.481 8.258,4.5 l 0,9.992 -2.25,0 c -9.465,0 -11.266,-2.402 -11.266,-7.89 0,-4.95 1.575,-6.602 5.258,-6.602 z m -0.824,-5.105 c -7.207,0 -11.34,3.972 -11.34,11.707 0,8.562 5.031,12.539 17.344,12.539 l 3.078,0 0,2.929 c 0,4.2 -0.527,6.758 -5.406,6.758 -3.227,0 -6.383,-1.133 -9.235,-2.558 -0.976,-0.45 -2.175,-0.071 -2.625,0.91 l -0.754,1.426 c -0.449,0.972 -0.078,2.175 0.899,2.703 3.379,1.797 7.285,3.144 12.387,3.144 7.359,0 11.187,-3.301 11.187,-11.328 l 0,-25.305 c 0,-1.05 -0.898,-1.953 -1.953,-1.953 l -1.121,0 c -1.129,0 -2.18,0.754 -2.481,1.875 l -0.523,1.875 c -2.18,-2.398 -5.332,-4.722 -9.457,-4.722"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path42" /><path
d="m 493.102,393.098 c -9.61,0 -14.942,6.304 -14.942,19.824 0,14.336 5.707,19.734 15.016,19.734 3.601,0 6.457,-0.82 9.16,-3 0.902,-0.672 0.977,-1.875 0.297,-2.703 l -1.203,-1.504 c -0.746,-0.82 -1.95,-0.898 -2.774,-0.222 -1.652,1.277 -3.23,1.953 -5.707,1.953 -5.703,0 -7.883,-2.473 -7.883,-14.258 0,-11.567 2.407,-14.348 8.411,-14.348 2.324,0 3.902,0.899 5.476,2.18 0.828,0.672 2.106,0.601 2.781,-0.227 l 1.352,-1.425 c 0.746,-0.75 0.676,-2.032 -0.152,-2.707 -2.473,-2.176 -5.555,-3.297 -9.832,-3.297"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path44" /><path
d="m 517.891,394.07 c -1.051,0 -1.953,0.903 -1.953,1.953 l 0,50.45 c 0,1.047 0.902,1.953 1.953,1.953 l 2.554,0 c 1.047,0 1.95,-0.906 1.95,-1.953 l 0,-18.993 c 3.304,3.079 6.683,5.176 11.035,5.176 5.402,0 9.086,-2.773 9.086,-9.16 l 0,-27.473 c 0,-1.05 -0.907,-1.953 -1.953,-1.953 l -2.555,0 c -1.051,0 -1.949,0.903 -1.949,1.953 l 0,25.454 c 0,4.277 -1.2,5.476 -4.579,5.476 -3.003,0 -6.382,-2.098 -9.085,-4.504 l 0,-26.426 c 0,-1.05 -0.903,-1.953 -1.95,-1.953 l -2.554,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path46" /><path
d="m 559.496,394.07 c -1.055,0 -1.953,0.903 -1.953,1.953 l 0,50.45 c 0,1.047 0.898,1.953 1.953,1.953 l 2.551,0 c 1.055,0 1.953,-0.906 1.953,-1.953 l 0,-18.993 c 3.305,3.079 6.684,5.176 11.035,5.176 5.403,0 9.086,-2.773 9.086,-9.16 l 0,-27.473 c 0,-1.05 -0.902,-1.953 -1.953,-1.953 l -2.555,0 c -1.05,0 -1.953,0.903 -1.953,1.953 l 0,25.454 c 0,4.277 -1.199,5.476 -4.574,5.476 -3.004,0 -6.383,-2.098 -9.086,-4.504 l 0,-26.426 c 0,-1.05 -0.898,-1.953 -1.953,-1.953 l -2.551,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path48" /><path
d="m 612.621,398.203 c 5.707,0 8.41,3.074 8.41,14.641 0,11.629 -2.777,14.715 -8.48,14.715 -5.711,0 -8.41,-3.008 -8.41,-14.637 0,-11.567 2.777,-14.719 8.48,-14.719 z m 0,-5.105 c -9.16,0 -15.391,5.703 -15.391,19.824 0,14.109 6.086,19.734 15.243,19.734 9.16,0 15.465,-5.625 15.465,-19.734 0,-14.121 -6.157,-19.824 -15.317,-19.824"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path50" /><path
d="m 654.23,393.098 c -9.613,0 -14.945,6.304 -14.945,19.824 0,14.336 5.711,19.734 15.016,19.734 3.605,0 6.457,-0.82 9.16,-3 0.898,-0.672 0.977,-1.875 0.305,-2.703 l -1.203,-1.504 c -0.75,-0.82 -1.954,-0.898 -2.778,-0.222 -1.656,1.277 -3.226,1.953 -5.707,1.953 -5.703,0 -7.883,-2.473 -7.883,-14.258 0,-11.567 2.403,-14.348 8.41,-14.348 2.325,0 3.903,0.899 5.477,2.18 0.824,0.672 2.106,0.601 2.777,-0.227 l 1.356,-1.425 c 0.75,-0.75 0.672,-2.032 -0.152,-2.707 -2.477,-2.176 -5.555,-3.297 -9.833,-3.297"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path52" /><path
d="m 679.023,394.07 c -1.05,0 -1.953,0.903 -1.953,1.953 l 0,50.45 c 0,1.047 0.903,1.953 1.953,1.953 l 2.555,0 c 1.051,0 1.945,-0.906 1.945,-1.953 l 0,-18.993 c 3.309,3.079 6.688,5.176 11.04,5.176 5.402,0 9.085,-2.773 9.085,-9.16 l 0,-27.473 c 0,-1.05 -0.906,-1.953 -1.953,-1.953 l -2.554,0 c -1.051,0 -1.95,0.903 -1.95,1.953 l 0,25.454 c 0,4.277 -1.199,5.476 -4.578,5.476 -3.004,0 -6.383,-2.098 -9.09,-4.504 l 0,-26.426 c 0,-1.05 -0.894,-1.953 -1.945,-1.953 l -2.555,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path54" /><path
d="m 727.582,393.098 c -4.129,0 -8.105,1.343 -10.883,2.925 -0.902,0.598 -1.203,1.797 -0.679,2.707 l 0.832,1.426 c 0.519,0.977 1.722,1.27 2.625,0.75 2.628,-1.504 5.328,-2.398 8.41,-2.398 5.101,0 6.679,2.019 6.679,5.547 0,4.207 -1.953,5.027 -7.961,6.687 -5.253,1.426 -9.609,4.199 -9.609,11.629 0,5.481 3.531,10.285 11.789,10.285 3.602,0 6.309,-0.593 8.711,-1.57 0.977,-0.449 1.426,-1.652 0.977,-2.629 l -0.68,-1.504 c -0.449,-0.976 -1.578,-1.504 -2.625,-1.055 -2.18,0.977 -3.902,1.282 -6.16,1.282 -4.051,0 -5.926,-1.426 -5.926,-4.653 0,-3.535 1.57,-4.429 6.754,-5.855 5.777,-1.574 11.039,-3.828 11.039,-12.317 0,-7.8 -4.434,-11.257 -13.293,-11.257"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path56" /><path
d="m 766.797,393.098 c -9.609,0 -14.942,6.304 -14.942,19.824 0,14.336 5.708,19.734 15.016,19.734 3.602,0 6.453,-0.82 9.16,-3 0.899,-0.672 0.977,-1.875 0.301,-2.703 l -1.199,-1.504 c -0.754,-0.82 -1.953,-0.898 -2.778,-0.222 -1.656,1.277 -3.23,1.953 -5.71,1.953 -5.704,0 -7.879,-2.473 -7.879,-14.258 0,-11.567 2.402,-14.348 8.406,-14.348 2.324,0 3.902,0.899 5.48,2.18 0.825,0.672 2.106,0.601 2.778,-0.227 l 1.351,-1.425 c 0.754,-0.75 0.676,-2.032 -0.148,-2.707 -2.477,-2.176 -5.559,-3.297 -9.836,-3.297"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path58" /><path
d="m 791.586,394.07 c -1.055,0 -1.953,0.903 -1.953,1.953 l 0,50.45 c 0,1.047 0.898,1.953 1.953,1.953 l 2.551,0 c 1.054,0 1.953,-0.906 1.953,-1.953 l 0,-18.993 c 3.305,3.079 6.683,5.176 11.035,5.176 5.402,0 9.086,-2.773 9.086,-9.16 l 0,-27.473 c 0,-1.05 -0.902,-1.953 -1.953,-1.953 l -2.555,0 c -1.051,0 -1.953,0.903 -1.953,1.953 l 0,25.454 c 0,4.277 -1.199,5.476 -4.574,5.476 -3.004,0 -6.383,-2.098 -9.086,-4.504 l 0,-26.426 c 0,-1.05 -0.899,-1.953 -1.953,-1.953 l -2.551,0"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path60" /><path
d="m 840.68,393.098 c -5.41,0 -9.61,3.074 -9.61,9.605 l 0,27.031 c 0,1.047 0.899,1.946 1.95,1.946 l 2.55,0 c 1.051,0 1.953,-0.899 1.953,-1.946 l 0,-25 c 0,-4.429 1.5,-5.933 4.879,-5.933 3.004,0 6.231,2.027 9.008,4.512 l 0,26.421 c 0,1.047 0.903,1.946 1.953,1.946 l 2.555,0 c 1.051,0 1.949,-0.899 1.949,-1.946 l 0,-33.711 c 0,-1.05 -0.898,-1.953 -1.949,-1.953 l -1.129,0 c -1.129,0 -2.098,0.832 -2.328,1.875 l -0.602,2.785 c -3.148,-3.234 -6.754,-5.632 -11.179,-5.632"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path62" /><path
d="m 880,393.32 c -4.805,0 -6.832,2.559 -6.832,9.16 l 0,43.993 c 0,1.047 0.898,1.953 1.953,1.953 l 2.551,0 c 1.055,0 1.953,-0.906 1.953,-1.953 l 0,-45.196 c 0,-1.875 0.824,-2.625 2.625,-2.625 0.305,0 0.602,0 0.824,0.078 0.379,0 0.754,-0.222 0.828,-0.605 l 0.375,-2.18 c 0.227,-1.043 -0.449,-2.097 -1.5,-2.324 -0.902,-0.144 -1.879,-0.301 -2.777,-0.301"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path64" /><path
d="m 908.043,427.559 c -4.355,0 -7.059,-2.254 -7.582,-11.27 l 14.937,0 c 0,8.645 -1.953,11.27 -7.355,11.27 z m 0.824,-34.461 c -9.836,0 -15.39,5.703 -15.39,19.824 0,14.258 5.855,19.734 14.714,19.734 8.934,0 14.039,-5.097 14.039,-18.691 l 0,-1.348 c 0,-0.676 -0.527,-1.203 -1.199,-1.203 l -20.644,0 c 0.144,-10.281 2.402,-12.84 8.633,-12.84 3.226,0 5.332,0.977 7.281,2.332 0.902,0.676 2.176,0.449 2.777,-0.379 l 1.199,-1.574 c 0.602,-0.828 0.45,-2.105 -0.449,-2.703 -3.074,-2.18 -6.23,-3.152 -10.961,-3.152"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path66" /></g></g></g></g></svg>

After

Width:  |  Height:  |  Size: 15 KiB

84
docs/images/logo-en.svg Normal file
View File

@ -0,0 +1,84 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
id="svg2"
version="1.1"
inkscape:version="0.48.5 r10040"
width="130.34865"
height="67.32325"
xml:space="preserve"
sodipodi:docname="logo-en.svg"><metadata
id="metadata8"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
id="defs6"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath18"><path
d="m 0,0 922.23,0 0,538.586 L 0,538.586 0,0 z"
id="path20"
inkscape:connector-curvature="0" /></clipPath></defs><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="889"
inkscape:window-height="781"
id="namedview4"
showgrid="false"
inkscape:zoom="6.9925926"
inkscape:cx="64.932998"
inkscape:cy="68.072034"
inkscape:window-x="271"
inkscape:window-y="47"
inkscape:window-maximized="0"
inkscape:current-layer="g10"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0" /><g
id="g10"
inkscape:groupmode="layer"
inkscape:label="logo"
transform="matrix(1.25,0,0,-1.25,0,67.32325)"><path
inkscape:connector-curvature="0"
id="path22"
style="fill:#467d97;fill-opacity:1;fill-rule:nonzero;stroke:none"
d="m 18.5602,53.8586 c 7.755,0 14.0449,-6.2867 14.0449,-14.0449 0,-5.2102 -2.4153,-9.7317 -6.3223,-12.1828 -0.0765,-0.0485 -0.132,-0.1211 -0.132,-0.2161 0,-0.1714 0.1359,-0.2152 0.1453,-0.2191 5.0684,-1.9617 8.2488,-7.1375 8.2488,-13.1484 C 34.5449,6.2875 28.2535,0 20.4977,0 L 1.94961,0.00390625 C 0.873047,0.00390625 0,0.877344 0,1.95156 L 0,51.9094 c 0,1.0769 0.873047,1.9492 1.94961,1.9492 l 16.61059,0" /><path
inkscape:connector-curvature="0"
id="path24"
style="fill:#fcd205;fill-opacity:1;fill-rule:nonzero;stroke:none"
d="m 11.7695,9.53672 c -0.2476,0 -0.4593,0.21172 -0.4593,0.45937 l 0,11.26291 c 0,0.2469 0.2117,0.4594 0.4593,0.4594 l 0.7071,0 c 0.2468,0 0.4613,-0.2125 0.4613,-0.4594 l 0,-4.9895 4.3844,0 0,4.9895 c 0,0.2469 0.2121,0.4594 0.4593,0.4594 l 0.7071,0 c 0.2472,0 0.4593,-0.2125 0.4593,-0.4594 l 0,-11.26291 c 0,-0.24765 -0.2121,-0.45937 -0.4593,-0.45937 l -0.7071,0 c -0.2472,0 -0.4593,0.21172 -0.4593,0.45937 l 0,4.84181 -4.3844,0 0,-4.84181 c 0,-0.24765 -0.2145,-0.45937 -0.4613,-0.45937 l -0.7071,0" /><path
inkscape:connector-curvature="0"
id="path26"
style="fill:#fcd205;fill-opacity:1;fill-rule:nonzero;stroke:none"
d="m 11.7227,32.1836 c -0.2477,0 -0.4594,0.2117 -0.4594,0.4594 l 0,11.2644 c 0,0.2473 0.2117,0.4614 0.4594,0.4614 l 6.7757,0 c 0.2473,0 0.4594,-0.2141 0.4594,-0.4614 l 0,-0.4773 c 0,-0.2477 -0.2121,-0.4594 -0.4594,-0.4594 l -5.6078,0 0,-3.9148 4.7754,0 c 0.2488,0 0.4613,-0.2121 0.4613,-0.4598 l 0,-0.4789 c 0,-0.2477 -0.2125,-0.4594 -0.4613,-0.4594 l -4.7754,0 0,-5.0148 c 0,-0.2477 -0.2121,-0.4594 -0.4593,-0.4594 l -0.7086,0" /><text
xml:space="preserve"
style="font-size:11.55966663px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#467d97;fill-opacity:1;stroke:none;font-family:Constantia;-inkscape-font-specification:Constantia"
x="40.459648"
y="-47.22646"
id="text3153"
sodipodi:linespacing="125%"
transform="scale(0.97670303,-1.0238527)"><tspan
sodipodi:role="line"
id="tspan3155"
x="40.459648"
y="-47.22646"
style="font-size:7.06424141px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#467d97;fill-opacity:1;font-family:News Gothic MT;-inkscape-font-specification:News Gothic MT">Bern University</tspan><tspan
sodipodi:role="line"
x="40.459648"
y="-38.396156"
id="tspan3157"
style="font-size:7.06424141px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#467d97;fill-opacity:1;font-family:News Gothic MT;-inkscape-font-specification:News Gothic MT">of Applied Sciences</tspan></text>
</g></svg>

After

Width:  |  Height:  |  Size: 4.7 KiB

BIN
docs/images/logo.pdf Normal file

Binary file not shown.

BIN
docs/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

View File

@ -3,20 +3,17 @@
\title{Project 2} \title{Project 2}
\subtitle{Bitmessage -- Communication Without Metadata} \subtitle{Bitmessage -- Communication Without Metadata}
\author{Christian Basler} \author{Christian Basler}
\tutor{Kai Brünnler}
\date{\today} \date{\today}
\begin{document} \begin{document}
\maketitle \maketitle
\begin{figure}[h]
\includegraphics[width=0.2\textwidth]{logo.png}
\centering
\end{figure}
\tableofcontents \tableofcontents
\section{Synopsis} \section{Synopsis}
TODO
% Section basics % Section basics
@ -32,6 +29,13 @@
\section{Issues} \section{Issues}
TODO
\subsection{Unsigned Numbers}
Java doesn't support unsigned number types. While Java 8 has some helper classes to address this issue, my goal is to support Java 7, which is needed for Android development, so I wasn't able to leverage them.
\subsection{Proof of Work} \subsection{Proof of Work}
Proof of work is needed for a message to be distributed within the Bitmessage network. This is to protect both the network itself from denial of service attacks and the users from spam. Proof of work is needed for a message to be distributed within the Bitmessage network. This is to protect both the network itself from denial of service attacks and the users from spam.
@ -51,6 +55,11 @@
\subsection{Network Management} \subsection{Network Management}
\section{Usage}
TODO
\section{Discussion} \section{Discussion}

BIN
docs/seminar.pdf Normal file

Binary file not shown.

103
docs/seminar.tex Normal file
View File

@ -0,0 +1,103 @@
\documentclass{bfh}
\usepackage[numbers]{natbib}
\title{Informatikseminar}
\subtitle{Bitmessage -- Communication Without Metadata}
\author{Christian Basler}
\tutor{Kai Brünnler}
\date{\today}
\newcommand{\msg}[1]{\textit{#1}}
\newcommand{\obj}[1]{\textbf{#1}}
\newcommand{\node}[1]{\textbf{#1}}
\begin{document}
\maketitle
\tableofcontents
\section{Synopsis}
TODO
% Section basics
\input{basics}
\section{Protocol}
\subsection{Nomenclature}
There are a few terms that are easily mixed up. Here's a list of the most confusing ones:
\listinginfo{}{message}{is sent from one node to another, i.e. to announce new objects or to initialize the network connection.}{}
\listinginfo{}{msg}{is the object payload containing the actual message written by a user. The term 'message' is never used to describe information exchange between users in this document.}{}
\listinginfo{}{payload}{There are two kinds of payload: message payload for message types, e.g. containing inventory vectors, and object payload, which is distributed throughout the network.}{}
\listinginfo{}{object}{is a kind of message whose payload is distributed among all nodes. Somtimes just the payload is meant.}{}
\subsection{Process Flow}
The newly started node \node{A} connects to a random node \node{B} from its node registry and sends a \msg{version} message, announcing the latest supported protocol version. If \node{B} accepts the version\footnote{A version is accepted by default if it is higher or equal to a nodes latest supported version. Nodes supporting experimental protocol versions might accept older versions.}, it responds with a \msg{verack} message, followed by a \msg{version} message announcing its own latest supported protocol version. Node \node{A} then decides whether it supports \node{B}'s version and sends its \msg{verack} mesage.
If both nodes accept the connection, they both send an \msg{addr} message containing up to 1000 of its known nodes, followed by one or more \msg{inv} messages announcing all valid objects they are aware of. They then send \msg{getobject} request for all objects still missing from their inventory.
\msg{Getobject} requests are answered by \msg{object} messages containing the requested objects.
If a user writes a new mail on node \node{A}, it is offered via \msg{inv} to up to eight connected nodes. They will get the object and distribute it to up to eight of their connections, and so on.
\subsection{Messages}
The messages and binary format are very well discribed in the Bitmessage wiki \cite{wiki:protocol}, the message description is therefore narrowed down to a description of what they do and when they're used.
\subsubsection{version / verack}
A \msg{version} message contains the latest protocol version supported by a node, as well as the streams it is interested in and which features it supports. If the other node accepts, it acknowledges with a \msg{verack} message. The connection is initialized when both nodes sent a \msg{verack} message.
\subsubsection{addr}
Contains up to 1000 known nodes with their IP addresses, ports, streams and supported features.
\subsubsection{inv}
One \msg{inv} message contains the hashes of up to 50000 valid objects. If your inventory is larger, several messages can be sent.
\subsubsection{getdata}
Can request up to 50000 objects by sending their hashes.
\subsubsection{object}
Contains one requested object, which might be one of:
\listinginfo{}{getpubkey}{A request for a public key, which is needed to encrypt a message to a specific user.}{}
\listinginfo{}{pubkey}{A public key. See \ref{subsec:addrenc} \nameref{subsec:addrenc}}{}
\listinginfo{}{msg}{}{}
\listinginfo{}{broadcast}{}{}
\subsubsection{ping / pong}
\subsection{Addresses and Encryption}
\label{subsec:addrenc}
\section{Issues}
\subsection{Scalability}
TODO
\section{Discussion}
TODO
\bibliographystyle{plain}
\bibliography{bibliography}
\appendix
\addcontentsline{toc}{section}{Appendix}
\section*{Appendix}
\renewcommand{\thesubsection}{\Alph{subsection}}
\subsection{TODO}
\end{document}