<?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>fak3r &#187; networking</title> <atom:link href="http://fak3r.com/tag/networking/feed/" rel="self" type="application/rss+xml" /><link>http://fak3r.com</link> <description>look out honey &#039;cause I&#039;m using technology</description> <lastBuildDate>Fri, 03 Sep 2010 12:36:55 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <item><title>HOWTO: disable IPv6 networking in Debian</title><link>http://fak3r.com/2008/12/02/howto-disable-ipv6-networking-in-debian/</link> <comments>http://fak3r.com/2008/12/02/howto-disable-ipv6-networking-in-debian/#comments</comments> <pubDate>Wed, 03 Dec 2008 04:45:39 +0000</pubDate> <dc:creator>fak3r</dc:creator> <category><![CDATA[geek]]></category> <category><![CDATA[howto]]></category> <category><![CDATA[2.6 kernel]]></category> <category><![CDATA[debian]]></category> <category><![CDATA[disable]]></category> <category><![CDATA[ipv6]]></category> <category><![CDATA[linux]]></category> <category><![CDATA[networking]]></category> <category><![CDATA[ports]]></category> <category><![CDATA[security]]></category><guid isPermaLink="false">http://www.fak3r.com/?p=1210</guid> <description><![CDATA[Tonight I did ran netstat (`netstat -plunt`) on my Debian server and saw that I had some ports listening via IPv6.  It&#8217;s a shame IPv6 hasn&#8217;t caught on as it&#8217;s better than IPv4 in virtually every way, and it should, especially since TCP/IPv4 was standardized in ARPANET RFC&#8217;s&#8230; in 1981!  Also, IPv6 provides network level [...]]]></description> <content:encoded><![CDATA[<div id="attachment_1213" class="wp-caption alignright" style="width: 116px"><a href="http://www.fak3r.com/wp-content/uploads/2008/12/ipv6_ready_logo_phase1.png"><img class="size-medium wp-image-1213" title="IPv6 ready...really?  who?" src="http://www.fak3r.com/wp-content/uploads/2008/12/ipv6_ready_logo_phase1.png" alt="" width="106" height="126" /></a><p class="wp-caption-text">IPv6 is ready?</p></div><p>Tonight I did ran netstat (`netstat -plunt`) on my <a href="http://debian.org">Debian</a> server and saw that I had some ports listening via <a href="http://en.wikipedia.org/wiki/IPv6">IPv6</a>.  It&#8217;s a shame IPv6 hasn&#8217;t caught on as it&#8217;s better than IPv4 in virtually every way, and it should, especially since <a href="http://ntrg.cs.tcd.ie/undergrad/4ba2/ipng/gerd.ipv4.html">TCP/IPv4 was standardized in ARPANET RFC&#8217;s</a>&#8230; in 1981!  Also,  IPv6 provides network level security via IPSec, which enables authentication of sender and encryption of communication  path, to secure communications, all fun stuff, but while some point to the fact that the Beijing Olympics used IPv6 exclusively as a point in how far it&#8217;s come, that&#8217;s hardly saying much when the protocol went Alpha&#8230; in <strong>1996</strong>!  I mean I put things off and get distracted, sure, but come on!  So while its adoption can be argued to be a case of <a href="http://robert.accettura.com/blog/2008/08/18/nobody-is-using-ipv6/">the chicken before the egg</a>, since I&#8217;m not using anything IPv6, nor do I or my ISP even have the capability to use it, it&#8217;s silly and perhaps dangerous to leave it running with open ports.  So, if you&#8217;re not using it, disable it &#8211; it&#8217;s easy, just put on your pointy hat and follow along&#8230;<span id="more-1210"></span> First we need to edit:</p><pre>/etc/modprobe.d/aliases</pre><p>By default you will have a line like this:</p><pre>alias net-pf-10 ipv6</pre><p>Replace that line with:</p><pre>alias net-pf-10 off
alias ipv6 off</pre><p><em>(The second line may/may not be required with newer (2.26.+) kernels, but it won&#8217;t hurt anything)</em></p><p>Also, while we&#8217;re at it, on your desktop machines, help out Firefox by disabling IPv6 there too.  It&#8217;s simple, in the location bar enter:</p><pre>about:config</pre><p>Then search for:</p><pre>network.dns.disableIPv6</pre><p>and toggle its value to &#8216;<strong>true</strong>&#8216;</p><p>Well, that&#8217;s it, you&#8217;re now surfing with 1980s technology (just like 99.098% of the internet!)</p> ]]></content:encoded> <wfw:commentRss>http://fak3r.com/2008/12/02/howto-disable-ipv6-networking-in-debian/feed/</wfw:commentRss> <slash:comments>20</slash:comments> </item> <item><title>Army: Twitter could be a terrorist tool</title><link>http://fak3r.com/2008/10/27/army-twitter-could-be-a-terrorist-tool/</link> <comments>http://fak3r.com/2008/10/27/army-twitter-could-be-a-terrorist-tool/#comments</comments> <pubDate>Tue, 28 Oct 2008 02:39:03 +0000</pubDate> <dc:creator>fak3r</dc:creator> <category><![CDATA[geek]]></category> <category><![CDATA[al qaida]]></category> <category><![CDATA[arabic language]]></category> <category><![CDATA[cell phone]]></category> <category><![CDATA[google maps]]></category> <category><![CDATA[Hezbollah]]></category> <category><![CDATA[im]]></category> <category><![CDATA[networking]]></category> <category><![CDATA[skype]]></category> <category><![CDATA[terror]]></category> <category><![CDATA[terrorism]]></category> <category><![CDATA[tweets]]></category> <category><![CDATA[twitter]]></category><guid isPermaLink="false">http://www.fak3r.com/?p=1120</guid> <description><![CDATA[Hmmm&#8230;so the Army has claimed that terrorists may be &#8216;tweeting&#8217; along to plan and organize attacks. Well yeah, I guess they could use Gmail, Slashdot comments and other things the same way, it seems their claim is that since this is more &#8216;real time&#8217; it could be a danger. Ok, oh, and they take a [...]]]></description> <content:encoded><![CDATA[<div id="attachment_1135" class="wp-caption alignright" style="width: 138px"><a href="http://www.fak3r.com/wp-content/uploads/2008/10/twitter-logo.png"><img class="size-full wp-image-1135" title="twitter-logo" src="http://www.fak3r.com/wp-content/uploads/2008/10/twitter-logo.png" alt="Tweet, tweet, bomb, bomb" width="128" height="128" /></a><p class="wp-caption-text">Tweet, tweet, bomb?</p></div><p>Hmmm&#8230;so the Army has claimed that terrorists may be &#8216;tweeting&#8217; along to <a href="http://www.instantmessagingplanet.com/security/article.php/3780961">plan and organize attacks</a>.  Well yeah, I guess they could use Gmail, Slashdot comments and other things the same way, it seems their claim is that since this is more &#8216;real time&#8217; it could be a danger.  Ok, oh, and they take a swipe at Skype as well.  Additionally they define a new name I would happily accept, <em>&#8220;The report describes hacktivists as politically motivated hackers</em>&#8220;.  Hacktvist, that&#8217;s awesome.  The report goes on with,</p><blockquote><p>&#8220;The &#8216;Twitter&#8217; member can send Tweets (messages) near real time to Twitter cell phone groups and to their online Twitter social networking page,&#8221; the author said, adding that &#8220;there are multiple pro- and anti-Hezbollah Tweets.&#8221;</p><p>Twitter members &#8220;can also mashup their Tweets with a variety of other tools including geo-coordinates and Google Maps or other electronic files/artifacts. Members can direct and re-direct audience members to other Web sites and locations from &#8216;Tweets&#8217; and can engage in rapid-fire group social interaction,&#8221; the writer said.</p><p>The author outlined three scenarios where Twitter could be used by terrorists, and pointed out that terrorists have also talked about using other technologies, including cell phones, and <a href="http://networking.webopedia.com/SHARED/search_action.asp?Term=SKYPE&amp;Template_Name=networking.webopedia.com"> Skype</a> and other internet telephony services.</p><p>The author, who did not sign the paper, warned that most of the information came from &#8220;al-Qaida-like Web sites from &#8216;uncorroborated&#8217; postings made by terrorists&#8221; and &#8220;persons sympathetic to terrorism.&#8221; Only &#8220;rudimentary Arabic language skills and the Google translating tool&#8221; were used.</p></blockquote><p>There&#8217;s no doubt that &#8216;terrorists&#8217; will use any means necessary to accomplish their goals, but is this really something to take seriously?</p> ]]></content:encoded> <wfw:commentRss>http://fak3r.com/2008/10/27/army-twitter-could-be-a-terrorist-tool/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> <item><title>Distributing biodiversity data globally</title><link>http://fak3r.com/2008/10/09/distributing-biodiversity-data-globally/</link> <comments>http://fak3r.com/2008/10/09/distributing-biodiversity-data-globally/#comments</comments> <pubDate>Thu, 09 Oct 2008 18:00:25 +0000</pubDate> <dc:creator>fak3r</dc:creator> <category><![CDATA[geek]]></category> <category><![CDATA[biodiversity]]></category> <category><![CDATA[bittorrent]]></category> <category><![CDATA[bittorrent protocol]]></category> <category><![CDATA[community]]></category> <category><![CDATA[debian]]></category> <category><![CDATA[library]]></category> <category><![CDATA[networking]]></category> <category><![CDATA[open source]]></category> <category><![CDATA[performance]]></category> <category><![CDATA[systems]]></category><guid isPermaLink="false">http://www.fak3r.com/?p=1082</guid> <description><![CDATA[My current project at work will take me far into next year, and that&#8217;s good because I&#8217;m facing an unprecedented amount of data, that will only continue to grow.  Because of this I&#8217;m finally getting to put my money where my mouth is.  For years I&#8217;ve talked about my ideas and theories about how I [...]]]></description> <content:encoded><![CDATA[<p><img class="alignright size-full wp-image-1111" title="BitTorrent logo" src="http://www.fak3r.com/wp-content/uploads/2008/10/bittorrent_logo.gif" alt="" width="128" height="128" />My current project at work will take me far into next year, and that&#8217;s good because I&#8217;m facing an unprecedented amount of data, that will only continue to grow.  Because of this I&#8217;m finally getting to put my money where my mouth is.  For years I&#8217;ve talked about my ideas and theories about how I could network disparate systems together and have them leverage each other to keep everything in sync.  So, while working with Open Source to push boundaries I seem to find more ways to do more complex things.  One basic idea that I&#8217;m working on now is that data sets are huge, and are only going to get huger (and hugerer) as time goes on, how to handle this has been solved a few different ways.  Usually it&#8217;s someone like the <a href="http://www.archive.org/index.php">Internet Archive</a> who have 1000s of computers networked together to share the data (they are using some parts of <a href="http://hadoop.apache.org/core/">hadoop</a> for the distributed file system, and then <a href="http://lucene.apache.org/nutch/">nutch</a> for search indexing) &#8211; but it&#8217;s still working from one central point of failure.  I started doing research to find out how this has been solved before, and if my idea of building a <a href="http://en.wikipedia.org/wiki/BitTorrent_(protocol)">BitTorrent</a> network was sound &#8211; and I found some great information to build on.  As I&#8217;m setting up my demo BitTorrent tracker in Debian, this info keeps me thinking of the best ways to implement my ideas.  Much of my progress is due to the very helpful advice of Paul at <a href="http://torrents.geograph.org.uk/index.php">Geograph Torrent Archive</a>, a project that has somewhat similar goals.<span id="more-1082"></span></p><p>First, a great first introduction of what bittorrent is, and what it accomplishes:</p><blockquote><p>&#8220;BitTorrent does not centrally manage resource allocation. Instead, each client attempts to maximise its download rate by controlling various protocol parameters. Clients make direct connections (using ports 6881-6889 by default) to one or more of the clients in the list, to exchange parts of the file. Direct connections between clients are duplex (bi-directional), and every client tries to maintain the greatest number of active connections. A client&#8217;s refusal to upload temporarily is known as choking. Connections are choked to prevent leeching a situation where another client is downloading, but not uploading.</p><p>To maximize the number of duplex connections, clients reward each other by reciprocating uploads. So clients unwilling to upload will find their download rate dropping as other clients choke in response. Clients decide which connections to choke or unchoke by calculating the current download rate of each connection, once every ten seconds. The connection is left choked or unchoked until the next ten-second period is up. This fixed interval cycle prevents clients from rapidly choking and unchoking, causing network resources to be wasted. Finally, a client does an &#8220;optimistic&#8221; unchoke, once every 30 seconds, to try out unused connections to determine if they might offer better transfer rates than current ones.&#8221; [<a href="http://www.technetra.com/writings/archive/2004/04/25/bittorrent-a-p2p-file-sharing-protocol">link</a>]</p></blockquote><p>Now on to comments by others in how to use/harness this system for data propogation:</p><blockquote><p>&#8220;One idea that does linger in my head is the idea of creating a bittorrent distribution channel for library cataloging data. In the podcast, a concern was raised on whether a single server such as Library of Congress&#8217;s might be serverely impacted if a lot of requests were made against its SRU server. If all the hopes of Casey Bisson&#8217;s gift to the library community are realized, what if libraries were to contribute their individual cataloging and authority records to a global torrent? Again, I don&#8217;t see the value of a single large file, like MIT&#8217;s Barton data, over distribution of individual records. In the real world, torrent sharing is mostly at the work-level and that would seem to be the logical way to handle library records.&#8221; [<a href="http://www.tomkeays.com/blog/archives/2006/12/18/004216.php">link</a>]</p></blockquote><blockquote><p>&#8220;Institutional repositories &#8211; I don’t hear as much noise about institutional repositories as I used to hear. I think their lack of popularity is directly related to the problems they are designed to solve, namely, long-term access. Don’t get me wrong, long-term access is definitely a good thing, but that is a library value. In order to be compelling, institutional repositories need to solve the problems of depositors, not the librarians. What do authors get by putting their content in an institutional repository that they don’t get elsewhere? If they supported version control, collaboration, commenting, tagging, better syndication and possibilities for content reuse — in other words, services against the content — then institutional repositories might prove to be more popular.&#8221; [<a href="http://infomotions.com/blog/2008/06/top-tech-trends-for-ala-summer-08/">link</a>]</p></blockquote><blockquote><p>&#8220;Of particular interest here is how such a description of BitTorrent intersects on certain points (which I have emphasized above) with larger conversations and concerns campus IT organizations are currently having regarding the increasingly prohibitive costs of owning, maintaining, and monitoring data services locally. In fact, this an issue with much larger scope that is not limited to the education sector by any means. Much of this is a result of our particular moment wherein a plethora of externally hosted options provide college communities the same, if not better, services with infinitely more storage space. And all of this at a fraction of the cost. For some campus IT shops in the business of supporting themselves financially, or even making money, the risks of not going in such a direction are much more dire. The recent news that the University of Washington’s IT department will be laying off 15% of their staff speaks directly to this. In fact, a number of schools have already begun offloading IT staples such as file storage and email to externally hosted solutions. Arizona State University was one of the the first large universities to do this in a deal with Google back in the Fall of 2006, and it is a trend we will continue to see much more of in the coming months and years, particularly as budgets shrink and the economy continues to tank.&#8221; [<a href="http://bavatuesdays.com/bittorrent-an-educational-autopsy-of-the-hydra/">link</a>]</p></blockquote><blockquote><p>&#8220;[...] bioinformatics networks present unique networking challenges that typically can&#8217;t be addressed by generic network installations. The first is that there is a huge amount of data involved. The network isn&#8217;t handling short e-mail messages typical of the corporate environment, but massive sequence strings, images, and other data. In addition, unlike networks that support traditional business transaction processing, data are continually flowing from disk arrays, servers, and other sources to computers for processing because the data can&#8217;t fit into computer RAM. As a result, the network and external data sources are in effect extensions of the computer bus, and the performance of the network limits the overall performance of the system. It doesn&#8217;t matter whether the computer processor is capable of processing several hundred million operations per second if the network feeding data from the disks to the computer has a throughput of only 4–5 Mbps.&#8221; [<a href="http://www.informit.com/articles/article.aspx?p=32102">link</a>]</p></blockquote> ]]></content:encoded> <wfw:commentRss>http://fak3r.com/2008/10/09/distributing-biodiversity-data-globally/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>HOWTO: webserver in 100 lines of Bash</title><link>http://fak3r.com/2008/09/04/howto-webserver-in-100-lines-of-bash/</link> <comments>http://fak3r.com/2008/09/04/howto-webserver-in-100-lines-of-bash/#comments</comments> <pubDate>Fri, 05 Sep 2008 00:48:38 +0000</pubDate> <dc:creator>fak3r</dc:creator> <category><![CDATA[geek]]></category> <category><![CDATA[howto]]></category> <category><![CDATA[bash]]></category> <category><![CDATA[code]]></category> <category><![CDATA[hack]]></category> <category><![CDATA[netcat]]></category> <category><![CDATA[networking]]></category> <category><![CDATA[perl]]></category> <category><![CDATA[system]]></category> <category><![CDATA[webserver]]></category> <category><![CDATA[www]]></category><guid isPermaLink="false">http://fak3r.com/?p=955</guid> <description><![CDATA[I&#8217;m a big Bash fan, I know Perl is the more popular scripting language, and I&#8217;m slowly using it more, but hey, if I need something done, I can do it quicker in Bash (keeping in mind that I&#8217;m a systems guy, not a dev guy). While at work looking up Bash related syntax I [...]]]></description> <content:encoded><![CDATA[<p><a href="http://www.fak3r.com/wp-content/uploads/2008/03/opensource.png"><img class="alignright size-medium wp-image-757" title="Open Source" src="http://www.fak3r.com/wp-content/uploads/2008/03/opensource.png" alt="" width="150" height="129" /></a>I&#8217;m a big <a href="http://netcat.sourceforge.net/">Bash</a> fan, I know <a href="http://netcat.sourceforge.net/">Perl</a> is the more popular scripting language, and I&#8217;m slowly using it more, but hey, if I need something done, I can do it quicker in Bash (keeping in mind that I&#8217;m a systems guy, not a dev guy).  While at work looking up Bash related syntax I came across a page describing <a href="http://quake.wikidot.com/www-server-in-100-lines-bash-script">how to run a webserver with 100 lines of Bash</a>.  It uses the old school GNU utility <a href="http://netcat.sourceforge.net/">Netcat</a> (nc) for communication between the pipes, and just a ton of basic logic and functions to pass it on to the user.  It&#8217;s one of those things I look at and can&#8217;t believe it works, but it does.  Of course security is unknown, as is the original author, but I consider this a reference on how to do networking things in Bash; who knows what I&#8217;ll use (parts) of it for.  If anyone has details on who originally wrote this I&#8217;m all ears.[sourcecode language='xml']#!/bin/bash</p><p>function debug {<br /> local severity=&#8221;$1&#8243;<br /> shift<br /> local message=&#8221;$@&#8221;</p><p>echo -n &#8220;`date -u`&#8221;    1>&amp;amp;2<br /> echo -ne &#8216;\t&#8217;        1>&amp;amp;2<br /> echo -n &#8220;$severity&#8221;    1>&amp;amp;2<br /> echo -ne &#8216;\t&#8217;        1>&amp;amp;2<br /> echo &#8220;$message&#8221;        1>&amp;amp;2<br /> }</p><p>function fix_path {<br /> echo -n &#8220;$1&#8243; | head -n 1 | sed &#8216;s|^[/.-]*||&#8217; | sed &#8216;s|/\.*|/|g&#8217;<br /> }</p><p>function serve_dir {<br /> local dir=&#8221;`fix_path &#8220;$1&#8243;`&#8221;<br /> if [ "$dir" = "" ]; then<br /> dir=&#8221;./&#8221;<br /> fi<br /> echo &#8216;HTTP/1.1 200 OK&#8217;<br /> echo &#8216;Content-type: text/html;charset=UTF-8&#8242;<br /> echo<br /> echo LISTING &#8220;$dir&#8221;<br /> echo &#8216;<br />&#8216;<br /> ls -p &#8220;$dir&#8221; | sed -e &#8216;s|^\(.*\)$|<a href="/'"$dir"'\1">\1</a><br />|&#8217;<br /> }</p><p>function serve_file {<br /> echo &#8216;HTTP/1.1 200 OK&#8217;<br /> echo &#8216;Content-type: application/x-download-this&#8217;<br /> echo<br /> local file=&#8221;`fix_path &#8220;$1&#8243;`&#8221;<br /> debug INFO serving file &#8220;$file&#8221;<br /> cat &#8220;$file&#8221;<br /> }</p><p>function process {<br /> local url=&#8221;`gawk &#8216;{print $2}&#8217; | head -n 1`&#8221;<br /> case &#8220;$url&#8221; in<br /> */)<br /> debug INFO Processing &#8220;$url&#8221; as dir<br /> serve_dir &#8220;$url&#8221;<br /> break<br /> ;;<br /> *)<br /> debug INFO Processing &#8220;$url&#8221; as file<br /> serve_file &#8220;$url&#8221;<br /> ;;<br /> esac<br /> }</p><p>function serve {<br /> local port=&#8221;$1&#8243;<br /> local sin=&#8221;$2&#8243;<br /> local sout=&#8221;$3&#8243;</p><p>while debug INFO Running nc; do</p><p>nc -l -p &#8220;$port&#8221; < "$sin" > &#8220;$sout&#8221; &amp;amp;<br /> pid=&#8221;$!&#8221;</p><p>debug INFO Server PID: &#8220;$pid&#8221;</p><p>trap cleanup SIGINT<br /> head -n 1 &#8220;$sout&#8221; | process > &#8220;$sin&#8221;<br /> trap &#8211; SIGINT</p><p>debug INFO Killing nc</p><p>kill &#8220;$pid&#8221;<br /> done</p><p>debug INFO Quiting server<br /> }</p><p>function cleanup {<br /> debug INFO Caught signal, quitting&#8230;<br /> rm -Rf &#8220;$tmp_dir&#8221;<br /> exit<br /> }</p><p>tmp_dir=&#8221;`mktemp -d -t http_server.XXXXXXXXXX`&#8221;<br /> sin=&#8221;$tmp_dir&#8221;/in<br /> sout=&#8221;$tmp_dir&#8221;/out<br /> pid=0<br /> port=&#8221;$1&#8243;</p><p>mkfifo &#8220;$sin&#8221;<br /> mkfifo &#8220;$sout&#8221;</p><p>debug INFO Starting server on port &#8220;$port&#8221;<br /> serve &#8220;$port&#8221; &#8220;$sin&#8221; &#8220;$sout&#8221;<br /> cleanup[/sourcecode]</p> ]]></content:encoded> <wfw:commentRss>http://fak3r.com/2008/09/04/howto-webserver-in-100-lines-of-bash/feed/</wfw:commentRss> <slash:comments>7</slash:comments> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using memcached
Page Caching using memcached (user agent is rejected)
Database Caching using memcached
Object Caching 419/479 objects using memcached

Served from: fak3r.com @ 2010-09-10 06:51:03 -->