diff options
author | Aleksander Machniak <alec@alec.pl> | 2017-01-07 11:59:42 +0300 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2017-01-07 11:59:42 +0300 |
commit | 7340360e798ac984214932d5fcd464f26392fa03 (patch) | |
tree | 5c9226001462bc2c66d78b2e87a68793b8d244d8 /tests | |
parent | f65f4bbca859aeb1b10a342c2af3d9094427974c (diff) |
Fix bug where image data URIs in css style were treated as evil/remote in mail preview (#5580)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Framework/Utils.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/Framework/Utils.php b/tests/Framework/Utils.php index 5f70544d4..ba04e1545 100644 --- a/tests/Framework/Utils.php +++ b/tests/Framework/Utils.php @@ -214,6 +214,10 @@ class Framework_Utils extends PHPUnit_Framework_TestCase $mod = rcube_utils::mod_css_styles(".test { position:/**/fixed; }", 'rcmbody'); $this->assertEquals("#rcmbody .test { position: absolute; }", $mod, "Replace position:fixed with position:absolute (2)"); + + // allow data URIs with images (#5580) + $mod = rcube_utils::mod_css_styles("body { background-image: url(data:image/png;base64,123); }", 'rcmbody'); + $this->assertEquals("#rcmbody { background-image: url(data:image/png;base64,123); }", $mod, "Data URIs in url() allowed"); } /** |