Commit graph

151 commits

Author SHA1 Message Date
Son NK
3015cd1dc0 ignore "text/calendar" content type 2020-12-18 16:07:32 +01:00
Son NK
6cec373b6d ignore UnicodeDecodeError in decode_text() 2020-12-18 13:10:33 +01:00
Son NK
fb8a43fd5d use decode_text() in add_header() 2020-12-18 10:44:42 +01:00
Son NK
091ff3ad2c Add decode_text() 2020-12-18 10:43:06 +01:00
Son NK
3a8cdce650 Create should_disable 2020-12-16 18:50:09 +01:00
Son Nguyen Kim
bf139f83b3
Merge pull request #342 from herrboyer/linting
Linting
2020-12-07 17:45:50 +01:00
Son NK
ce3dae2a07 inform user when an alias can't be created when a directory is disabled 2020-12-07 10:55:13 +01:00
Son NK
37a74bc093 refactor: rename 2020-12-07 10:50:42 +01:00
Renaud Boyer
5d948faf56 black 2020-12-06 22:11:58 +01:00
Son NK
ce2d68a64d take into account include_sender_in_reverse_alias when creating reverse-alias 2020-12-06 19:37:20 +01:00
Renaud Boyer
4bcc0d107f linting 2020-12-06 18:01:55 +01:00
Son NK
83df119178 do not replace for "application/*" 2020-12-04 11:33:49 +01:00
Son NK
59daaa3164 ignore multipart/signed when replacing message 2020-12-03 17:52:11 +01:00
Son NK
cd680bcd7f ignore content type like image/, video/, audio/ in replace() 2020-12-01 18:34:38 +01:00
Son NK
652bb6a369 take into account multipart/mixed in replace() 2020-11-30 19:45:45 +01:00
Son NK
cefa68d392 Create replace() in email_utils 2020-11-30 15:15:13 +01:00
Son NK
0b95ca33b8 use no encoding for 8bit and binary 2020-11-30 10:49:04 +01:00
Son NK
f804332c2d refactor: create EmailEncoding enum 2020-11-30 10:48:16 +01:00
Son NK
d61f45ea86 use 7bit as default encoding 2020-11-26 17:22:17 +01:00
Son NK
1241838b26 take into account message encoding in add_header() 2020-11-26 17:03:50 +01:00
Son NK
e2a7061429 add get_encoding() and encode_text() 2020-11-26 17:01:05 +01:00
Son NK
bcdf522174 create normalize_reply_email(): handle case where reply email contains space, quote, etc 2020-11-22 13:07:09 +01:00
Son NK
f069d2f083 use getaddresses to parse multiple address from To, CC header. Remove get_addrs_from_header() 2020-11-21 19:15:02 +01:00
Son NK
c25a5b50f6 make sure reply_email only contain lowercase 2020-11-20 10:03:40 +01:00
Son NK
75c3fa1c11 make sure reply-email only uses ascii-encoded char 2020-11-18 15:36:39 +01:00
Son NK
9ca129cb97 use warning level for cannot decode error 2020-11-18 11:43:25 +01:00
Son NK
319078fceb use contact email when generating reply-email 2020-11-18 10:24:39 +01:00
Son NK
0963049d1f use utf-8 when unknown charset in parseaddr_unicode() 2020-11-18 10:03:58 +01:00
Son NK
28d42a7a22 Use get_header_unicode() in get_addrs_from_header() 2020-11-18 10:03:00 +01:00
Son NK
be510ea1d7 use utf-8 if unknown charset in get_header_unicode() 2020-11-18 10:02:10 +01:00
Son NK
9154b4656d refactor: create is_reply_email() 2020-11-16 19:22:19 +01:00
Son NK
75ba1669e0 Create generate_reply_email() and refactor 2020-11-16 19:15:09 +01:00
Son NK
f16676e921 email.message_from_string can also throw LookupError when non-existent charset is set 2020-11-13 18:08:56 +01:00
Son NK
4e16eb7403 fix 2020-11-10 17:42:23 +01:00
Son NK
4666d21f63 email.message_from_string can also throw KeyError when 'content-transfer-encoding' is absent 2020-11-10 17:26:24 +01:00
Son NK
632a5bbbc8 handle UnicodeEncodeError in copy() and to_bytes() 2020-11-10 16:02:19 +01:00
Son NK
c3f73b25b2 decode the subject 2020-11-09 21:16:50 +01:00
Son NK
b2f9479bce failover when ascii encoding fails 2020-11-09 20:58:39 +01:00
Son NK
2cc7cb6a37 use to_bytes instead of .as_bytes() 2020-11-09 17:02:10 +01:00
Son NK
3f8e5d0a8b add more logging 2020-11-08 22:39:49 +01:00
Son NK
e659680875 add_header() 2020-11-07 13:00:12 +01:00
Son NK
72a34e28be add is_valid_email() 2020-11-03 11:09:37 +01:00
Son NK
677f150fef add unsubscribe header to com emails 2020-10-22 10:44:05 +02:00
Son NK
4a32db5b5d rename PublicDomain -> SLDomain 2020-10-15 16:51:07 +02:00
Son NK
0a4fc76b61 optimize import 2020-10-15 16:45:28 +02:00
Son NK
adff510359 use PublicDomain instead if ALIAS_DOMAINS 2020-10-15 16:45:08 +02:00
Son NK
1fcf166c00 small refactor: add should_add_dkim_signature 2020-10-15 16:24:04 +02:00
Son NK
e79522b638 take into account Premium domains 2020-10-15 16:21:31 +02:00
Son NK
805e78cad1 rename email_belongs_to_alias_domains -> email_belongs_to_default_domains 2020-10-14 18:46:05 +02:00
Son NK
8517e7d356 refactor com emails: remove non-uses, move to the right location 2020-09-30 11:51:43 +02:00