<?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>mala::home</title>
	<atom:link href="http://davide.eynard.it/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://davide.eynard.it</link>
	<description>Davide "+mala" Eynard's website</description>
	<lastBuildDate>Sun, 06 Dec 2009 17:46:30 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Pirate Radio: Let your voice be heard on the Internet</title>
		<link>http://davide.eynard.it/?p=161</link>
		<comments>http://davide.eynard.it/?p=161#comments</comments>
		<pubDate>Sun, 06 Dec 2009 10:00:53 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[hacks]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=161</guid>
		<description><![CDATA[[Foreword: this is article number 4 of the new "hacks" series. Read here if you want to know more about this.]
&#8220;I believe in the bicycle kicks of Bonimba, and in Keith Richard&#8217;s riffs&#8221;: for whoever recognizes this movie quote, it will be easy to imagine what you could feel when you speak on the radio, [...]]]></description>
			<content:encoded><![CDATA[<p>[Foreword: this is article number 4 of the new "hacks" series. Read <a href="../../?p=106" target="_blank">here</a> if you want to know more about this.]</p>
<p>&#8220;I believe in the bicycle kicks of Bonimba, and in Keith Richard&#8217;s riffs&#8221;: for whoever recognizes this <a href="http://www.imdb.com/title/tt0169164/" target="_blank">movie</a> quote, it will be easy to imagine what you could feel when you speak on the radio, throwing in the air a message that could virtually be heard by anyone. Despite all the new technologies that came after the invention of the radio, its charm has remained the same; moreover, the evolution of the Internet has given us a chance to become deejays, using simple softwares and broadcasting our voice on the Net instead of using radio signals. So, why don&#8217;t we use these tools to create our &#8220;pirate radio&#8221;, streaming non-copyrighted music and information free from the control of the big media?</p>
<div id="attachment_163" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr01.png"><img class="size-medium wp-image-163" title="Streaming architecture" src="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr01-300x225.png" alt="Figure 1: Streaming servers work as antenna towers for the signals you send them, broadcasting your streams to all the connected users." width="300" height="225" /></a><p class="wp-caption-text">Figure 1: Streaming servers work as antenna towers for the signals you send them, broadcasting your streams to all the connected users.</p></div>
<h3>Technical details</h3>
<p>It is not too difficult to understand how a streaming radio works (see Figure 1): everyhing you need is a streaming server, which receives an audio stream from your computer and makes this stream available to all its listeners. This is the most versatile solution and allows anyone, even with a simple 56kbps modem, to broadcast without bandwidth problems. The only limit is that you need a server to send your stream to: fortunately, many servers are available for free and it is pretty easy to find a list of them online (for instance, at <a href="http://www.radiotoolbox.com/hosts" target="_blank">http://www.radiotoolbox.com/hosts</a>). A solution which is a little more complex but that allows you to be completely autonomous is to install a streaming audio server on your own machine (if you have one which is always connected to the Internet), so you&#8217;ll be your own broadcaster. Of course, in this case the main limit is the bandwidth: an ADSL is more than enough if you don&#8217;t have many listeners, but you might need something more powerful if the number of listeners increases. If creating a Web radio is not a trivial task (we will actually need to setup a streaming server and an application to send the audio stream to it), listening to it is very easy: most of the audio applications currently available (i.e. Media Player, Winamp, XMMS, VLC) are able to connect and play an audio stream given its URL.</p>
<h3>Install the software</h3>
<p>The most famous technologies in audio streaming are currently two: SHOUTCast (<a href="http://www.shoutcast.com" target="_blank">http://www.shoutcast.com</a>) and Icecast (<a href="http://icecast.org" target="_blank">http://icecast.org</a>). The first one is proprietary and the related software is closed source, even if it is distributed for free; the second one, instead, is based on an opensource server and supports different third-party applications which are also distributed with free licenses. Even if Shoutcast is somehow easier to use (actually, the software is basically integrated within Winamp), our choice has fallen on Icecast as it is far more versatile. The Icecast server is available both for Windows and Linux: the Windows version has a graphical interface while the Linux one runs as a service; in both cases, the configuration can be managed through a text file called icecast.xml. Most of the settings can be left untouched, however it is a good practice to change the default password (which is &#8220;hackme&#8221;) with a custom one inside the authentication section. Once you have installed and configured your server you can run it, and it will start waiting for connections.</p>
<div id="attachment_164" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr02.png"><img class="size-medium wp-image-164" title="Icecast for Win screenshot" src="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr02-300x279.png" alt="Figure 2: The main screen from Windows Icecast server, showing connection stats in realtime." width="300" height="279" /></a><p class="wp-caption-text">Figure 2: The main screen from Windows Icecast server, showing connection stats in realtime.</p></div>
<p>The applications you can use to connect to Icecast to broadcast audio are many and different in genre and complexity. Between the ones we tested, we consider the following as the most interesting ones:</p>
<ul>
<li><a href="http://star.arm.ac.uk/~spm/software/liveice.html">LiveIce</a> is a client that can be used as an XMMS plugin. Its main advantage is the simplicity: in fact, you just need to play mp3 files with XMMS to automatically send them to the Icecast server;</li>
<li><a href="http://www.oddsock.org/tools/oddcastv2_wa2">OddCast</a>, which is basically the equivalent of LiveIce for Winamp;</li>
<li><a href="http://darkice.sf.net">DarkIce</a>, a command line tool that directly streams audio from a generic device to the server. The application is at the same time mature and still frequently updated, and the system is known to be quite stable.</li>
<li><a href="http://muse.dyne.org">Muse</a>, a much more advanced tool, which is able to mix up to six audio channels and the &#8220;line in&#8221; of your audio card, and also to save the stream on your hard disk so you can reuse it (for instance creating a podcast);</li>
<li><a href="http://dynebolic.org">DyneBolic</a>, finally, is a live Linux distribution which gives you all the tools you might need to create an Internet radio: inside it, of course, you will also find IceCast and Muse.</li>
</ul>
<h3>Manage the programs schedule</h3>
<p>One of the main differences between an amateur radio and a professional one is the management of the programs schedule: the tools we have described till now, in fact, are not able to manage the programs depending on the current time or to play songs as a filler between different programs. <a href="http://www.somasuite.org">Soma Suite</a> is an application which can solve this problem, as it is able to create programs of different types: playlists (even randomly generated ones), audio streams (yours or taken from other radios), files, and so on.</p>
<div id="attachment_165" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr03.png"><img class="size-medium wp-image-165" title="Soma Suite" src="http://davide.eynard.it/blog/wp-content/uploads/2009/12/pr03-300x240.png" alt="Figure 3: Somasuite's graphical interface offers a complete view of your radio's program schedule." width="300" height="240" /></a><p class="wp-caption-text">Figure 3: Somasuite&#39;s graphical interface offers a complete view of your radio&#39;s program schedule.</p></div>
<h3>Leave a trace on the Net</h3>
<p>One of the main requirements for something worth calling a radio is to have listeners. However, how can we be heard if nobody knows us yet? Of course not broadcasting our IP address (maybe even a dynamic one!) every time we decide to stream. Luckily, there are a couple of solutions to this problem. The first one consists in advertising your radio inside some well-known lists: in fact, you can configure your Icecast server so that you can automatically send your current IP address to one of these lists whenever you run it. Icecast itself provides one of these listings, but of course you can choose different ones (even at the same time) to advertise your stream. The second solution consists in publishing your programs online using podcasts: this way, even those who could not follow you in realtime will be able to know you and tune at the right time to listen your next transmission.</p>
<p>Now that you have a radio, what can you broadcast? Even if the temptation of playing copyrighted music regardless of what majors think might be strong, why shall we do what any other website (from youtube to last.fm) is already doing? Talk, let your ideas be heard from the whole world and when you want to provide some good music choose free alternatives such as the ones you find <a href="http://lifehacker.com/software/geek-to-live/geek-to-live-find-free-music-on-the-web-136578.php">here</a> and <a href="http://davide.eynard.it/malawiki/FreeMp3">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=161</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>All for a question mark</title>
		<link>http://davide.eynard.it/?p=141</link>
		<comments>http://davide.eynard.it/?p=141#comments</comments>
		<pubDate>Wed, 11 Nov 2009 10:34:31 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=141</guid>
		<description><![CDATA[Hey, did you know that the &#8220;where&#8221; keyword in the &#8220;where&#8221; clause in SPARQL is optional? Yep, you can check it here!
What does this mean? Well, instead of writing something like
select ?s ?p ?o where{
  ?s ?p ?o
}
you can write
select ?s ?p ?o {
  ?s ?p ?o
}
So, what&#8217;s the problem? Well, there is [...]]]></description>
			<content:encoded><![CDATA[<p>Hey, did you know that the &#8220;where&#8221; keyword in the &#8220;where&#8221; clause in SPARQL is optional? Yep, you can check it <a href="http://www.w3.org/TR/rdf-sparql-query/#rWhereClause" target="_blank">here</a>!</p>
<p>What does this mean? Well, instead of writing something like</p>
<pre>select ?s ?p ?o where{
  ?s ?p ?o
}</pre>
<p>you can write</p>
<pre>select ?s ?p ?o {
  ?s ?p ?o
}</pre>
<p>So, what&#8217;s the problem? Well, there is no problem&#8230; But what if you forget a space and write the following?</p>
<pre>select ?s ?p ?owhere {
  ?s ?p ?o
}</pre>
<p>I guess you can understand what this means :) Of course it is very easy to spot this error, but what if you are building the query string like the following one?</p>
<pre>$query  = "select ?s ?p ?o";
$query .= "where {\n";
$query .= "  ?s ?p ?o\n";
$query .= "}";</pre>
<p>I know, I know, that is a quick and dirty way of doing it, and anyone who does this should pay the fee. But what if a poor student forgets a \n in the concatenation, the system does not return any error, and all the objects you were asking for are not returned? Be aware, friends, and don&#8217;t repeat his mistake&#8230; ;-)</p>
<p>[thanks Sarp for providing me the chance to spot this error - it was a funny reversing exercise!]</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=141</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Request for Comments: learn Internet standards by reading the documents that gave them birth</title>
		<link>http://davide.eynard.it/?p=147</link>
		<comments>http://davide.eynard.it/?p=147#comments</comments>
		<pubDate>Sun, 08 Nov 2009 10:00:12 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[hacks]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=147</guid>
		<description><![CDATA[[Foreword: this is article number 3 of the new "hacks" series. Read here if you want to know more about this. A huuuuuge THANX to Aliosha who helped me with the translation of this article!]
A typical characteristic of hackers is the desire to understand -in the most intimate details- the way any machinery works. From [...]]]></description>
			<content:encoded><![CDATA[<p>[Foreword: this is article number 3 of the new "hacks" series. Read <a href="../../?p=106" target="_blank">here</a> if you want to know more about this. A huuuuuge THANX to <a href="http://aliosha.org/" target="_blank">Aliosha</a> who helped me with the translation of this article!]</p>
<p>A typical characteristic of hackers is the desire to understand -in the most intimate details- the way any machinery works. From this point of view, Internet is one of the most interesting objects of study, since it offers a huge variety of concepts to be learnt: just think how many basic formats and standards it relies on&#8230; And all the nice hacks we could perform once we understand the way they work!</p>
<p>Luckily, most of these standards are published in freely accessible and easily obtainable notes: these documents are called RFC (Request for Comments), and have been used for almost 40 years to share information and observations regarding Internet formats, technologies, protocols and standards. The first RFC goes up to 1969, and since then more than 5500 have been published. Each one of them has to pass a difficult selection process lead by IETF (Internet Engineering Task Force), whose task is -as described in RFC 3935 and 4677- &#8220;to manage the Internet in such a way as to make the Internet work better.&#8221;</p>
<div id="attachment_149" class="wp-caption aligncenter" style="width: 210px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc01.png"><img class="size-medium wp-image-149" title="rfc01" src="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc01-200x300.png" alt="John Postel, one of the authors of the first RFC and contributor to the project for 28 years, has always typed on his keyboard using only two fingers :-)" width="200" height="300" /></a><p class="wp-caption-text">John Postel, one of the authors of the first RFC and contributor to the project for 28 years, has always typed on his keyboard using only two fingers :-)</p></div>
<h3>The RFC format</h3>
<p>In order to become a RFC, a technical document must above all follow a very strict standard. At a first glance, it strikes us for its stark outlook: a simple text file with 73 columns, exclusively formatted with standard ASCII chars. On a second thought, it is easy to understand the reason of this choice: what format did not change since 1969 and can be visualized on any computer, no matter how old it is or which OS it runs?</p>
<div id="attachment_150" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc02.png"><img class="size-medium wp-image-150" title="rfc02" src="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc02-300x199.png" alt="Despite of the fact that many standards are now more than stable, the number of published RFCs is always increasing." width="300" height="199" /></a><p class="wp-caption-text">Despite of the fact that many standards are now more than stable, the number of published RFCs is always increasing.</p></div>
<p>Every RFC has a header with information especially important for the reader. In addition to title, date and authors, there is also the unique serial number of the document, the relations with preceding documents, and its category. For example (see figure below), the most recent RFC that describes the SMTP protocol is 5321, updating RFC 1123, making 2821 obsolete, belonging to the &#8220;Standard Track&#8221; category. Similarly, if we read that a document has been &#8220;obsoleted&#8221; by another, it is better to look for this other one, since it will contain more up to date information.</p>
<p>The categories of RFCs are several, depending to the level of standardization reached by the described protocol or format at the moment of publication. The documents considered as the most official ones are split in three main categories: well-established standards (<em>standard</em>), drafts (<em>draft</em>) and standard proposals (<em>proposed</em>). There are also three non-standard classes, including experimental documents (<em>experimental</em>), informative ones (<em>informational</em>), and historical ones (<em>historic</em>). Finally, there is an &#8220;almost standard&#8221; category, containing the Best Current Practices (<em>BCP</em>), that is all those non official practices that are considered the most logical to adopt.</p>
<div id="attachment_151" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc03.png"><img class="size-medium wp-image-151" title="rfc03" src="http://davide.eynard.it/blog/wp-content/uploads/2009/11/rfc03-300x73.png" alt="The header of RFC 5321, the document devoted to the SMTP protocol." width="300" height="73" /></a><p class="wp-caption-text">The header of RFC 5321, the document devoted to the SMTP protocol.</p></div>
<h3>Finding the document we want</h3>
<p>Now that we understand the meaning of RFC associated metadata (all those data not pertaining to the content of the document but to the document itself), we only have to take a peek inside the official IETF archive to see if there is information of interest for us. There are several methods to find an RFC: the first -and simplest- can be used when we know the document serial number and consists in opening the address <em>http://www.ietf.org/rfc/rfcxxxx.txt</em>, where <em>xxxx</em> is that number. For instance, the first RFC in computer history is available at <a href="http://www.ietf.org/rfc/rfc0001.txt" target="_blank">http://www.ietf.org/rfc/rfc0001.txt</a>.</p>
<p>Another search approach consists in starting from a protocol name and searching for all the documents that are related to it. To do this, we can use the list of Official Internet Protocol Standards that is available at <a href="http://www.rfc-editor.org/rfcxx00.html" target="_blank">http://www.rfc-editor.org/rfcxx00.html</a>. Inside this list you can find the acronyms of many protocols, their full names and the standards they are related to: for instance, IP, ICMP, and IGMP protocols are described in different RFCs but they are all part of the same standard (number 5).</p>
<p>Finally, you can search documents according to their status or category: at <a href="http://www.rfc-editor.org/category.html" target="_blank">http://www.rfc-editor.org/category.html</a> you can find an index of RFCs ordered by publication status and, for each section, updated documents appear as black while obsolete ones are red, together with the id of the RFC which obsoleted them.</p>
<p>The tools we have just described should be enough in most of the cases: in fact, we usually know at least the name of the protocol we want to study, if not even the code of the RFC where it is described. However, whenever we just have a vague idea of the concepts that we want to learn, we can use the search engine available at <a href="http://www.rfc-editor.org/rfcsearch.html" target="_blank">http://www.rfc-editor.org/rfcsearch.html</a>. If, for instance, we want to know something more about the encoding used for mail attachments, we can just search for &#8220;mail attachment&#8221; and obtain as a result the list of titles of the RFCs which deal with this topic (in this case, RDF 2183).</p>
<h3>What should I read now?</h3>
<p>When you have an archive like this available, the biggest problem you have to face is the huge quantity of information: a life is not enough to read all of these RFCs! Search options, fortunately, might help in filtering away everything which is not interesting for us. However, which could be good starting points for our research?</p>
<p>If we don&#8217;t know where to begin, having a look at the basic protocols is always a good way to start: you can begin from the easiest, higher-level ones, such as the ones regarding email (POP3, IMAP, and SMTP, already partially described here), the Web (HTTP), or other famous application-level protocols (FTP, IRC, DNS, and so on). Transport and network protocols, such as TCP and IP, are more complicated but not less interesting than the others.</p>
<p>If, instead, you are searching for something simpler you can check informative RFCs: they actually contain many interesting documents, such as RFC 2151 (A Primer On Internet and TCP/IP Tools and Utilities) and 2504 (Users&#8217; Security Handbook). April Fool&#8217;s documents deserve a special mention, being funny jokes written as formal RFCs (<a href="http://en.wikipedia.org/wiki/April_Fools%27_Day_RFC" target="_blank">http://en.wikipedia.org/wiki/April_Fools%27_Day_RFC</a>). Finally, if you still have problems with English (so, why are you reading this? ;-)) you might want to search the Internet for RFCs translated in your language. For instance, at <a href="http://rfc.altervista.org" target="_blank">http://rfc.altervista.org</a>, you can find the Italian version of the RFCs describing the most common protocols.</p>
<div id="_mcePaste" style="overflow: hidden; position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px;">[Foreword: this is article number 2 of the new "hacks" series. Read <a href="../../?p=106" target="_blank">here</a> if you want to know more about this]</div>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=147</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Human-Machine Communication</title>
		<link>http://davide.eynard.it/?p=138</link>
		<comments>http://davide.eynard.it/?p=138#comments</comments>
		<pubDate>Sat, 31 Oct 2009 18:37:41 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=138</guid>
		<description><![CDATA[Maybe we still have some problems&#8230;

;-)
]]></description>
			<content:encoded><![CDATA[<p>Maybe we still have some problems&#8230;</p>
<p><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/hamlet02.png"><img class="aligncenter size-medium wp-image-139" title="Hamlet" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/hamlet02-300x166.png" alt="Hamlet" width="300" height="166" /></a></p>
<p>;-)</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=138</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hacking Challenge: challenge hackers in a skill game</title>
		<link>http://davide.eynard.it/?p=127</link>
		<comments>http://davide.eynard.it/?p=127#comments</comments>
		<pubDate>Sun, 25 Oct 2009 10:00:20 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[hacks]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=127</guid>
		<description><![CDATA[[Foreword: this is article number 2 of the new "hacks" series. Read here if you want to know more about this]
[Foreword 2: if you know me, you also know I usually don't use the term "hacker" lightly. I'm sure you will understand what I mean here without being offended, whether you are a (real) hacker [...]]]></description>
			<content:encoded><![CDATA[<p>[Foreword: this is article number 2 of the new "hacks" series. Read <a href="../../?p=106" target="_blank">here</a> if you want to know more about this]</p>
<p>[Foreword 2: if you know me, you also know I usually don't use the term "hacker" lightly. I'm sure you will understand what I mean here without being offended, whether you are a (real) hacker or not ;-)]</p>
<p>In the latest years, also thanks to the fact that website creation has become a much easier and quicker task, the number of hacking challenges on the Internet has considerably increased. These websites usually consist of a series of riddles or puzzles, published by increasing difficulty; solving one of these riddles you can gain points or advance to higher levels where you can access some new resources inside the website. Riddles and puzzles, of course, are &#8220;tailored for hackers&#8221;: the knowledge required to participate, in fact, covers a little bit of everything technical, from scripting languages to cryptography, from reverse engineering to Internet search techniques. Participating to these challenges is a very interesting experience, not only because it is instructive, but also because it allows you to network with other people with your same passion. And, after all, some narcisism doesn&#8217;t hurt: most of the hacking challenges you can find around the Web also have a &#8220;hall of fame&#8221;, inside which you can see the (nick)names of the hackers who reached the highest scores.</p>
<p style="text-align: center;">
<div id="attachment_132" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall01.png"><img class="size-medium wp-image-132" title="ASCII" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall01-300x265.png" alt="The website http://ascii-table.com provides an ASCII table with dec, hex, octal, and binary codes, together with a collection of tools to convert text in different formats. You'll be surprised at how much this can be useful for you." width="300" height="265" /></a><p class="wp-caption-text">Figure 1: The website http://ascii-table.com provides an ASCII table with dec, hex, octal, and binary codes, together with a collection of tools to convert text in different formats. You&#39;ll be surprised at how much this can be useful for you.</p></div>
<h3>Create new riddles</h3>
<p>If participating to a hacking challenge as a player is really funny, letting people play your own challenge could be really awesome. Becoming &#8220;riddlers&#8221; is not particularly complicated from a technical viewpoint: everything you need is some time, together with lots of creativity.</p>
<p>The main idea is that the final answer to a riddle could always be summarized as a simple string of text: in the easiest case it could be a name, in the most complex it could become a (more or less long) sequence of apparently random characters. The easiest way to check if the string is right is to use it as part of the URL of the page containing the following riddle. You can ask users to manually type this URL inside their browsers or use some Javascript code to automatically generate it: if the answer is right the correct page will be loaded, otherwise the Web server will return an error message. More advanced methods to check riddle solutions involve the use of scripting languages (such as Perl, PHP, or Python) and passwords saved inside a file or a database.</p>
<h3>The tools</h3>
<p>Whatever your choice is, you will not have many problems in finding the Web space and the software you need to create your own hacking challenge. Actually, there are currently lots of free Web space providers available and many of them also give you the chance to run scripts or store your data inside databases. You can also practice by creating a test environment locally on your PC, using ready LAMP (Linux+Apache+PHP+MySQL) packages. For instance, XAMPP (http://www.apachefriends.org/it/xampp.html) is an Apache distribution that comes together with PHP, MySQL, and Perl: the installation procedure has been designed to be as simple as possible and in few minutes you&#8217;ll be able to start experimenting with your site.</p>
<p style="text-align: center;">
<div id="attachment_134" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall03.png"><img class="size-medium wp-image-134" title="XAMPP" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall03-300x170.png" alt="XAMPP is one of the quickest way to run a LAMP servers on your Windoze, Linux, or Mac computer." width="300" height="170" /></a><p class="wp-caption-text">Figure 2: XAMPP is one of the quickest way to run a LAMP servers on your Windoze, Linux, or Mac computer.</p></div>
<h3>Find inspiration</h3>
<p>Before you build a new riddle you&#8217;d better gather some information, checking what has already been created and what in general you like most. The Web is full of hacking challenges you might get some inspiration from, however finding the one which might be more interesting for you is a riddle on its own. To help you in the choice, instead of searching for challenges on classical search engines you might better start from some more specific websites. <a href="http://www.hackergames.net" target="_blank">Hackergames.net</a> is a &#8220;historical&#8221; portal for this genre, with links to about 150 different challenges: for each of them you can find details such as the main language, a description, and a list of reviews written by users themselves. <a href="http://www.wechall.net" target="_blank">We Chall</a>, instead, despite having links to less challenges, has introduced a whole new API-like communication system between websites; using that, it can aggregate scores from different challenges, allowing users to be listed into a global ranking which spans over many sites. Last but not least, keep an eye on all those sites (such as <a href="http://www.bright-shadows.net" target="_blank">TheBlackSheep</a>) that accept contributions from their own users, as they give you the chance to see your riddles published without requiring you to develop and maintain a website on your own.</p>
<p style="text-align: center;">
<div id="attachment_133" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall02.png"><img class="size-medium wp-image-133" title="WeChall" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/chall02-300x210.png" alt="We Chall plots, for each user, all the progresses done in every challenge she has subscribed to." width="300" height="210" /></a><p class="wp-caption-text">Figure 3: We Chall plots, for each user, all the progresses done in every challenge she has subscribed to.</p></div>
<h3>Hacker psychology</h3>
<p>The main rule in a hacking challenge worth this name is that there are no rules. If a solution to your riddle is not the one you had envisioned, well&#8230; that&#8217;s a good thing: it means that who found it is more creative than you! Finding alternative ways to reach one goal is a very common hacker approach, so you shouldn&#8217;t be surprised if, trying to find the solutions to your riddles, somebody tries to exploit your system vulnerabilities. So, here are some suggestions to keep your challenge as funny as possible, both for your players and you:</p>
<ul>
<li>check how secure your scripts are, in particular against the most common types of exploit (such as SQL injection, if you save data inside a database);</li>
<li>do not rely on &#8220;security by obscurity&#8221;, making the security of your website depend on the secrecy of some pieces of information: give for granted the fact that they will be discovered sooner or later and act accordingly. For instance, do not keep all the solutions to your riddles in clear but rather encrypt them, so that whoever finds them will have to sweat a little more to get to the next level;</li>
<li>one of the simplest, but at the same time effective way to crack a short password is bruteforcing. So, use secret strings which are long and difficult to bruteforce, and make it clear for everyone: this way, users will avoid bruteforce finding it unuseful (and save a lot of your bandwidth);</li>
<li>if you are good with programming, you can intentionally leave some bugs in the system so that users will be able to exploit them enabling new features inside your site, such as a secret forum or a list of hidden resources: there&#8217;s no better incentive for hackers than the possibility of shaping a system according to their own will!</li>
<li>if you receive a message from a user warning you about a vulnerability, consider it as a great privilege: instead of defacing you, they have sent you a constructive contribute! Try to learn more from that, correct the bug and document everything, so that all the other users will be able to learn something new from your error and from the ability of who discovered it. Finally, challenge everyone to find others: this will make the game even more interesting.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=127</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Telnet Email: access your email without a mail client</title>
		<link>http://davide.eynard.it/?p=108</link>
		<comments>http://davide.eynard.it/?p=108#comments</comments>
		<pubDate>Sun, 11 Oct 2009 10:00:33 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[hacks]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=108</guid>
		<description><![CDATA[[This is article number 1 of the new "hacks" series. Read here if you want to know more about this]
In the beginning was the command line. Then, the evolution of software saw more and more complex graphical applications, able to abstract from low-level machine operations and make work much easier for the end user. All [...]]]></description>
			<content:encoded><![CDATA[<p>[This is article number 1 of the new "hacks" series. Read <a href="http://davide.eynard.it/?p=106" target="_blank">here</a> if you want to know more about this]</p>
<p><a href="http://www.cryptonomicon.com/command.zip" target="_blank">In the beginning was the command line</a>. Then, the evolution of software saw more and more complex graphical applications, able to abstract from low-level machine operations and make work much easier for the end user. All of this, of course, had a price: the loss of control. But we are not common users&#8230; and if there is one thing we want it is having control over what happens on our computers!</p>
<p>Let&#8217;s think, for instance, about email: in most of the cases we can access our<br />
mailbox with a browser, however only through an interface which has been already defined by our provider; this interface often contains advertisements and forces us to stay connected while we read our mails. We can configure an email client and make it download our messages from the server, however this choice has its drawbacks too: what should we do, for instance, if the computer we are using is not ours? The solution to this problem is very easy: let&#8217;s come back to the origins, manually executing all the operations that an email client automatically performs whenever it downloads our emails from a server. The only tool we need is available on any computer: its name is <strong>telnet</strong> and it can be called from the command line (that is from Windows &#8220;command prompt&#8221; or from MacOSX and Linux Terminal). The data we need to know in advance are just the address and the port of our mail server, which are usually specified by our providers within the howtos for mail client configuration, together with our account&#8217;s login and password.</p>
<h3>Mail servers</h3>
<p>Mail servers available on the Internet usually belong to one of two different<br />
categories: outgoing or incoming mail. The former ones usually use SMTP (Simple Mail Transfer Protocol) and are accessed to send messages, while the latter ones use either POP3 (Post Office Protocol 3) or IMAP (Internet Message Access Protocol) and are the ones we will describe more in detail in this article, as they are used to download messages from a mailbox to our computer. Most of the times mail server addresses are built starting from your email address domain name and adding a prefix witch matches the protocol used: for instance, for gmail.com emails the outgoing server is called smtp.gmail.com, while the incoming ones are called pop.gmail.com and imap.gmail.com. A last parameter you have to specify to connect to a server is the port: the default values are 110 for POP3 and 143 for IMAP.</p>
<h3>Let&#8217;s keep things private</h3>
<p>Before starting, however, you have to be aware about the following: every time you connect to one of the ports we just described, your data will be transferred in clear. This means that anyone would be able to read what you write just by sniffing the packets that are sent over the network. Luckily, some mail servers also accept encrypted connections (see below): in this case, the default ports are 995 for POP3 and 993 for IMAP. Finally, it is good to remember that all the information you send, independently from the fact that you are using an encrypted connection or not, are shown on the screen, so you&#8217;ll better check that nobody&#8217;s near you before entering your password&#8230;</p>
<p><strong>NOTE:</strong> for those mail servers which, like gmail, require an encrypted connection, you can&#8217;t just have a simple telnet connection. However, you can use the openssl program (available <a href="http://www.slproweb.com/products/Win32OpenSSL.html" target="_blank">here</a>). The syntax to connect is the following:</p>
<pre>openssl s_client -connect &lt;server name&gt;:&lt;port&gt;</pre>
<p>For instance:</p>
<pre>openssl s_client -connect pop.gmail.com:995</pre>
<h3>Connect to the server</h3>
<p>After you have chosen the connection type and verified you have the correct data, you can finally connect to your mail server using telnet. To do this you first have to open a terminal: from the Start menu in windows, select the Run option, write the &#8220;cmd&#8221; command, then press Enter; if you have a Mac, choose the Terminal application from the folder called Application/Utilities; in linux you can find it in the Utilities or Tools section (or you can have a full screen terminal by pressing the keys CTRL+ALT+F1). Once the terminal is open, you can connect to the server by writing</p>
<pre>telnet &lt;server address&gt; &lt;port&gt;</pre>
<p>For instance:</p>
<pre>telnet pop.mydomain.com 110</pre>
<p>If the connection is opened correctly the server replies saying it is ready to<br />
receive commands. Images show the main commands you can run on a POP server and below you can find different examples of connections both to POP and IMAP servers. IMAP servers are a little more complex than POP (for instance, every command has to be preceded by a tag containing an incremental value), however it is much more powerful at the same time, as it allows you to manage your mail in folders and mark messages with specific flags. All you have to do now is experiment with this new tool, maybe a little spartan but with no restrictions imposed by proprietary interfaces, and find new ways to manage your email with telnet.</p>
<div id="attachment_117" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/img01.png"><img class="size-medium wp-image-117" title="Figure 1" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/img01-300x264.png" alt="Here's how a telnet POP3 session looks like." width="300" height="264" /></a><p class="wp-caption-text">Here&#39;s how a telnet POP3 session looks like.</p></div>
<h4>POP3</h4>
<p>The POP3 protocol is quite easy and follows the specs which appear inside <a href="http://www.ietf.org/rfc/rfc1939.txt" target="_blank">RFC1939</a>. Here&#8217;s a list of the main commands:</p>
<ul>
<li><em>USER &lt;username&gt;</em>: specifies your email account&#8217;s login</li>
<li><em>PASS &lt;password&gt;</em>: specifies (in clear) your email account&#8217;s password</li>
<li><em>STAT</em>: shows the number of messages in the mailbox and the total space they require</li>
<li><em>LIST</em>: shows a list of messages with their size</li>
<li><em>RETR &lt;message id&gt;</em>: shows the message identified by &#8220;id&#8221;</li>
<li><em>TOP &lt;message id&gt; &lt;n&gt;</em>: shows the first &lt;n&gt; rows of the message</li>
<li><em>DELE &lt;message id&gt;</em>: deletes the specified message from the server</li>
<li><em>RSET</em>: resets all the DELE operations previously performed (within the same session)</li>
<li><em>QUIT</em>: quits the POP3 session and disconnects from the server</li>
</ul>
<div id="attachment_119" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/10/img02.png"><img class="size-medium wp-image-119" title="Figure 2" src="http://davide.eynard.it/blog/wp-content/uploads/2009/10/img02-300x209.png" alt="The same mail message is checked on an IMAP server." width="300" height="209" /></a><p class="wp-caption-text">The same mail message is checked on an IMAP server.</p></div>
<h4>IMAP</h4>
<p>The IMAP protocol follows the specs of <a href="http://www.ietf.org/rfc/rfc3501.txt" target="_blank">RFC3501</a> and is far more complex than POP3. For this reason, instead of a list of commands we just show a session example, suggesting you to check the RFC or to search for &#8220;IMAP and TELNET&#8221; to get more details.</p>
<pre> 01 LOGIN &lt;login&gt; &lt;pass&gt;             authenticates on the server
 02 LIST "" *                        shows the list of available folders
 03 SELECT INBOX                     opens the INBOX folder
 04 STATUS INBOX (MESSAGES)          shows the number of messages in the current folder
 05 FETCH &lt;messagenum&gt; FULL          downloads the header of the specified message
 06 FETCH &lt;messagenum&gt; BODY[text]    downloads the body of the specified message
 07 LOGOUT                           disconnects from the server</pre>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=108</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New &#8220;hacks&#8221; series</title>
		<link>http://davide.eynard.it/?p=106</link>
		<comments>http://davide.eynard.it/?p=106#comments</comments>
		<pubDate>Sat, 10 Oct 2009 12:30:04 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[blog]]></category>
		<category><![CDATA[hacks]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=106</guid>
		<description><![CDATA[It all started last winter, when a couple of old friends asked me if I wanted to help in writing articles for an Italian magazine. The zine was targeted at young people willing to learn something more about what is going on inside their computer: some would call them wannabe hackers, I&#8217;d prefer to think [...]]]></description>
			<content:encoded><![CDATA[<p>It all started last winter, when a couple of old friends asked me if I wanted to help in writing articles for an Italian magazine. The zine was targeted at young people willing to learn something more about what is going on inside their computer: some would call them wannabe hackers, I&#8217;d prefer to think about them as potential reversers ;-)</p>
<p>Why did I accept this work? The reasons are many, including the deep respect I have for these friends, some <em>nostalgia</em> of good old times, the fact that the magazine has no ads, and finally the right to redistribute my articles online.So here they are, a collection of introductory texts that I hope will be useful for someone. If you are already an expert you will probably find nothing interesting here, but I like to think that few people really are as expert as they think.. ;)</p>
<p>So, how does it work? Well, I don&#8217;t have much time so I usually write a very short article each month. The original article is always in Italian, so I have to translate it (any help is more than welcome!). I already have a buffer long enough to keep you busy for a while, so here is my plan: one article every other Sunday for some months, then we&#8217;ll see (yeah, this does not sound like a very detailed plan :)).</p>
<p>Shall we start?</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=106</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Posts about Vocamp Ibiza 2009</title>
		<link>http://davide.eynard.it/?p=85</link>
		<comments>http://davide.eynard.it/?p=85#comments</comments>
		<pubDate>Tue, 05 May 2009 08:07:53 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=85</guid>
		<description><![CDATA[Just a couple of links to other participants&#8217; feedbacks on Ibiza VoCamp:

A post by Peter Mika
A post by Alexandre Monnin

And now that we speak about this, here&#8217;s a pic of the actual owner of our room in Ibiza: from the very first day, he followed us to the room and settled there. But we had [...]]]></description>
			<content:encoded><![CDATA[<p>Just a couple of links to other participants&#8217; feedbacks on Ibiza VoCamp:</p>
<ul>
<li>A post by <a href="http://www.ysearchblog.com/2009/04/22/sun-fun-and-search-in-ibiza/" target="_blank">Peter Mika</a></li>
<li>A post by <a href="http://urfistinfo.blogs.com/urfist_info/2009/05/see-search-and-fun.html" target="_blank">Alexandre Monnin</a></li>
</ul>
<p>And now that we speak about this, here&#8217;s a pic of the actual owner of our room in Ibiza: from the very first day, he followed us to the room and settled there. But we had our revenge: we gave it a new name, and now everyone calls it RDF.</p>
<p><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/06/P1020748.JPG"><img class="aligncenter size-medium wp-image-86" title="P1020748" src="http://davide.eynard.it/blog/wp-content/uploads/2009/06/P1020748-300x225.jpg" alt="P1020748" width="300" height="225" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=85</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SquirrelRDF-IMAP is out!</title>
		<link>http://davide.eynard.it/?p=92</link>
		<comments>http://davide.eynard.it/?p=92#comments</comments>
		<pubDate>Sat, 25 Apr 2009 12:45:06 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=92</guid>
		<description><![CDATA[At last, SquirrelRDF-IMAP code is available!

check it out from the SVN repository into Eclipse:


svn co https://svn.sourceforge.net/svnroot/jena/SquirrelRDF/trunk


add Jena libs to the project&#8217;s build path (I tested Jena 2.5.6 and it works fine)


the class to run is com.hp.hpl.squirrelrdf.imap.test.Scratch.java, a very very simple app which loads a ready made SPARQL query and sends a request to a gmail [...]]]></description>
			<content:encoded><![CDATA[<p>At last, SquirrelRDF-IMAP code is available!</p>
<ul>
<li>check it out from the SVN repository into Eclipse:</li>
</ul>
<blockquote>
<pre>svn co https://svn.sourceforge.net/svnroot/jena/SquirrelRDF/trunk</pre>
</blockquote>
<ul>
<li>add Jena libs to the project&#8217;s build path (I tested Jena 2.5.6 and it works fine)</li>
</ul>
<ul>
<li>the class to run is com.hp.hpl.squirrelrdf.imap.test.Scratch.java, a very very simple app which loads a ready made SPARQL query and sends a request to a gmail account I had set up for tests</li>
</ul>
<ul>
<li> inside &#8220;examples&#8221; you can find the file <em>imap_map.n3</em> which contains the configuration. From here you can set up access to your own email accounts or the way mapping is done between my dummy email ontology and IMAP requests. In the &#8220;queries&#8221; directory you can find some example queries.</li>
</ul>
<p>The tool is still very rudimental but I think it already gives an idea about some of the potentialities of querying mailboxes with SPARQL, meshing up data from different sources etc. If you are interested in the details there&#8217;s also a techreport about this work <a href="http://www.hpl.hp.com/techreports/2007/HPL-2007-161.pdf" target="_blank">here</a>.</p>
<p>A big&#8230; well, HUGE thanks to Damian Steer who allowed me to integrate the IMAP plugin code into the official SquirrelRDF trunk!</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=92</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>People from Ibiza</title>
		<link>http://davide.eynard.it/?p=79</link>
		<comments>http://davide.eynard.it/?p=79#comments</comments>
		<pubDate>Mon, 20 Apr 2009 14:16:58 +0000</pubDate>
		<dc:creator>+mala</dc:creator>
				<category><![CDATA[research]]></category>

		<guid isPermaLink="false">http://davide.eynard.it/?p=79</guid>
		<description><![CDATA[Got back from Vocamp Ibiza + Future of Web Search 2009 Workshop. Just one word: great!
I spent a great time there and came back enlightened and with a lot of enthusiasm. Hope that will last long enough to produce something interesting :-)
Tom Heath has put some photos on Flickr. Enjoy!
]]></description>
			<content:encoded><![CDATA[<p>Got back from <a href="http://vocamp.org/wiki/VoCampIbiza2009">Vocamp Ibiza</a> + <a href="http://grupoweb.upf.es/tfws09/" target="_self">Future of Web Search 2009 Workshop</a>. Just one word: great!</p>
<div id="attachment_80" class="wp-caption aligncenter" style="width: 310px"><a href="http://davide.eynard.it/blog/wp-content/uploads/2009/06/P1020759.JPG"><img class="size-medium wp-image-80" title="P1020759" src="http://davide.eynard.it/blog/wp-content/uploads/2009/06/P1020759-300x225.jpg" alt="VoCampers at work" width="300" height="225" /></a><p class="wp-caption-text">VoCampers at work</p></div>
<p>I spent a great time there and came back enlightened and with a lot of enthusiasm. Hope that will last long enough to produce something interesting :-)</p>
<p><a href="http://tomheath.com/home/html" target="_blank">Tom Heath</a> has put some photos on <a href="http://www.flickr.com/photos/tommyh/sets/72157616947007621/" target="_blank">Flickr</a>. Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://davide.eynard.it/?feed=rss2&amp;p=79</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
