From: Adriana Draghici Date: Thu, 11 Feb 2010 16:13:55 +0000 (+0200) Subject: report - wrote about BT messages X-Git-Tag: getopt_long~166 X-Git-Url: http://p2p-next.cs.pub.ro/gitweb/?a=commitdiff_plain;h=ece73a55ab0c78237c63aea4953b7113f7f0abec;p=cs-p2p-next.git report - wrote about BT messages --- diff --git a/report/img/Logarch.png b/report/img/Logarch.png new file mode 100644 index 0000000..618044e Binary files /dev/null and b/report/img/Logarch.png differ diff --git a/report/img/Logarch_part1.png b/report/img/Logarch_part1.png deleted file mode 100644 index 073c1ad..0000000 Binary files a/report/img/Logarch_part1.png and /dev/null differ diff --git a/report/img/Logarch_part2.png b/report/img/Logarch_part2.png deleted file mode 100644 index 5464dcc..0000000 Binary files a/report/img/Logarch_part2.png and /dev/null differ diff --git a/report/logarch.tex b/report/logarch.tex index f383018..a1893cd 100644 --- a/report/logarch.tex +++ b/report/logarch.tex @@ -1,21 +1,17 @@ \begin{figure} \begin{center} -\includegraphics[width = 6.0in, height = 2.6in]{img/Logarch_part1.png} -\end{center} -\caption{} -\end{figure} -\begin{figure} -\begin{center} -\includegraphics[width = 4.5in, height = 1in]{img/Logarch_part2.png} +\includegraphics[width = 6.6in, height = 2.0in]{img/Logarch.png} \end{center} \caption{} \end{figure} + \subsection{BitTorrent Messages} +\input{logarch/bt.tex} \subsection{BitTorrent Clients Instrumentation} \input{logarch/clients.tex} -\subsection{Parser} +\subsection{Parsers} \input{logarch/parser.tex} \subsection{Database}\label{database} diff --git a/report/logarch/bt.tex b/report/logarch/bt.tex new file mode 100644 index 0000000..4010833 --- /dev/null +++ b/report/logarch/bt.tex @@ -0,0 +1,31 @@ + +The BitTorrent protocol defines the followingg messages, as described in \cite{bt} +\begin{itemize} +\item BT\_HANDSHAKE $$ - first message transmited by the client as the initiator of a connection +\item BT\_CHOKE $$ +\item BT\_UNCHOKE $$ +\item BT\_INTERESTED $$ +\item BT\_UNINTERESTED $$ +\item BT\_BITFIELD $$ - The payload is a bitfield representing the pieces that have been successfully downloaded +\item BT\_REQUEST $$ - used to request a block +\begin{itemize} +\item index: integer specifying the zero-based piece index +\item begin: integer specifying the zero-based byte offset within the piece +\item length: integer specifying the requested length. +\end{itemize} + +\item BT\_PIECE $$ +\begin{itemize} +\item index: integer specifying the zero-based piece index +\item begin: integer specifying the zero-based byte offset within the piece +\item block: block of data, which is a subset of the piece specified by index. +\end{itemize} +\item BT\_HAVE $$ - inform of having a certain piece +\item BT\_CANCEL $$ - used to cancel block requests +\item BT\_KEEP\_ALIVE $$ - must be sent to maintain the connection alive if no command have been sent for a given amount of time +\item BT\_PORT (DHT tracker) $$ +\end{itemize} + + +From the messages decribed above, the most important for future analysis are those related to choking, requesting, receiving +and canceling pieces. They provide information about the behaviour of the certain peers, and might be useful also in predictions. Moreover, the performance details of the tested client can be retrived from inspecting the occurances of this messages. diff --git a/report/report.bib b/report/report.bib index 87bb007..a18379a 100644 --- a/report/report.bib +++ b/report/report.bib @@ -21,3 +21,7 @@ @misc{repo, title={http://koala.cs.pub.ro/git/?p=cs-p2p-next.git/.git;a=tree;f=tribler-mod;h=d8516ffa338b44dcb3d6c83b9d498481c4415eb9;hb=HEAD} } + +@misc{bt, +title = {http://wiki.theory.org/BitTorrentSpecification} +} \ No newline at end of file