~/tmp/localhost_cookies via py v3.12.3 (.venv) ❯ ./localhost_cookies.py DEBUG:urllib3.connectionpool:Starting new HTTP connection (1): localhost:80 DEBUG:urllib3.connectionpool:http://localhost:80 "GET /set_cookie.php HTTP/1.1" 200 60 Cookie 'testcookie' has been set with the value 'testvalue'. Local cookies after receiving Set-Cookie header: {'testcookie': 'testvalue'} Cookie: testcookie, Value: testvalue, Domain: localhost, Path: / DEBUG:__main__:Request URL: http://localhost/read_cookie.php DEBUG:__main__:Request method: GET DEBUG:__main__:Request headers: DEBUG:__main__: User-Agent: python-requests/2.32.0 DEBUG:__main__: Accept-Encoding: gzip, deflate DEBUG:__main__: Accept: */* DEBUG:__main__: Connection: keep-alive DEBUG:__main__:Request body: None DEBUG:urllib3.connectionpool:http://localhost:80 "GET /read_cookie.php HTTP/1.1" 200 2 DEBUG:__main__:Response status code: 200 DEBUG:__main__:Response headers: DEBUG:__main__: Date: Mon, 20 May 2024 18:46:28 GMT DEBUG:__main__: Server: Apache/2.4.54 (Debian) DEBUG:__main__: X-Powered-By: PHP/7.4.33 DEBUG:__main__: Access-Control-Allow-Origin: * DEBUG:__main__: X-Frame-Options: DENY DEBUG:__main__: X-Content-Type-Options: nosniff DEBUG:__main__: X-XSS-Protection: 1; mode=block DEBUG:__main__: Referrer-Policy: no-referrer-when-downgrade DEBUG:__main__: Cache-Control: no-transform DEBUG:__main__: Vary: User-Agent DEBUG:__main__: Content-Length: 2 DEBUG:__main__: Keep-Alive: timeout=5, max=99 DEBUG:__main__: Connection: Keep-Alive DEBUG:__main__: Content-Type: text/html; charset=UTF-8 DEBUG:__main__:Response body: [] Cookies sent to the server: []