bug in inet_drv.c

klacke <>
Mon Apr 11 22:30:37 CEST 2005


Howdy, 

I resent an old bug report of mine a couple
of months ago but I'm not sure what happened to it.

It's a pretty serious bug and I recommend everone running
erlang systems that use sockets with {packet, http}   
(this includes all yaws systems) to apply the patch. 
Otherwise it's easy to bring down the entire erlang node 
just by sending broken HTTP requests at it.

Anyway, the bug is old and originally reported at:

http://www.erlang.org/ml-archive/erlang-questions/200302/msg00493.html

and a correct description at

http://article.gmane.org/gmane.comp.lang.erlang.patches/3


The patch is:

--- inet_drv.c.orig     2005-04-08 17:33:37.003071900 +0200
+++ inet_drv.c  2005-04-08 17:33:43.279602316 +0200
@@ -1980,7 +1980,7 @@
     int c;
     /* start-line = Request-Line | Status-Line */
     if (n == 0)
-      return 0;
+      return -1;
     h = 0;
     meth_ptr = ptr;
     while (n && !is_tspecial((unsigned char)*ptr)) {



/klacke


-- 
Claes Wikstrom                        -- Caps lock is nowhere and
http://www.hyber.org                  -- everything is under control          



More information about the erlang-questions mailing list