Normalize the url to jail the request in web root.
Test whether it is a dir, if url is not ended with a /.
Use os.access() to test file existence and permission.
Add support for cgi.
Add more cgi env var.