dburkart / check-sieve

Syntax checker for mail sieves.
MIT License
34 stars 7 forks source link

`fileinto :flags` not properly handling flag arguments #26

Closed stmontgomery closed 8 years ago

stmontgomery commented 8 years ago

RFC 5232 supports specifying a string-list of IMAP flags to the fileinto command via the :flags tag, but check-sieve does not properly parse this.

The usage is currently

fileinto [\":flags\"][\":copy\"] <folder: string>"

but should be

fileinto [\":flags\" <list-of-flags: string-list>][\":copy\"] <folder: string>

Test cases reproducing the issue and proposed fix below. See my commit messages for details, including an explanation of why the bison version changed from 3.0.2 to 3.0.4.