linkchecker/tests/checker/cgi-bin/input2cookies.py
Chris Mayo 3b8af403be Add test for loginurl
A new cgi-bin directory is created to identify the scripts to be run by
http.server.CGIHTTPRequestHandler.
2020-04-19 19:05:55 +01:00

11 lines
175 B
Python
Executable file

#!/usr/bin/python3
import cgi
from http import cookies
form = cgi.FieldStorage()
C = cookies.SimpleCookie()
for field in form:
C[field] = form.getvalue(field)
print(C)