Problem installing apache webserver on my FreeRunner

Aapo Rantalainen aapo.rantalainen at gmail.com
Sun Mar 1 16:44:33 CET 2009


http://cc.oulu.fi/~rantalai/freerunner/aa-http/
Thanks Timo for your thoughts.

Case:
User Adam start server on directory, where Bob has write access. (this
is bad habits anyway)
Someone asks file from server. Server first check file size and then
loads it. Bob can change file between
those steps and it causes buffer overflow. (and if Adam is root, this
is critical)



I eliminate warnings and memory leaks. (can be compiled -Wall -Wextra cleanly)
I use valgrind to find memory leaks, and it founds something with
threading. I read manuals and found this solution, but valgrind is not
satisfated.

//  I try that every thread frees its memory when it is ready:
   pthread_attr_t pattr;
   pthread_attr_init(&pattr);
   pthread_attr_setdetachstate(&pattr, PTHREAD_CREATE_DETACHED);


    pthread_create(&handling_thread, &pattr, handle_connection, (void
*)new_conection_socket);


-Aapo Rantalainen




More information about the community mailing list