Pull requests

#8 Open
Repository
acdha acdha
Branch
robust-path-regexp
Repository
carljm carljm
Branch
default

Fix an edge case with noisy URLs

Bitbucket cannot automatically merge this request.

The commits that make up this pull request have been removed.

Bitbucket cannot automatically merge this request due to conflicts.

Review the conflicts on the Overview tab. You can then either decline the request or merge it manually on your local system using the following commands:

hg update default
hg pull -r robust-path-regexp https://bitbucket.org/acdha/django-localeurl
hg merge robust-path-regexp
hg commit -m 'Merged in acdha/django-localeurl/robust-path-regexp (pull request #8)'
Author
  1. Chris Adams
Reviewers
Description

I've encountered a few requests in the wild which had embedded newlines in their URLs (e.g. %0a / %0d, not at the end of the URL where .strip() would handle them). These caused PATH_RE not to match the decoded URL which meant that the servers endlessly redirected (e.g. /foo%0a%0dbar -> /en/foo%0a%0dbar -> /en/en/foo%0a%0dbar) rather than the desired 404.

Comments (0)