Commit 4c70d8c6 authored by Andreas Jung's avatar Andreas Jung

Collector 2396: STXNG: URLs containing '%' were not handled properly

like http://zope.org/%7e/.... (replacement for tilde)

Notice: to be backported to 2.4 branch after 2.4 release
parent c75c60e0
......@@ -7,6 +7,10 @@ Zope Changes
- Collector #2390: Objects of type 'Help Image' were not properly
re-registered inside registerHelp().
- Fixed broken FTP download for larger files.
- Collector # 2396: StructuredText did not allow URLs containing "%"
Zope 2.4 beta 2
......
......@@ -949,8 +949,8 @@ class DocumentClass:
## Some constants to make the doc_href() regex easier to read.
_DQUOTEDTEXT = r'("[ %s0-9\n\r\-\.\,\;\(\)\/\:\/\*\']+")' % letters ## double quoted text
_ABSOLUTE_URL=r'((http|https|ftp|mailto|file|about)[:/]+?[%s0-9_\@\.\,\?\!\/\:\;\-\#\~\=\&]+)' % letters
_ABS_AND_RELATIVE_URL=r'([%s0-9_\@\.\,\?\!\/\:\;\-\#\~\=\&]+)' % letters
_ABSOLUTE_URL=r'((http|https|ftp|mailto|file|about)[:/]+?[%s0-9_\@\.\,\?\!\/\:\;\-\#\~\=\&\%%]+)' % letters
_ABS_AND_RELATIVE_URL=r'([%s0-9_\@\.\,\?\!\/\:\;\-\#\~\=\&\%%]+)' % letters
_SPACES = r'(\s*)'
def doc_href(self, s,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment