<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Gustavo F. Padovan &#187; gpsl</title>
	<atom:link href="http://padovan.org/blog/tag/gpsl/feed/" rel="self" type="application/rss+xml" />
	<link>http://padovan.org/blog</link>
	<description>a hacking life</description>
	<lastBuildDate>Fri, 23 Jul 2010 22:30:07 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>GSoC meet-up at Unicamp</title>
		<link>http://padovan.org/blog/2010/03/gsoc-meet-up-at-unicamp/</link>
		<comments>http://padovan.org/blog/2010/03/gsoc-meet-up-at-unicamp/#comments</comments>
		<pubDate>Wed, 10 Mar 2010 04:18:35 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[gpsl]]></category>
		<category><![CDATA[unicamp]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=144</guid>
		<description><![CDATA[Last Wednesday (March 3rd) we did a talk about Google Summer of Code at Unicamp. The talk was part of the weekly talk about Free Software in the University. It was presented by mentors and students from past GSoCs. We explained how GSoC works and how one can take part on it this year. I&#8217;ll [...]]]></description>
			<content:encoded><![CDATA[<p>Last Wednesday (March 3rd) we did a talk about Google Summer of Code at Unicamp. The talk was part of the weekly talk about Free Software in the University. It was presented by mentors and students from past GSoCs. We explained how GSoC works and how one can take part on it this year. I&#8217;ll post here some photos:</p>
<p><img title="GSoC meet-up" src="http://littlechina.org/~padovan/img/gsoc-1.jpg" alt="" width="600" /></p>
<p><img title="GSoC meet-up" src="http://littlechina.org/~padovan/img/gsoc-2.jpg" alt="" width="600" /></p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2010/03/gsoc-meet-up-at-unicamp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Summer of Code 2009: Final stats</title>
		<link>http://padovan.org/blog/2009/09/google-summer-of-code-2009-final-stats/</link>
		<comments>http://padovan.org/blog/2009/09/google-summer-of-code-2009-final-stats/#comments</comments>
		<pubDate>Sat, 12 Sep 2009 06:12:22 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[gpsl]]></category>
		<category><![CDATA[unicamp]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=103</guid>
		<description><![CDATA[Google Open Source team has just published yesterday a set of stats[1] about Google Summer of Code 2009 and Google Summer of Code during the years. The good news is that University of Campinas (Unicamp) is on the second place in number of accepted students to GSoC 2009, with 12 projects.  We also are the [...]]]></description>
			<content:encoded><![CDATA[<p>Google Open Source team has just published yesterday a set of <a href="http://google-opensource.blogspot.com/2009/09/tasty-new-google-summer-of-code-stats.html" target="_blank">stats</a>[1] about Google Summer of Code 2009 and Google Summer of Code during the years. The good news is that University of Campinas (Unicamp) is on the second place in number of accepted students to GSoC 2009, with 12 projects.  We also are the second place in the history of the program with 37 projects. Congratulations to all guys from University of Campinas that take part on GSoC. We&#8217;ve been done a great job. Unicamp rocks! :-)</p>
<p style="text-align: left;">[1] <a href="http://google-opensource.blogspot.com/2009/09/tasty-new-google-summer-of-code-stats.html" target="_blank">http://google-opensource.blogspot.com/2009/09/tasty-new-google-summer-of-code-stats.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/09/google-summer-of-code-2009-final-stats/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>BlueZ: status update into the L2CAP layer</title>
		<link>http://padovan.org/blog/2009/08/bluez-status-update-into-the-l2cap-layer/</link>
		<comments>http://padovan.org/blog/2009/08/bluez-status-update-into-the-l2cap-layer/#comments</comments>
		<pubDate>Sat, 29 Aug 2009 17:11:35 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[bluez]]></category>
		<category><![CDATA[crc16]]></category>
		<category><![CDATA[en]]></category>
		<category><![CDATA[enhanced retransmission mode]]></category>
		<category><![CDATA[gpsl]]></category>
		<category><![CDATA[l2cap]]></category>
		<category><![CDATA[streaming mode]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=88</guid>
		<description><![CDATA[Since the last post here (it was a long time ago :-) too much work was done, but ERTM isn&#8217;t fully implemented yet. So, what did I do last month? I&#8217;ll explain each of the features I implemented on the next paragraphs, but if this are boring for you just take a look at the [...]]]></description>
			<content:encoded><![CDATA[<p>Since the last post here (it was a long time ago :-) too much work was done, but ERTM isn&#8217;t fully implemented yet. So, what did I do last month?<br />
I&#8217;ll explain each of the features I implemented on the next paragraphs, but if this are boring for you just take a look at the roadmap at the end of this post.</p>
<p>First I did the support to send and receive I-frames (the data frames) and created the support to RR S-frames to acknowledge the received I-frames. It first worked with a txWindow=1 (which means only one packet can be send without receive acknowledge from the receiver side). The next step was support a txWindow up to 63 (the maximum value specified). To bring this support I have been using sk_buff lists from the net core implementation.</p>
<p>Support for Segmentation and Reassembly(SAR) of L2CAP SDUs: this feature allows upper applications to use a buffer greater than the L2CAP size packet. The buffer is break down in many packet on the transmitter side and then reassembled on the receiver side and pushed to the upper layer.</p>
<p>REJ frame exception: When a packet is lost we need to start the recoveries procedures. BlueZ won&#8217;t support raise of REJ exception (we support only raise of SREJ exception by now, spec says that we can choose one of them). But we need to support the receipt of a REJ-exception (i.e. receive a REJ frame). On the receipt of a REJ frame the L2CAP entity needs to stop the transmission and starts to retransmit the requested packets.  A REJ frame tells the ReqSeq(packet id sequence) and all packets up to ReqSeq &#8211; 1 shall be considered acknowledged, the others shall be retransmitted.</p>
<p>SREJ frame exception: BlueZ starts a SREJ exception when it detects lost packets. It sets its state to SREJ_SENT(It means that L2CAP entity is under recovery proccess) and sends a SREJ S-frame for each lost packets. The transmitter side shall resend the packets requested in the SREJ frames without stops transmission of new frames. SREJ exception saves retransmission of unneeded frames.</p>
<p>Retransmission And Monitor Timers: The Retransmission Timer shall be (re)started each time we send a I-frame. If it expires we send a RR-frame and start the Monitor Timer. The other side should response the RR frame immediately, if the the other side do not response and the Monitor Timer expires we resend the RR frame. A maximum value for the of Monitor Timer&#8217;s timeouts can be defined. If a L2CAP entity exceeds this value the channel shall be disconnected.</p>
<p>Busy condition on the remote side: If the remote side enters in a busy condition it will send a RNR frame. So, when the local side receives this frame it should mark the remote busy flag as true and stop the transmission of packets. It restarts the sending of packets only when the remote sides send a REJ, SREJ or RR frame. This says the remote busy condition was cleared.</p>
<p>Streaming mode: This mode of operation is useful to the Bluetooth Streaming Profiles such as A2DP and VDP(not yet implemented). It can take advantages of the Segmentation and Reassembly features.</p>
<p>FCS Option: It is a crc16 check for L2CAP packets. It is the default if both sides support it. If a L2CAP entity receives a packet with a broken crc16 it will drop. The receive procedure will miss it and start the recovery procedure.</p>
<p>Roadmap updated:</p>
<ol>
<li><del datetime="2009-08-29T05:11:58+00:00">Implement ERTM with txWindow=1 and retransmission disabled</del>.
<ol type="i">
<li><del datetime="2009-08-29T05:11:58+00:00">send I-frames</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">receive I-frames</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">support RR S-frames to acknowledge I-frames received</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">acknowledge I-frames</del></li>
</ol>
</li>
<li><del datetime="2009-08-29T05:11:58+00:00">Support txWindow up to 63</del></li>
<li><del datetime="2009-08-29T05:14:58+00:00">Support segmentation and reassembly of L2CAP SDUs</del></li>
<li><del datetime="2009-08-29T20:49:20+00:00">Enable retransmission</del>
<ol type="i">
<li><del datetime="2009-08-29T05:11:58+00:00">support receipt REJ S-Frame</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">support receipt SREJ S-Frame</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">support raise of SREJ exception</del></li>
</ol>
</li>
<li> Support busy conditions exceptions</li>
<li><del datetime="2009-08-29T05:11:58+00:00">Enable Retransmission Timer</del></li>
<li><del datetime="2009-08-29T05:11:58+00:00">Enable Monitor Timer</del></li>
<li><del datetime="2009-08-29T05:14:58+00:00">Implement Streaming Mode</del></li>
<li><del datetime="2009-08-29T05:14:58+00:00">Implement FCS Option</del></li>
<li>Support duplex channel</li>
<li>Use SOCK_STREAM as default for Enhanced Retransmission and Streaming Modes.</li>
<li>Test BlueZ against others stacks</li>
</ol>
<h3> What&#8217;s next?</h3>
<p>Now I&#8217;m working the busy condition exception and the support for the ERTM duplex channel. Today, just one side can send data packets. Then I&#8217;ll put ERTM as default when SOCK_STREAM is selected. I expect finish these issues on the coming weeks. After, I&#8217;ll spend my time fixing the bugs I find trough the code.</p>
<p>ps: Sorry for my too not bad English ;-)</p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/08/bluez-status-update-into-the-l2cap-layer/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>BlueZ: What I&#8217;m doing that I&#8217;m not posting here</title>
		<link>http://padovan.org/blog/2009/07/bluez-what-im-doing-that-im-not-posting-here/</link>
		<comments>http://padovan.org/blog/2009/07/bluez-what-im-doing-that-im-not-posting-here/#comments</comments>
		<pubDate>Sat, 25 Jul 2009 17:51:33 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[bluez]]></category>
		<category><![CDATA[gpsl]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=81</guid>
		<description><![CDATA[I spent the last weeks work on my Google Summer of Code project. Code for items 1, 2 and 3 of the roadmap that I posted here[1] 3 week ago is almost done and in process to be merged into bluetooth-testing. Now I&#8217;m starting to work on item 4. First I&#8217;ll will look to support [...]]]></description>
			<content:encoded><![CDATA[<p>I spent the last weeks work on my Google Summer of Code project. Code for items 1, 2 and 3 of the roadmap that I posted <a href="http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/" target="_blank">here</a>[1] 3 week ago is almost done and in process to be merged into bluetooth-testing. Now I&#8217;m starting to work on item 4. First I&#8217;ll will look to support REJ S-frames and implement retransmission of L2CAP packets.</p>
<p>[1] <a href="http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/" target="_blank">http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/07/bluez-what-im-doing-that-im-not-posting-here/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Vim plugin for pastebin</title>
		<link>http://padovan.org/blog/2009/07/vim-plugin-for-pastebin/</link>
		<comments>http://padovan.org/blog/2009/07/vim-plugin-for-pastebin/#comments</comments>
		<pubDate>Thu, 16 Jul 2009 02:32:41 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[vim]]></category>
		<category><![CDATA[en]]></category>
		<category><![CDATA[gpsl]]></category>
		<category><![CDATA[pastebin]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=73</guid>
		<description><![CDATA[I was looking for a pastebin plugin for vim. I&#8217;ve  found one[1], but it was not  working, then I fixed it. The plugin is here[2]. And if is useful to you there is a git repo[3] too. How to use: Put it into ~/.vim/plugin to autoload the plugin every time you open VIM. You can also [...]]]></description>
			<content:encoded><![CDATA[<p>I was looking for a pastebin plugin for vim. I&#8217;ve  found <a href="http://djcraven5.blogspot.com/2006/10/vimpastebin-post-to-pastebin-from.html" target="_blank">one</a>[1], but it was not  working, then I fixed it. The plugin is <a href="http://www.las.ic.unicamp.br/~gustavo/pub/vim/vim-pastebin/plugin/pastebin.vim" target="_blank">here</a>[2]. And if is useful to you there is a git <a href="http://github.com/pao/vim-pastebin/tree/master" target="_blank">repo</a>[3] too.</p>
<p><strong>How to use:</strong></p>
<p>Put it into <tt>~/.vim/plugin</tt> to autoload the plugin every time you open VIM. You can also source it manually:</p>
<blockquote><p><tt>:source /path/to/pastebin.vim</tt></p></blockquote>
<p>You can set your favorite pastebin site and your name editing the pastebin.vim</p>
<p>From [1]: &#8220;To use the script is very simple. Just visually block (Shift-v) the lines of code you want to send to the <a class="ext-link" href="http://pastebin.com/"><span class="icon">Pastebin</span></a> and enter the command <tt>:PasteCode</tt>. The blocked text will be sent to the <a class="ext-link" href="http://pastebin.com/"><span class="icon">Pastebin</span></a> and the new URL will be shown on the Vim statusline.&#8221;</p>
<p style="text-align: left;">[1] <a href="http://djcraven5.blogspot.com/2006/10/vimpastebin-post-to-pastebin-from.html" target="_blank">http://djcraven5.blogspot.com/2006/10/vimpastebin-post-to-pastebin-from.html</a><br />
[2] <a href="http://www.las.ic.unicamp.br/~gustavo/pub/vim/vim-pastebin/plugin/pastebin.vim" target="_blank">http://www.las.ic.unicamp.br/~gustavo/pub/vim/vim-pastebin/plugin/pastebin.vim</a><br />
[3] <a href="http://github.com/pao/vim-pastebin/tree/master" target="_blank">http://github.com/pao/vim-pastebin/tree/master</a></p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/07/vim-plugin-for-pastebin/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>BlueZ: First patch was merged</title>
		<link>http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/</link>
		<comments>http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/#comments</comments>
		<pubDate>Sun, 05 Jul 2009 03:25:30 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[bluez]]></category>
		<category><![CDATA[en]]></category>
		<category><![CDATA[gpsl]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=51</guid>
		<description><![CDATA[The first patch, that add support to L2CAP Enhanced Retransmission, was merged into bluetooth-testing yesterday. The patch adds support to  configure L2CAP connections in Enhanced Retransmission(ERTM) and Streaming Modes besides the Basic Mode.  Streaming Mode will not be implemented now, but it&#8217;s better make all configuration code for the 3 modes instead only ERTM and [...]]]></description>
			<content:encoded><![CDATA[<p>The first patch, that add support to L2CAP Enhanced Retransmission, was merged into bluetooth-testing yesterday. The patch adds support to  configure L2CAP connections in Enhanced Retransmission(ERTM) and Streaming Modes besides the Basic Mode.  Streaming Mode will not be implemented now, but it&#8217;s better make all configuration code for the 3 modes instead only ERTM and Basic Mode. This way we don&#8217;t need to touch twice into configuration code.  The commit is <a href="http://git.kernel.org/?p=linux/kernel/git/holtmann/bluetooth-testing.git;a=commitdiff;h=cd3875bd8ec1cbb490c76dae19fdad375132be73" target="_blank">here</a> and that is the commit message:</p>
<blockquote><p>Bluetooth: Add configuration support for ERTM and Streaming mode</p>
<p>Add support to config_req and config_rsp to configure ERTM and Streaming<br />
mode. If the remote device specifies ERTM or Streaming mode, then the<br />
same mode is proposed. Otherwise ERTM or Basic mode is used. And in case<br />
of a state 2 device, the remote device should propose the same mode. If<br />
not, then the channel gets disconnected.</p>
<p><span class="signoff">Signed-off-by: Gustavo F. Padovan &lt;gustavo@las.ic.unicamp.br&gt;</span><br />
<span class="signoff">Signed-off-by: Marcel Holtmann &lt;marcel@holtmann.org&gt;</span></p></blockquote>
<p>Now I&#8217;m going to implement support to send and receive I-frames and S-frames. Some part of the code for that . First I&#8217;m going to add support to transmissions with txWindow = 1 (i.e., only one packet can be sent per time without acknowledgment from the other side) and no retransmission support and I intend to finish it during this week.</p>
<p>Here is a quick roadmap for my work:</p>
<ol>
<li>Implement ERTM with txWindow=1 and retransmission disabled.
<ol type="i">
<li>send I-frames</li>
<li>receive I-frames</li>
<li>support RR S-frames to acknowledge I-frames received</li>
<li>acknowledge I-frames</li>
</ol>
</li>
<li>Support txWindow up to 63</li>
<li>Support segmentation and reassembly of L2CAP SDUs</li>
<li>Enable retransmission
<ol type="i">
<li>support REJ S-Frame</li>
<li>support SREJ S-Frame</li>
<li>support RNR S-Frame to indicate busy condition</li>
<li> use RR S-frame to show that is ready to receive I-frames</li>
</ol>
</li>
<li>Enable Retransmission Timer</li>
<li>Enable Monitor Timer</li>
<li>Test BlueZ against others stack that implement ERTM</li>
</ol>
<p>I expect that until end of August finish all this topics. So, let&#8217;s hack. =)</p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/07/bluez-first-patch-was-merged/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Arena de Programação do FISL 10</title>
		<link>http://padovan.org/blog/2009/07/arena-de-programacao-do-fisl-10/</link>
		<comments>http://padovan.org/blog/2009/07/arena-de-programacao-do-fisl-10/#comments</comments>
		<pubDate>Thu, 02 Jul 2009 04:15:41 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[dnscurve]]></category>
		<category><![CDATA[fisl]]></category>
		<category><![CDATA[gpsl]]></category>
		<category><![CDATA[pt_BR]]></category>

		<guid isPermaLink="false">http://padovan.org/blog/?p=38</guid>
		<description><![CDATA[Durante a décima edição do Fórum Internacional do Software Livre [0] em Porto Alegre &#8211; RS, Brasil participei da Arena de Programação do evento. O desafio desse ano foi implementar um servidor e um cache DNS que suportasse o DNSCurve[1], protocolo de criptografia para DNS criado por Daniel J. Bernstein[2], também criador do djbdns[3]. O [...]]]></description>
			<content:encoded><![CDATA[<p>Durante a décima edição do <a title="FISL 10" href="http://fisl.softwarelivre.org/" target="_blank">Fórum Internacional do Software Livre</a> [0] em Porto Alegre &#8211; RS, Brasil participei da Arena de Programação do evento. O desafio desse ano foi implementar um servidor e um cache DNS que suportasse o <a href="http://dnscurve.org">DNSCurve</a>[1], protocolo de criptografia para DNS criado por <a title="Daniel J. Bernstein" href="http://cr.yp.to/djb.html" target="_blank">Daniel J. Bernstein</a>[2], também criador do <a title="djbdns" href="http://cr.yp.to/djbdns.html" target="_blank">djbdns</a>[3]. O desafio foi proposto e julgado pelo djb.</p>
<p>A arena durou 3 dias. Às 22 horas do terceiro dia deveríamos entregar o servidor e o cache com DNSCurve para o Daniel. Meu grupo era formado por mim, pelo <a href="http://jprvita.wordpress.com" target="_blank">João Paulo Rechi Vita</a>[4], que também é aluno aqui da Unicamp e assim como eu, está no <a href="http://code.google.com/soc/" target="_blank">Google Summer of Code</a> pelo projeto <a href="http://www.bluez.org">BlueZ</a>. E por Rodrigo Exterckötter Tjäder, aluno de Ciência da Computação da UFSM &#8211; Universidade Federal de Santa Maria.</p>
<p>Ficamos sabendo o que teríamos que fazer apenas no início do primeiro dia, então passamos as primeiras horas descobrindo do que se tratava o DNSCurve (principalmente eu, que não estudei Redes formalmente na Unicamp ainda). Após entendermos o DNSCurve fomos atrás de implementações de DNS para tomarmos como ponto de partida para nossa implementação. Partimos preferencialmente para implementações em python, pois seria bem mais rápido e tranquilo desenvolver.</p>
<p>Rechi Vita encontrou uma implementação de servidor DNS em python, chamada <a href="http://sourceforge.net/projects/pymds/" target="_blank">pymds</a>[5] e uma implementação de cache chamada <a title="PyDNSCache" href="http://www.rbgrn.net/projects" target="_blank">PyDNSCache</a>[6]. Ambas as implementações são extremamente pequenas, o que facilitou o nosso entendimento e a expansão desses códigos para suportar o DNSCurve.</p>
<p>Para a parte cripotográfica do DNSCurve usamos a <a href="http://github.com/mrd/dnscurve/tree/master" target="_blank">slownacl</a>[7] biblioteca que implementa a todo calculo criptográfico do DNSCurve. Acompanhavam a slowsalt pequenas bibliotecas para manipulação pacotes DNS, isto é, funções prontas pra descriptografar e criptografar pacotes DNS que são enviados e recebidos pelos servidor e cache.</p>
<p>Passamos os dois primeiros dias integrando esses 3 códigos: pymds, PyDNSCache e slownacl. No final do segundo dia tinhamos um servidor e um cache funcionando para o envio e recebimento de pacotes. Mas esse cache nao resolvia nomes recursivamente e como ia dar muito trabalho implementar isso no nosso cache, resolvemos abandoná-lo e partir para uma nova implementação de cache usando a biblioteca <a title="DNS Python" href="http://www.dnspython.org/" target="_blank">dnspython</a>[8]. Com esse novo código foi possível fazer o cache resolver nomes recursivamente e consequentemente conseguir pegar a chave pública do servidor DNS.</p>
<p>O Resultado desses três dias de maratona foi recompesado com a vitória. Nossa solução foi eleita a melhor e recebemos um celular G1 rodando Android cada e muitos elogios do djb sobre o nosso código. =)</p>
<p>Nosso código está <a href="http://www.las.ic.unicamp.br/~joaopaulo/arena/" target="_blank">aqui</a>[9] e abaixo coloco a descrição sobre a implementação que enviamos ao Daniel junto com nosso código:</p>
<p>We implemented the two proposed parts separately.</p>
<p>(1) DNS Server &#8212; pymdscurve.tar.bz2</p>
<p>We based our implementation on pymds [5], a modular python DNS server<br />
licensed under the MIT license. It&#8217;s a standalone DNS server, in terms<br />
it doesn&#8217;t resolve any names it doesn&#8217;t know. For the NaCl functions,<br />
we used the slownacl lib from dnscurve [1]. Despite it doesn&#8217;t says on<br />
the website, we contacted the authors (both Matthew and Angel) and<br />
both of them told us the is public domain and a note on the project<br />
page is missing. Matthew even added a README to the code which says<br />
it&#8217;s public domain and updated some code on the lib to make it<br />
compliant with NaCl spec (article on your website).</p>
<p>(2) DNS Cache</p>
<p>For the cache we tried two different approaches.</p>
<p>(i) PyDNSCacheCurve.tar.bz2 &#8212; First we added the DNSCurve messages to<br />
PyDNSCache [6], which is a very simple DNS cache written in python and<br />
intended to be used as a python library. This code didn&#8217;t had any<br />
license note on the project page either, but we contacted the author<br />
and he licensed it under Creative Commons Attribution 3.0 United<br />
States License. Since it&#8217;s just a cache of DNS information, it used<br />
gethostbyname() from the socket module. We changed it to use a<br />
function we implemented, gethostfromDNS(), to send the necessary DNS<br />
messages to get the information from a server. For the cryptography<br />
part we&#8217;ve also used slownacl from dnscurve [1]. We didn&#8217;t implemented<br />
the ability to resolve names recursively on PyDNSCache, so we<br />
hardcoded the server public key inside the code.</p>
<p>(ii) dnspythoncurve.tar.bz2 &#8212; Since solution (i) was unable to<br />
resolve names recursively, we decided to use dnspython [8], which<br />
provides a lot of helper functions to deal with DNS. We&#8217;ve added<br />
DNSCurve extensions to it and also added a recursive resolver.<br />
dnspython [4] is released under a BSD-style license. Since recursive<br />
resolution works we can get the server name to check if it a DNSCurve<br />
enabled server and, if so, obtain it&#8217;s public key.</p>
<p>We&#8217;ve tested pymdscurve and dnspythoncurve under a scenery with two<br />
servers, one configured as authority for .com and other as authority<br />
for example.com, in order to test recursive resolution. Both config<br />
files are shipped in pymdscurve package.</p>
<p>We plan to send patches back to all projects we&#8217;ve added code to. We<br />
have also added some code to some dns helper functions on dnscurve<br />
[1], outside of slownacl</p>
<p>[0] <a href="http://fisl.softwarelivre.org/" target="_blank">http://fisl.softwarelivre.org</a><br />
[1] <a href="http://dnscurve.org" target="_blank">http://dnscurve.org</a><br />
[2] <a href="http://cr.yp.to/djb.html" target="_blank">http://cr.yp.to/djb.html</a><br />
[3] <a href="http://cr.yp.to/djbdns.html" target="_blank">http://cr.yp.to/djbdns.html</a><br />
[4] <a href="http://jprvita.wordpress.com" target="_blank">http://jprvita.wordpress.com</a><br />
[5] <a href="http://sourceforge.net/projects/pymds/" target="_blank">http://sourceforge.net/projects/pymds/</a><br />
[6] <a href="http://www.rbgrn.net/projects" target="_blank">http://www.rbgrn.net/projects</a><br />
[7] <a href="http://github.com/mrd/dnscurve/tree/master" target="_blank">http://github.com/mrd/dnscurve/tree/master</a><br />
[8] <a href="http://www.dnspython.org/" target="_blank">http://www.dnspython.org/</a><br />
[9] <a href="http://www.las.ic.unicamp.br/~joaopaulo/arena/" target="_blank">http://www.las.ic.unicamp.br/~joaopaulo/arena/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/07/arena-de-programacao-do-fisl-10/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Let&#8217;s hack! Google Summer of Code 2009 has come.</title>
		<link>http://padovan.org/blog/2009/04/lets-hack-google-summer-of-code-2009-has-come/</link>
		<comments>http://padovan.org/blog/2009/04/lets-hack-google-summer-of-code-2009-has-come/#comments</comments>
		<pubDate>Thu, 23 Apr 2009 00:58:01 +0000</pubDate>
		<dc:creator>padovan</dc:creator>
				<category><![CDATA[free software]]></category>
		<category><![CDATA[gsoc]]></category>
		<category><![CDATA[bluez]]></category>
		<category><![CDATA[en]]></category>
		<category><![CDATA[gpsl]]></category>

		<guid isPermaLink="false">http://www.las.ic.unicamp.br/~gustavo/blog/?p=20</guid>
		<description><![CDATA[I&#8217;m proud to announce I was accepted on Google Summer of Code 2009. Google announced on Monday the students accepted on GSoC 2009. I&#8217;m going to hack BlueZ. My project is named &#8220;L2CAP Enhanced Retransmission mode support&#8221; . My mentors are Luiz Augusto &#8220;Vudentz&#8221; von Dentz and Marcel Holtmann. The work is on L2CAP layer, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m proud to announce I was accepted on Google Summer of Code 2009. Google announced on Monday the students accepted on <a title="GSoC 2009" href="http://socghop.appspot.com/program/accepted_orgs/google/gsoc2009" target="_blank">GSoC 2009</a>. I&#8217;m going to hack BlueZ.<br />
My project is named &#8220;<a href="http://socghop.appspot.com/student_project/show/google/gsoc2009/bluez/t124021929416" target="_blank">L2CAP Enhanced Retransmission mode support&#8221;</a> . My mentors are Luiz Augusto &#8220;Vudentz&#8221; von Dentz and Marcel Holtmann.<br />
The work is on L2CAP layer, which passes the packets from the Link Manager to the higher layer protocols or vice versa.(If you don&#8217;t know what I&#8217;m talking read the links in the end of the post). BlueZ L2CAP layer implementation only supports basic mode of transmission of packets, but corrupted or lost packets can&#8217;t be resent.<br />
The new implementation with the L2CAP Enhanced Retransmission mode will permit retransmission of  corrupted or lost L2CAP packets improving the bluetooth experience on Linux. L2CAP Enhanced Retransmission has a mechanism to notify the sender of the packet that it need to be retransmitted.<br />
If you wanna see what a I&#8217;m doing you can subscribe this blog and get my <a href="http://www.las.ic.unicamp.br/~gustavo/git/" target="_blank">kernel tre</a>e with the L2CAP Enhanced Retransmission mode implementation. Vudentz is going to a page for my project into <a href="http://wiki.bluez.org/wiki/" target="_blank">BlueZ wiki</a>, so when done I&#8217;ll post the link here.</p>
<p><strong>About GSoC 2009 in Brazil:</strong><br />
Leslie Hawthorn has posted yesterday on Google Open Source Blog some <a href="http://google-opensource.blogspot.com/2009/04/announcing-accepted-students-for-google.html" target="_blank">statistics</a> about GSoC 2009, and Brazil is the top 5 country for accepted student applicants , with 43 students. I&#8217;m too happy to hear that, but I&#8217;m also waiting for the statistic about students accepted per University. Last year my university (Unicamp &#8211; University of Campinas) was the 2nd in the whole world.</p>
<p>And I wanna congratulate my friends of University of Campinas that were accepted on GSoC 2009 too. They are João Paulo Rechi Vita, working on BlueZ with me and Vudentz is his mentor too; Bruno Cardoso working on LLVM for the third time. Helder Ribeiro on ReviewBoard; João &#8220;lvwr&#8221; Correa on NMAP and Thiago &#8220;bolaum&#8221; Abdnur.  We will hack togheter for next four months to accomplish our Google Summer of Code project.</p>
<p><strong>Getting deeper on Bluetooth:</strong><br />
For a first read you can read [1] e [2] , if wanna more you can go to [3] e and look thought the spec.</p>
<p>[1] <a href="http://en.wikipedia.org/wiki/Bluetooth" target="_blank">http://en.wikipedia.org/wiki/Bluetooth</a></p>
<p>[2] <a href="http://bluetooth.com/Bluetooth/Technology/Works/Overview_of_Operation.htm" target="_blank">http://bluetooth.com/Bluetooth/Technology/Works/Overview_of_Operation.htm</a></p>
<p>[3] <a href="http://bluetooth.com/Bluetooth/Technology/Building/Specifications/" target="_blank">http://bluetooth.com/Bluetooth/Technology/Building/Specifications/</a></p>
<p>ps: if you find errors in my English, please tell me, I&#8217;m learning yet. =)</p>
]]></content:encoded>
			<wfw:commentRss>http://padovan.org/blog/2009/04/lets-hack-google-summer-of-code-2009-has-come/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
