ProtonMail / proton-mail-settings

React web application to manage ProtonMail settings
53 stars 13 forks source link

Filter Action label does not handles names containing a slash #240

Closed ThHareau closed 5 years ago

ThHareau commented 5 years ago

When choosing the label action while creating a filter, labels containing a / are not handled correctly.

To reproduce:

  1. Create a filter

    • Create a label that contains a / (example: la/bel);
    • Create a new filter;
    • Choose a valid condition;
    • Choose the label with a /
    • Save.
  2. Open the related sieve script

    • Notice that the label slash is not escaped;
    • Escape the slash, buy appending \\ before it. If the label was la/bel, it should now be transformed to la\\/bel. That is how the label should be given to be understood by the sieve library;
    • Save
  3. Edit the filter using the graphical tool

    • Notice that the label is no longer present in the label action