Kademlia over HTTP
a Javascript framework bringing DHT to mobile applications
Alexandre Lachèze Pierre Guilleminot
KadOH Kademlia over HTTP a Javascript framework bringing DHT to - - PowerPoint PPT Presentation
Alexandre Lachze Pierre Guilleminot KadOH Kademlia over HTTP a Javascript framework bringing DHT to mobile applications What have been done so far in the DHT landscape ? * * Distributed Hash Table Theoretical resuts Chord Kademlia
Kademlia over HTTP
a Javascript framework bringing DHT to mobile applications
Alexandre Lachèze Pierre Guilleminot
* * Distributed Hash Table
Chord Kademlia Improvement proposals
File sharing eMule BitTorrent’s Mainline
Ignored by DHTs Huge and growing audience Private data
taking advantage of DHTs scalability
improving privacy protections
a.k.a. KadOH
Common problem on obstrusive cellular networks
highly restrictive firewalls technicaly impossible need a for third party router
Develop our own router ?
Router
Develop our own routers ?
Router Router
s2s
distributed
Develop our own routers ?
heavy does not scale against the end-to-end principle
Unsing the XMPP infrastructures
GTalk
Jabber.com
peer to peer messaging distributed – already scaled
eXtensible Messaging and Presence Protocol
based on XML made for instant messaging and extensible
<message from='juliet@jabber.org’ to='romeo@jabber.org' xml:lang='en'> <body>Art thou not Romeo, and a Montague? <3</body> </message>
TCP
But in the browser ?
bosh bosh
GTalk
Jabber.com
Bidirectional-streams Over Synchronous HTTP XHR long polling XMPP in browser
ValueManagement
Node RoutingTable
Reactor
KBucket
*
1 1 1 1 1 1
Transport
(XMPP, UDP, ..)1 1 1
RPC
*
1
FindNodeRPC StoreRPC FindValueRPC PingRPC
IterativeFind
1
*
modular extensible independant parts highly hackable
node = new KadOH.Node(id, options)
Instantation
node.connect(function() { node.join(); });
Connection and joining
node.put('0beec7b5ea3f0fdbc95d0dd47f3c5bc275da8a33', 'Hello world !');
Store
node.get('62cdb7020ff920e5aa642c3d4066950dd1f01f4d', function(value) { alert(value); });
Retrieve
...but possibility to access to lower level functions
Amazon EC2
EC2 instance
elastic ip
EC2 instance EC2 instance
botfork process
bootstraps
XMPP server
bosh
Bar.com
testing device
Non resolved Iterative find - time (ms)
5000 10000 15000 20000 250 500 750 1000 1500 2000 3000 3500Resolved Iterative find - time (ms) chrome firefox iphone-wifi iphone-3g
A Javascript framework implementing Kademlia in browsers using XMPP over HTTP
https://github.com/jinroh/kadoh http://jinroh.github.com/kadoh/