March 1. 2009. aa-http for Freerunner. version 0.2 Http-server. ------------ Usage ----- Go to folder, which you want serve to public. ./server It uses port 8080 as default. If you want use another port, just give it as commandline parameter. ./server 80 Then you can connect with browser: http://moko:8080/index.html Features -------- *It can serve files. *Easy way to handle dynamic content or make http-based 'control-center'. Go page named vibra.html and your device should thrill 2 seconds. *Not implemented: directory listing. Issues ------ 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 might be critical) ???Valgrind shows that threads leaks memory??? Compiling --------- . /usr/local/openmoko/arm/setup-env arm-angstrom-linux-gnueabi-gcc -o server server.c -pthread -Wall -Wextra License ------- GPL 2 or newer. Aapo Rantalainen @ gmail.com