This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Bad URL encoding in SimpleHTTPServer directory listing
Type: Stage:
Components: Library (Lib) Versions:
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: jlgijsbers Nosy List: jlgijsbers, nielsdi
Priority: normal Keywords: patch

Created on 2004-08-18 01:12 by nielsdi, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
patch nielsdi, 2004-08-18 01:26
Messages (2)
msg46727 - (view) Author: Niels Diepeveen (nielsdi) Date: 2004-08-18 01:12
The list_directory method of SimpleHTTPRequestHandler uses cgi.escape() to encode the filenames.
However, the HREF part should be encoded using urllib.quote(). This patch fixes that.
msg46728 - (view) Author: Johannes Gijsbers (jlgijsbers) * (Python triager) Date: 2004-08-21 10:44
Logged In: YES 
user_id=469548

Checked in as rev 1.22 of SimpleHTTPServer.py. Thanks for
the patch!
History
Date User Action Args
2022-04-11 14:56:06adminsetgithub: 40776
2004-08-18 01:12:28nielsdicreate

Follow Lee on X/Twitter - Father, Husband, Serial builder creating AI, crypto, games & web tools. We are friends :) AI Will Come To Life!

Check out: eBank.nz (Art Generator) | Netwrck.com (AI Tools) | Text-Generator.io (AI API) | BitBank.nz (Crypto AI) | ReadingTime (Kids Reading) | RewordGame | BigMultiplayerChess | WebFiddle | How.nz | Helix AI Assistant