Slashdot Mirror


User: dunkels

dunkels's activity in the archive.

Stories
0
Comments
3
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 3

  1. Re:From the author on phpstack - A TCP/IP Stack and Web Server in PHP · · Score: 1

    Sorry about that. To be honest, I haven't looked at the patch page since I registered the page at souceforge. I prefer emails for communication and bug reports and it never really crossed my mind that the sourceforge patch system might be used :-P. Please drop me an email. Thanks!

  2. Re:netcat anyone? on phpstack - A TCP/IP Stack and Web Server in PHP · · Score: 1

    The TCP/IP stack is intensionally very simple - this is just a proof-of-concept demo and nowhere did I claim it to be RFC compliant or of production quality. I don't think that PHP is the right language for writing a TCP/IP stack for production use. If you are interested in a fully functional but still very small TCP/IP stack, you should take a look at my uIP stack instead. It has full support for IP fragment reassembly and has an RFC-compliant TCP and still fits in only a few kilobytes of code space.

    (And, by the way, the FIN + PSH + ACK flag combination is perfectly legal.)

  3. From the author on phpstack - A TCP/IP Stack and Web Server in PHP · · Score: 5, Informative

    I am the author of this and I must point out that the phpstack server is actually still running after over two hours of slashdotting! It is extremely slow, however, because of the insane amount of IP packets that have to traverse the 115200 bps serial line that connects the server with the rest of the world. The front page of the server currently reports that it has served 13157 visitors.

    A lot of people that comment here focus solely on the web server part of this software and completely miss the novel part in this: the TCP/IP stack. Writing a simple web server is dead easy. To the best of my knowledge, however, nobody has been stupid enough to write a TCP/IP stack in PHP before :-). The web server running on top of the stack is really simple and can be seen as the equivalent of the "netcat" web server someone suggested.

    The TCP/IP stack is intensionally extremely simplified (or "half-baked", if you wish) and tailored to the specific needs of the simple web server. Someone implied that the reason for the simplifications was that I maybe hadn't "figured out" how to handle fragmented packets. Well, it does not have to do with packet fragmentation (IP fragmentation is not that much of an issue today), but with the TCP receiver not trying to put together incoming TCP segments into a stream. Interested people could take a look at my uIP or lwIP TCP/IP stacks to see how to solve these problems in the general case. I have also written a paper that discuss issues with reducing TCP and IP in more detail.

    Of course, there are also the standard "this guy should get a life" comments. I always find it amusing to see such comments being posted only 10 minutes after the article hit the Slashdot front page, on a Saturday. I'm not the only one in need of a life, it seems :-)

    Finally, all of this is just a quick hack made solely for fun (and in part to learn more about PHP). I submitted it to Slashdot simply because I enjoy seeing articles like this myself. From the insane amount of traffic to my demo server, it seems that quite a lot of other people find it interesting as well :-)