thortex / rpi3-webiopi

WebIOPi for Raspberry Pi 1, 2, 3, and zero
https://thortex.github.io/rpi3-webiopi/
Apache License 2.0
60 stars 20 forks source link

Issue #100 [New/open] - Patch for percent-encoded URL's #4

Closed thortex closed 8 years ago

thortex commented 8 years ago

Posted by andreas.riegg

Sometimes, HTTP requests contain URL's that have paths which contain percent encoded characters (e.g. "%2F" for the "/"). I came across this as I was working with Swagger UI for the testing console.

If WebIOPi receives such a request, it fails with a "not found" error. The attached patch mitigates this problem for Python 2 and 3.

So if anyone also has or gets this problem, here is a solution for that.

Andreas

Files attached

http.py