#webservers using netcat, busybox nc, or ncat #this will work with the full version of ncat, but busybox nc doesn't have '-c' builtin ncat -l -p 8000 -c 'echo -e "HTTP/1.1 200 OK\r\n$(date)\r\n\r\n";echo "
How are you today?
"' #this is more universal { echo -e 'HTTP/1.1 200 OK\r\n'; echo "How are you today?
"; } | netcat -l -p 8000 #keep it up and running after serving files while [ 1 ];do { echo -e 'HTTP/1.1 200 OK\r\n'; echo "How are you today?
"; } | busybox -l -p 8000;done #or you can pass it a file { echo -e 'HTTP/1.1 200 OK\r\n'; cat index.html; } | busybox nc -l -p 8000 #or the output of a command { echo -e 'HTTP/1.1 200 OK\r\n'; ls /; } |busybox nc -l -p 8000 #or a command with html tags #note the use of '' and use single quotes due to special characters { echo -e 'HTTP/1.1 200 OK\r\n'; echo '';echo "