Skip to content

Instantly share code, notes, and snippets.

@llamaonsecurity
llamaonsecurity / dummy-web-server.py
Last active April 27, 2018 13:05 — forked from bradmontgomery/dummy-web-server.py
a minimal http server in python. Responds to GET, HEAD, POST requests, with content of the file.
#!/usr/bin/env python
"""
Very simple HTTP server in python.
Usage::
./dummy-web-server.py [<port>] [<file_to_serve>] [<content_type>]
Send a GET request::
curl http://localhost -v
Send a HEAD request::
curl -I http://localhost -v
Send a POST request::