Slashdot Mirror


P2P Through Firewalls

An anonymous submitter writes "A few stream-through-firewall applications have been announced recently. p2pnet has an interview with Ian Clarke about his new 'Dijjer' program, which promises to reduce bandwidth requirements from HTTP servers by transparently distributing the load. Slyck.com has an article about LimeWire's new version that offers firewall-to-firewall transfers (code here). [Both Dijjer and LimeWire are GPL'd.] There's also been a lot of discussion on the p2p hackers list about reliable UDP transfers."

48 of 220 comments (clear)

  1. please dont by Spy+Hunter · · Score: 5, Funny

    Haha, so much for their "please avoid submitting it to any high-traffic web sites, it is not yet ready for primetime" policy. Good work, anonymous submitter.

    --
    main(c,r){for(r=32;r;) printf(++c>31?c=!r--,"\n":c<r?" ":~c&r?" `":" #");}
    1. Re:please dont by nocomment · · Score: 3, Insightful

      hmmm. I don't care if it's ready for primetime or not. GTK-Gnutella works just fine with firewalls.

      --
      /* oops I accidentally made a comment, sorry */
      /* http://allyourbasearebelongto.us */
    2. Re:please dont by Jugalator · · Score: 2, Informative
      The page has now been updated:

      Welcome Slashdotters

      Ok, I guess the "please don't submit to high traffic websites" in red wasn't enough, perhaps I should have used <blink> tags ;-) Since you are here, please heed the warning that this is at an early stage of development, if you are interested please sign up to our announcement mailing list so that we can let you know when its ready for primetime. Otherwise, we do need testers, so feel free to poke around.

      --
      Beware: In C++, your friends can see your privates!
  2. I don't know about you by recursiv · · Score: 4, Interesting
    --
    I used to bulls-eye womp-rats in my pants
    1. Re:I don't know about you by sameb · · Score: 5, Informative

      LimeWire doesn't have any spyware, at all. In fact, it has absolutely zero bundled software. Even with the free version.

    2. Re:I don't know about you by NardofDoom · · Score: 4, Funny

      It's also poorly coded Java that runs slower than a retarded snail on NyQuil. That's reason enough for me to avoid it.

      --
      You have two hands and one brain, so always code twice as much as you think!
  3. But... by remigo · · Score: 5, Insightful

    But... I thought that peer-to-peer sharing was horribly immoral and only used for warez and porn!!

    Seriously, though, this is the kind of thing that I desperately wish mainstream media/Congress paid more attention to. It's only the lawsuits and illegal uses that get covered because that's what sells ads.

    1. Re:But... by Swamii · · Score: 5, Funny

      But... I thought that peer-to-peer sharing was horribly immoral and only used for warez and porn!!

      No, it's used for warez, porn and mp3s.

      --
      Tech, life, family, faith: Give me a visit
  4. Text of interview by Anonymous Coward · · Score: 5, Informative

    p2pnet.net News:- Freenet author Ian Clarke is developing Dijjer, a new open source p2p content distribution tool, and he's looking for people to test drive it before it goes online in beta.

    "Dijjer is a peer-to-peer HTTP cache, designed to allow the distribution of large files from Web servers while virtually eliminating the bandwidth cost to the file's publisher," he told p2pnet.

    "Dijjer is designed to be simple, elegant, and to cleanly integrate with existing applications where possible. Dijjer uses "UDP hole punching" to allow it to operate from behind firewalls without any need for manual reconfiguration.

    "Dijjer's distributed and scalable content distribution algorithm is inspired by Freenet."

    Below is a brief Q&A.

    p2pnet: When did you start working on this?

    Clarke: Several months ago. It's hard to pinpoint a specific time because it's a combination of a variety of ideas that have been at the back of my mind for quite some time.

    p2pnet: What prompted you?

    Clarke: Dissatisfaction with apps like BitTorrent, and a desire to demonstrate that the ideas behind Freenet could be applied to solve other problems.

    p2pnet: When do you expect (hope) it'll be completed?

    Clarke: Well, I'm sure that development will continue for quite some time, but I hope to release a beta version in four to eight weeks that will be suitable for large-scale adoption.

    p2pnet: Who do you see as the principle users?

    Clarke: Anyone who needs to distribute large files to large numbers of people but who can't afford to pay for the bandwidth that this would normally require.

    The download site says features include:

    "No Firewall configuration
    With many P2P applications you must reconfigure your firewall to get the most out of them. Not so with Dijjer, we use state-of-the-art "NAT2NAT" techniques to get the most out of your internet connection without any reconfiguration.

    "Sequential downloads
    If you tried to download a video through Dijjer you may have noticed that you could start watching the video before the download completed. This is because Dijjer behaves like a web server, pieces of a file are download in-order and fed to your web browser when they arrive, allowing your browser to start displaying content before it has completely downloaded.

    "No "Tracker" necessary, works with virtually any URL
    This is a big one, Dijjer will work with almost any direct URL, the content publisher doesn't need to lift a finger - they may not even realise that people are using Dijjer to save their bandwidth costs!

    "Cross platform and native compilable
    Dijjer is implemented in Java, meaning that it will run on Windows, Linux, and Macs. Those who don't wish to install the Java Runtime Environment (JRE) will be pleased to note that Dijjer can be compiled with the GNU Compiler for Java (JCJ) to native code thus eliminating the need for a JRE. Native compiled versions of Dijjer will be available from this site in due course.

    "Free as in Speech
    Dijjer will be released under the GNU Public License.

    "No cumbersome clients
    Dijjer downloads through your web browser or preffered HTTP download application. You don't need to learn to use yet another P2P client user interface.

    "Advanced scalable distributed caching algorithm
    Dijjer uses a highly scalable distributed caching algorithm inspired by Freenet. This will allow it to deliver faster download speeds while placing less burden on the web server, and will be better able to handle sudden increases in demand for content."

    "Now all I need are some people to help me test it,"says Clarke.

    1. Re:Text of interview by Elwood+P+Dowd · · Score: 3, Funny

      Dijjer uses a highly scalable distributed caching algorithm inspired by Freenet. This will allow it to deliver faster download speeds while placing less burden on the web server, and will be better able to handle sudden increases in demand for content.

      Sweet! Maybe it will be as fast as Freenet!

      --

      There are no trails. There are no trees out here.
  5. Been waiting for this! by nhnfreespirit · · Score: 2, Interesting

    It has been a long running discussion in my project lab at the university, how to make a p2p program (in our example, Skype) work between two networks using NAT-firewalls.

    Seems like somebody finally came up with the answer! :-)

    Freespirit

    1. Re:Been waiting for this! by Stephen+Samuel · · Score: 2, Interesting
      So wierd: I woke up this morning with the same idea in my head. I finally tried using gtk-gnutella this weekend, and noticed that it was having problems with my firewall. I started thinking about how to punch thru a firewall without having to manually reconfigure and came up with the same solution.

      Essentially, UDP is a stateless system, so stateful firewalls don't have SYN packets to signal the start of a connection, so you can do the following

      • Machine A sends a UDP packet from port X to machine B Port Y, and
        • Machine A's firewall will create a connection for the outgoing address/port pair
        • (Machine B's firewall will drop the packet because there is no connection associated with it)
      • Machine B then sends a UDP packet from port Y to machine A Port X
        • Machine B's firewall will create a connection based on the address/port pair.
        • Machine A's firewall will accept (and route) the connection as belonging to a legitmate connection.
      • All further connections between A and B based on this address/port pair should work until further notice
      Note that this will not work on firewalls that use port randomizing on outgoing connections. More work has to be done to make that work. This also (obviously) requires a mediating connection where the two can agree on what addresses and ports to send from and to. (If a machine is inside of a NAT it may not realize what it's post-translated address is).
      As long as you don't have port randomizing, this should work on both NATed and non-NATed statefull firewalls.
      --
      Free Software: Like love, it grows best when given away.
  6. Reliable... udp... transfers? by 192939495969798999 · · Score: 5, Insightful

    It strikes me that one could set up a server to cache udp requests and serve them back out to the attached/requested clients reliably. However, one must wonder why not just use TCP, which is guaranteed to be reliable. IMHO, What you'd end up with using UDP is a LOT of "did you get it? yes/no"-type network traffic between peers.

    --
    stuff |
    1. Re:Reliable... udp... transfers? by Anonymous Coward · · Score: 5, Informative

      TCP has slow start / back-off retransmit problems that for long transfers over links with some packet loss can cause it to not fully use the pipe.

      Most modern UDP transfer systems use NACKing, where the receiver just tells the sender if it didn't get a packet (the packets are numbered sequentially) and that it should put it in the retransmit queue. The sender just goes about it's business spewing out packets until it's informed the receiver didn't get one.

    2. Re:Reliable... udp... transfers? by crow · · Score: 3, Informative

      UDP has advantages and disadvantages.

      UDP is connectionless--you just send a packet to a given IP/port and it goes there. This means that you can forge the from address to make it impossible to tell who is sending the file (provided your ISP doesn't filter those as bogus packets). Of course, you still need some way to get the request from the recipient to the sender (along with re-requests for lost packets).

      UDP has no flow control--the sender sends as fast has he likes without any knowledge as to what the maximum bandwidth on the connection is. If the sender's direct upstream connection is the bottleneck, then that should be fine, but otherwise there may be huge packet loss. Also, because of the lack of flow control, it tends to hog the bandwidth instead of share the bandwidth.

    3. Re:Reliable... udp... transfers? by Spy+Hunter · · Score: 5, Insightful

      TCP errs on the side of caution. The failure mode of TCP on congested links is to stop. These new UDP transfer protocols have a "damn the network, just send my bits!" attitude that could be bad for the health of the Internet as a whole. The failure mode of a NACK protocol is to flood the pipe with data that never reaches its destination, while the NACK packets never reach back to the source. Widespread use of unproven UDP transfer protocols with bad congestion control could flood the entire Internet with uncontrolled traffic, making it impossible to establish a TCP connection because of high packet loss, and reducing throughput for all. All in the name of getting a few percent more speed on long links. These people should be working together through the IETF to publish RFCs on a real replacement for TCP, not writing their own vigilante protocols on top of UDP.

      --
      main(c,r){for(r=32;r;) printf(++c>31?c=!r--,"\n":c<r?" ":~c&r?" `":" #");}
    4. Re:Reliable... udp... transfers? by ArbitraryConstant · · Score: 4, Interesting

      p2p traffic is large static files almost 100% of the time. A UDP protocol optimized for large files can be a good thing, better than TCP.

      a) Instead of a relative small window like TCP, we can make the window as big as we want. This would let us cut down a LOT on ACKs (or pseudo-ACKS in the case of UDP). We can ACK a range, or a range with exceptions, or whatever. For a protocol specializing in bulk transfers, it can really cut down on overhead.

      b) TCP guarantees that data arrives to the application in order. This is expensive when we don't care. A custom UDP protocol lets us pick up missing chunks at our leisure, we simply need to maintain a list of missing chunks as the transfer goes along so we can request them later.

      c) Since UDP is connectionless, firewalls must create pseudo-connections for UDP. When a UDP packet is sent, the firewall will allow incoming UDP packets from that host/port to the originating port. This gives us a way of signaling to the firewall that we wish to accept UDP packets from that host on that port, even though the client on the other end will never recieve that packet due to their own firewall. Once they've both done it, they have a mutual "connection". This is a brilliant hack, whoever thought of it.

      d) We can hide the sender of the data. If we request a file in some mutually accessible place, along with the host/port we're going expect packets from, anyone anywhere can start spewing packets at us with falsified sender information. It's nearly impossible to determine where they came from with UDP.

      "However, one must wonder why not just use TCP, which is guaranteed to be reliable. IMHO, What you'd end up with using UDP is a LOT of "did you get it? yes/no"-type network traffic between peers."

      TCP does that a lot too (a LOT), it's simply handled by the network stack rather than the application. TCP ACKs cause 1/15th or 1/20th as much upstream traffic as the downstream portion of the connection causes. That adds up when you have a {dsl,cable} modem that's 1/10th as fast with upstream traffic.

      --
      I rarely criticize things I don't care about.
    5. Re:Reliable... udp... transfers? by AndroidCat · · Score: 3, Insightful
      Oh good! So when someone starts a moby transfer that's going to take forever, and crashes his machine trying to game with scores of spyware running at the same time, then I can be next in line to pick up his old DHCP dynamic IP address.

      I'm so looking forward to having my bandwidth eaten by a system that wants a precise STFU packet to stop spewing at me.

      --
      One line blog. I hear that they're called Twitters now.
  7. bittorrent behind a firewall by ArbitraryConstant · · Score: 5, Informative

    I have bittorrent behind my firewall. Rather than statically allowing ports, I set up a "torrent" user, and told the firewall to let it listen for connections. This also has two beneficial side effects. First, if there's an arbitrary code vulnerability, an attacker can be somewhat contained. Second, bittorrent doesn't always use the common range of ports, so prioritizing by port is problematic. Having a seperate user lets me throttle the bittorrent connections so that interactive traffic has priority.

    While I imagine this is possible with Linux, I have no specific knowledge of how to do it. I did it with PF on OpenBSD.

    --
    I rarely criticize things I don't care about.
    1. Re:bittorrent behind a firewall by Moloch666 · · Score: 2, Informative

      Let me make sure I understand this. You can take:
      pass in on $ext_if inet proto tcp from any to $ext_if \
      port $btorrent flags S/SA keep state queue (p2p_bit, low_ack)

      Change to:
      pass in on $ext_if inet proto tcp from any to $ext_if \
      user torrent flags S/SA keep state queue (p2p_bit, low_ack)

      Not only will it assign the apropriate queue, but automatically open the ports without specifically defining them?

      --
      Understanding is a three-edged sword. -- Kosh Naranek
  8. Cross between Coral and BitTorrent? by Bert690 · · Score: 3, Informative

    This looks like an interesting hybrid of Coral and BitTorrent. Coral is nice in that you don't need to install any client-side software to take advantage of it. This one it appears you do need to install a client-side proxy, which is a little scary.

    This system seems to utilize a client that takes on roles of both the BitTorrent tracker and the Coral caching nodes. I wonder how the client caches cooordinate? Any centralized server involved here?

    Another firewall-busting HTTP serving system is YouServ (coral link), though geared more at sharing personal content instead of content requiring "super distribution".

    1. Re:Cross between Coral and BitTorrent? by Sanity · · Score: 2, Informative
      Any centralized server involved here?
      Only for the initial introduction of a peer to the global network (as with all P2P apps) - then its entirely decentralised, just like Freenet.
  9. Limewire = java based. by Krunaldo · · Score: 3, Interesting

    My father, who's using a mac, loves limewire beacuse it melts perfectly in to his UI. But he can't do anything else while he has limewire running; except play solitare and shanghai.

    Personnaly I think limewire sucks. Here's the reasons. 1. It's slow and processor hogging.
    2. It dosen't melt into my fluxbox theme. (my fault)
    3: It requires Java.



    But for the ordinary user I think limewire is the best p2p software out there.

    Fear kazaa though.

    --
    God,root what's the difference? I read slashdot, there for I errr... am stupid?
    1. Re:Limewire = java based. by AIX-Hood · · Score: 2, Insightful

      He should be using Acquisition for OS X. It's the coolest Limewire app out there with full iTunes integration and never slows down your machine. He'll never look back.

  10. Dijjer by burns210 · · Score: 2, Interesting

    "Dijjer will work with almost any direct URL, the content publisher doesn't need to lift a finger - they may not even realise that people are using Dijjer to save their bandwidth costs!"

    That is a good thing, but potentially a bad as well, for how some sites make money... I think a needed features is a robot.txt entry that blocks dijjer from caching the site.

  11. VPN-mesh? by B5_geek · · Score: 4, Interesting

    I'll be the first to admit that I'm an idiot; but what about using VPN's to secure and mesh these P2P hubs together?

    Each PC that wants to share data, acts as a hub with x-number of tunnels going out at one time. The content of each hub could be spidered and locally cached. (kind of like combining a router-cache with a Freenet hub)

    It might be slower (like DC++) but you could setup groups of peers that get preferential bandwidth.
    BUT you could always add a swarm-like functinality of BT.

    a) secure from **AA (as long as you don't let them into your peer-group)
    b) distributed load (no central server to take down)
    c) because it is a VPN, you don't need to worry a firewall because YOU initiate the connection and keep it open. {I do know that you are fubar if the firewall admin blocks the ports, but wouldn't you be SOL anyway?}

    d) well, I just think it sounds kida cool. =)

    --
    "The price good men pay for indifference to public affairs is to be ruled by evil men." ~Plato (427-347 BC)
    1. Re:VPN-mesh? by Cyfun · · Score: 2, Informative

      Check out Virtual Native Network. "VNN is a platform which provides the peer to peer's transparence. The peer that is behide either NAT devices or a SOCKS server can communicate with another peer transparently. Also the applications run on the peer can ignore the NAT devices' existence. Enter the world of VNN. Get over the lack of IPv4 address. Construct our own convenient and easy-using VPN."

      --
      In Soviet Russia, dot slashes YOU!
  12. But... by RAMMS+EIN · · Score: 2, Interesting

    And I thought firewalls were supposed to stop certain services...isn't "P2P Through Firewalls" defeating the purpose?

    Or perhaps the problem is rather with NAT? In that case, I'm still hoping that someday someone will implement something like RFC 1701 or somesuch instead of continuously reinventing the wheel.

    --
    Please correct me if I got my facts wrong.
  13. limewire = spyware free by Anonymous Coward · · Score: 2, Informative

    Wrong.

    Besides the official site stating categorically no adware, spyware, or bundled software, have an actual read of the page you linked to. It's written by a desperately technologically impaired writer who probably just got these from another source.

  14. Re:How? by GregBildson · · Score: 5, Informative

    Having written most of the udpconnect code in LimeWire, the basic idea works fairly simply. The downloader starts pinging the desired uploader with UDP SYN messages. At the same time it uses what we call a PushProxy in Gnutella to tell the uploader to start doing the same thing. So then both computers are sending UDP SYNs. This makes the NAT/firewall open up to this traffic and the LimeWire hosts on both end respond to the UDP SYNs with UDP ACKs in order to identify their connection ID.

    After receiving the ACKs, the connections can send UDP data messages in both direction safely. The only trick is you need to ensure that a message is sent every so often so the NAT/firewall doesn't close. If nothing else is sent, a special KEEPALIVE message is sent. Beyond this, the communication is somewhat similar to TCP with a FIN message shutting things down at the end.

  15. what's the big problem? by pair-a-noyd · · Score: 2, Interesting

    Smoothwall GPL 2.0 final
    POS PC = free from side of road
    Smoothwall GPL = free

    Problem solved..

  16. Dijjer is self defeating by AIX-Hood · · Score: 4, Insightful

    "No "Tracker" necessary, works with virtually any URL This is a big one, Dijjer will work with almost any direct URL, the content publisher doesn't need to lift a finger - they may not even realise that people are using Dijjer to save their bandwidth costs! As the that guy who runs filerush, I'm always looking to move to whatever will keep the files free flowing with zero hassle. The problem is that this method just shot itself in the foot. So you're saying that I have to serve my 350 meg new game demo on my regular http server and Dijjer users will P2P it without my knowledge. That's great.. but what about the other million users who have no idea about Dijjer, and just hammered my download and therefore my site in extinction because I can't tell who's who? Now nobody gets the file.

  17. Followed by virus-through-firewall applications by Animats · · Score: 2, Insightful
    If P2P through firewalls is deployed, viruses through firewalls can't be far behind.

    0wn corporate networks! Laugh at their ineffective firewalls. Use them to send spam all night! Resell them on Spamforum.biz. At last, the killer app for "grid computing".

  18. Re:security? by Hobbex · · Score: 5, Informative

    "UDP hole punching" is a simple technique, already used by many games, to allow two computers behind NAT firewalls to talk directly to one another.

    Basically it works because UDP doesn't work very well with NATs, and so the NAT has to have a very general policy on what it forwards. UDP is a packet (datagram) based protocol. Each UDP packet is actually just an IP packet with two extra headers added - the source port and the destination port, and then just the data. So how can a NAT know which host on the local network it should send a UDP packet to? It can't really, so it is forced to guess, and the classical way to do this simply to forward incoming UDP packets with a given source port to a host that recently sent an outgoing UDP packet from that source port.

    This allows hosts behind the NAT to open something like a server port, by simply sending packets from a certain source port out to the Internet regularly, thus making sure that packets sent to that destination port from the Internet will be sent to them. Note though that this also reveals the scalability problem with UDP and NATs: if you have many machines sending UDP packets from the same ports you get a problem.

    On modern, stateful, firewalls, the NATs are slightly smarter, and will only forward the UDP packet to a node in the internal network if that recently sent a packet from the destination port of the incoming packet, and to the host that the incoming packet was sent from. This makes it impossible to act as a general "server", but UDP hole punching is still possible if you have an intermediary who can tell two NATed hosts to start sending UDP packets to each other with certain port values. This means that a non-NATed host is still needed, but it doesn't need to forward all the traffic between the two others, like it would with a proxy solution.

    Blah, I meant this to be short, but instead I wasted my time writing a long slashdot post, and now there is probably already a +5 with a shorter description. Everybody mock me...

  19. UDP Hole Punching explained by Otto · · Score: 3, Informative

    UDP Hole Punching won't work on an actual "firewall". Instead it's meant to get through these home-type NAT boxes that people are calling firewalls but which really are not.

    The problem with getting stuff across a NAT gateway is that communication must go through the NAT, and the NAT is generally configured to block incoming traffic unless it's expecting it.

    See, NAT works by pretending to be you. When you go get a web page, you send a packet to a webserver. The NAT box, being your gateway, gets this packet, then sends out a reformatted packet of it's own to that webserver. It opens a return port to get the data from that webserver and this gets forwarded along to the receiving system. Basically you're changing the addresses used in both ways, so as to munge the thing between the private and public IP address space.

    UDP works in a similar way, it's just modifying addresses going through the gateway. However, with UDP, usually the port number doesn't change. Meaning that when I send a packet out, I don't get to specify what port the responding host sends a return packet back to. I'm expected to know that it'll be coming back on the same port. So NAT deals with UDP pretty simply. The outgoing port and incoming port are the same. This is open to possible abuse, so most NAT boxes only forward packets from the original host back to the private network.

    That's potentially confusing, so I'll use an example:

    Computer A is behind a NAT. He sends a UDP packet to computer B on the public internet, on port 30000. The NAT munges the outgoing address and forwards it to computer B. Computer B sends back a UDP packet on port 30000. The NAT verifies that he is only allowing B to respond on that port, and sends the packet back to computer A. If computer C were to send something to the NAT on port 30000, it would be discarded by the NAT (not all NAT's do this, some allow anything in for a short time instead).

    In the case where only one system is behind a NAT, this is easy to solve. The computer behind the NAT must initiate the connection. That's all there is to it. Computer A initiating the connection makes it possible for the NAT to send stuff back to computer A, and so all is good.

    In the case where both computers A and B are behind their own NAT, suddenly they have no way to talk to each other. Anything A sends to B gets dropped by B's NAT, and anything B sends to A gets dropped by A's NAT. The only fix for this has been port forwarding, which manually punches a hole in one or both NAT devices.

    UDP Hole Punching exploits the UDP behavior of NAT devices to allow A and B to communicate directly without any port forwarding being needed. It works like this:

    Computer A sends a UDP packet to computer B on port 30000. This act opens the hole in the NAT for B to talk to A on port 30000. At the same time, A sends a packet to Server S on the P2P network. This packet basically asks computer B to send something to computer A on port 30000. Server S routes the packet to computer B over the already setup P2P network. Computer B then sends something to computer A on the given port, and they can now talk directly and setup other ports if they likee by this single channel of communication that they have gotten open.

    And that's all it is, really. Just a way of using an intermediary that can talk to both A and B (via the already established P2P routing) to allow them to talk directly. Nothing particularly tricky.

    Why UDP? Because UDP doesn't get the port changed by the NAT. TCP connections over a NAT usually get ports munged by the NAT without informing the computer behind the NAT. That's part of the "transparency" portion of NAT. The less tricky behavior of UDP on a NAT device makes this possible.

    --
    - Give a man a fire and he's warm for a day, but set him on fire and he's warm for the rest of his life.
  20. Mod parent up. by apankrat · · Score: 2, Insightful

    And mod me up while you're at it :)

    Most of reliable UDP protocols do use unsolicited NACK'ing and solicited ACK'ing. This cuts down overhead on fat pipes to just one ACK per a transfer, which is as low as it gets.

    This approach doesn't work well on lossy links or for interactive sessions though.

    --
    3.243F6A8885A308D313
  21. Not likely by Wesley+Felter · · Score: 2, Informative

    Lots of ISPs implement egress filtering these days to reduce forged IP source addresses.

  22. Re:How to Initiate Connection? by sameb · · Score: 2, Informative

    It's still peer to peer. Or more appropriately, peer to peer using another peer (P2PUAP). The flow is like this:

    - Someone sends a request that gets routed through the network.
    - Someone sends a reply that gets routed back through the network. The reply contains the address of a few [directly connectable] people the replier is connected to.
    - The requestor sends a message to the directly connectable folks telling them to tell the replier to start sending UDP packets.
    - Requestor & Replier both start sending UDP packets to each other. The NATs open, the transfer begins.

  23. robots.txt is for search engines by Sanity · · Score: 2, Informative

    Dijjer respects the various no-cache HTTP headers, a robots.txt file is intended for search engines, not caches.

  24. Re:How to Initiate Connection? by Hobbex · · Score: 2, Informative

    Yes, it is impossible to for two hosts behind stateful NAT firewalls to communicate if they do not have some third party "matchmaker" to tell them: "start sending packets from this port to that port at that host". But the point is that this matchmaker still has a very low load, and can exit once the connection is established, so that is not that bad compared to what would happen if he served as a proxy for all the data instead.

    This definitely an ugly hack, but all NAT is really just an ugly hack, so it isn't that surprising.

  25. Trivially solved by Sanity · · Score: 3, Informative

    Just make your web server reject or redirect links that do not report Dijjer as their HTTP client. Easy.

  26. Wondered when.... by GoRK · · Score: 2, Informative

    I have been really wondering when someone was going to do this for P2P apps. Compared to how much other software actually uses the same techniques, it's long overdue. There seems to be some misconceptions on how it works though in the comments here, so I'll try to do a simple explination:

    UDP is stateless. There is no connection setup like there is with TCP so there's really no way for a firewall or gateway to statefully track where to send UDP packets, so the typical implementation for NAT'ing UDP is something of a 'best guess' scenario, redirecting certain packets based on port numbers and IP's. These new applications take advantage of this synchronous behavior of NAT devices to permit direct connection between client computers where both are behind NAT firewalls.

    NAT of UDP is generally implemented like this: If you begin sending UDP from source port 2000 on your computer to a remote host on port 5000, then the router doing NAT will automatically open up a 'hole' that allows any UDP packet from the remote host from source port 5000 to destination port 2000 on your machine to pass through to you. This is sort of how it works with TCP too; however the firewall only opens up the 'holes' when connections are first set up and only allows packets with correct sequence numbers to pass back through.

    Essentially how it works is that two clients decide to "connect" and agree on port numbers, etc through some third host that both can reach via tcp. They then begin broadcasting UDP data to each other. Once a packet goes out from both hosts, the two 'holes' in the firewall will open up. Probably at least one packet will not actually arrive at its indended destination; however, the software can implement its own robust transfer protocol over UDP.

    Games have been doing this forever. QuakeWorld (the Quake 1 client tailored to internet play) was one of the first to implement it. Most implentations of SIP support this type of connection.

  27. Problem with Dijjler by brunes69 · · Score: 4, Informative

    Just tried it out, so this is speaking from actual experience. Digger doesn't limit itself to sharing files you have already downloaded - it will *actively* download files other people are requesting, so that it can share them.

    This is simmilar to freenet, and indeed will maximize everyone's bandwidth. But it has grave issues when not combined with Freenet's huge anonymimity factors like encryption and hiding IPs , and will open you up to all sorts of legal problems.

    I don't want the FBI knocking down my door because my Dijjer client has been downloading kiddie porn for someone else without my knowledge. Sure, I *may* be able to argue in court that it was not me, and hey, I may even be able to prove it. But is that potential trouble worth my saving on some bandwidth? I think not.

    1. Re:Problem with Dijjler by Sanity · · Score: 2, Interesting
      Just the other day they announced that BitTorrent, the P2P app/protocol that gives far more control to the user than any other P2P app out there, holds 35% of all internet traffic.
      Correlation doesn't imply causality.
      It already happened when Kazaa first hit the net, before it didn't have the ability to completely shut off sharing.
      URL? I have never heard of that. I have spoken to many ISPs and they secretly love P2P, it is the primary driver for broadband adoption. Well designed P2P can actually reduce ISPs costs by minimising off-network traffic.
  28. DMCA explicitly makes caching legal by Sanity · · Score: 2, Informative
    will open you up to all sorts of legal problems.
    Care to be more specific? It seems to me that Dijjer is pretty-much exactly what the system caching exemption of the DMCA was intended for.

    Dijjer does not create any more liability for its users than a HTTP cache creates for an ISP, and note that virtually all ISPs run HTTP caches, so far as I know, without encountering legal problems.

  29. *Any* URL? by MacDork · · Score: 2, Interesting
    "No "Tracker" necessary, works with virtually any URL
    This is a big one, Dijjer will work with almost any direct URL, the content publisher doesn't need to lift a finger - they may not even realise that people are using Dijjer to save their bandwidth costs!

    So, am I to understand that when using dijjer you are broadcasting your web surfing habits all the time in the hopes that someone other than marketers and police are out there listening? Or is there some anonymizing Freenet magic going on here? Giving up my privacy to save someone else a dime doesn't sound like a good idea to me.

  30. Re:Reliable... (TCP/IP vs TCP/UDP) by Stephen+Samuel · · Score: 2, Insightful
    UDP isn't similar to IP. It sits on top of IP, just like TCP does. The main difference between UDP and TCP is that TCP has reliability built in. The protocol will automatically re-order out of sequence packets, figure out which ones are missing and have them retransmitted before it delivers the data to the recipient.

    With UDP, if you want reliable transmission, then you have to do all that work yourself. If you have a generally reliable link, then this can be very cheap. It's also very cheap if you only want to send a little bit of data (say, one line of text).

    With TCP it takes at least three packets just to open the connection -- before you can even transmit data -- and then another three to close it. That gives you a minimum of 6 packets with no actual transmitted data.

    With UDP, a very simple transaction can consist of
    a -> B (( DATA ))
    B -> a (( ACK: CRC was X) [[ optional ]]
    As long as the checksum is good, A need do nothing. If the checksum was bad (or no ACK comes back) then A can retransmit). If you don't mind losing the data altogether, then even the ACK is unnecessary.

    UDP can be fast and cheap, but to avoid beating the internet to death on bulk transfers it depends on the application being well-designed to prevent bad side effects.... That intelligence is built into TCP (but at a cost).

    As long as you can handle losing the occasional packet and/or having packets arrive out of order and you don't threaten hog the entire bandwidth of your pipe, then UDP is fine.

    If you don't want to worry about the above, and you're willing to put up with the overhead of TCP, then TCP is your best bet. This turns out to be the case for the majority of applications, which is why TCP seems to be way more common than UDP -- SO much so that many people don't even relize that you can have IP without TCP (( the 'TCP/IP' misnomer contributes to this)).

    --
    Free Software: Like love, it grows best when given away.
  31. Generic Matchmaker? by bill_mcgonigle · · Score: 2, Insightful

    But the point is that this matchmaker still has a very low load, and can exit once the connection is established, so that is not that bad compared to what would happen if he served as a proxy for all the data instead.

    Is there a generic (P2P Protocol Agnostic) matchmakerd? Seems silly to have one for each network. If there were a standard, I could, for example, put a call through to my parents' video phone without having to know their IP address if we both subscribed to the same matchmaker or network of matchmakers. Without a generic standard the proverbial videophone firmware developer isn't going to be able to offer me a field for query service server.

    --
    My God, it's Full of Source!
    OUTSIDE_IP=$(dig +short my.ip @outsideip.net)