diff --git a/roundup/rfc2822.py b/roundup/rfc2822.py
index 7cee7150592c359e322623de8afd822f77653516..0faa833f2e34d047af431c34fdcb16a96acb7a29 100644 (file)
--- a/roundup/rfc2822.py
+++ b/roundup/rfc2822.py
import re
+from string import letters, digits
from binascii import b2a_base64, a2b_base64
ecre = re.compile(r'''
\?= # literal ?=
''', re.VERBOSE | re.IGNORECASE)
-hqre = re.compile(r'^[-a-zA-Z0-9!*+/\[\]., ]+$')
+hqre = re.compile(r'^[A-z0-9!"#$%%&\'()*+,-./:;<=>?@\[\]^_`{|}~ ]+$')
def base64_decode(s, convert_eols=None):
"""Decode a raw base64 string.
if not header:
return header
- global hqre
# return plain header if it is not contains non-ascii characters
if hqre.match(header):
return header