diff options
author | Aleksander Machniak <alec@alec.pl> | 2013-04-06 19:28:47 +0200 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2013-04-06 19:28:47 +0200 |
commit | 4fdaa02ac724e597479a4a48388a8a10101000fd (patch) | |
tree | ac6e7b739dddfafd41dde12c06ccbd6d82c29699 /program/lib/Roundcube/rcube_message_header.php | |
parent | 50cc5b370f1fab3ecf4ff516f60087129e8a57d1 (diff) |
Fix handling of invalid characters in message headers and output (#1489032)
Diffstat (limited to 'program/lib/Roundcube/rcube_message_header.php')
-rw-r--r-- | program/lib/Roundcube/rcube_message_header.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/program/lib/Roundcube/rcube_message_header.php b/program/lib/Roundcube/rcube_message_header.php index 274ae7f9f..2c5e2b6c8 100644 --- a/program/lib/Roundcube/rcube_message_header.php +++ b/program/lib/Roundcube/rcube_message_header.php @@ -215,7 +215,12 @@ class rcube_message_header $value = $this->others[$name]; } - return $decode ? rcube_mime::decode_header($value, $this->charset) : $value; + if ($decode) { + $value = rcube_mime::decode_header($value, $this->charset); + $value = rcube_charset::clean($value); + } + + return $value; } /** |