+ Reply to Thread
Page 15 of 34 FirstFirst ... 5 13 14 15 16 17 25 ... LastLast
Results 141 to 150 of 335

Thread: Sieverules plugin

  1. #141
    adlerweb_ is offline Roundcube Newcomer
    Join Date
    Jan 2010
    Posts
    3
    Downloads
    0
    Uploads
    0

    Default

    OK, i think i found the bug…

    Before roundcube r731 (think release 0.1-r1) it used ASCII as default character encoding for its session-table. It was changed (bug #1484456) but they only updated the initial SQL, the update.sql does not contain any conversion. As long as you don't disable caching the plugin will save rules inside the session - if there any UTF8-Chars the SQL-query breaks and rc killes the session.

    Quick and dirty fix:
    Code:
    ALTER TABLE `session`  ENGINE = InnoDB DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci 
    ALTER TABLE `session` CHANGE `sess_id` `sess_id` VARCHAR( 40 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL ,
    CHANGE `ip` `ip` VARCHAR( 15 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL ,
    CHANGE `vars` `vars` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL
    If you have a database that was created with a early rc-version you should recreate all tables - there are more changes that are not inside the update.sql (e.g. MyISAM -> InnoDB)

  2. #142
    JohnDoh is offline Super Moderator
    Join Date
    May 2007
    Posts
    1,206
    Downloads
    6
    Uploads
    0

    Default

    pela020: if you are using the repo version go into rcube_sieve.php and set $cache to false on line 37 and then try again, may be the cache doesnt work right. if that doesnt work then check your dovecot config and where the sieve files are acually being written on the server, make sure they are not all in the same place.

    internalkernel: i have setup a rule with 20 tests and then a fileinto and it saves just fine. could you post an example of one which doesnt work for you please?
    Roundcube Patches: Sieverules, SpamAssassin Prefs, and more…

  3. #143
    pela020 is offline Roundcube Newcomer
    Join Date
    Jan 2010
    Location
    Sweden
    Posts
    3
    Downloads
    0
    Uploads
    0

    Default

    [QUOTE=JohnDoh;24801]pela020: if you are using the repo version go into rcube_sieve.php and set $cache to false on line 37 and then try again, may be the cache doesnt work right. if that doesnt work then check your dovecot config and where the sieve files are acually being written on the server, make sure they are not all in the same place.

    There's a symlink in /home/vmail/domain

    Code:
    .dovecot.sieve -> sieve/roundcube.sieve
    I've changed the cache value to false but it doesn't do anything different what i can see. It still writes the filters in the same file for all users

  4. #144
    JohnDoh is offline Super Moderator
    Join Date
    May 2007
    Posts
    1,206
    Downloads
    6
    Uploads
    0

    Default

    looks like your dovecot config is wrong then the symlink should be in the user's directry along with a dir containing the sieve files.
    Roundcube Patches: Sieverules, SpamAssassin Prefs, and more…

  5. #145
    internalkernel's Avatar
    internalkernel is offline Registered User
    Join Date
    Jan 2010
    Posts
    25
    Downloads
    4
    Uploads
    0

    Default

    Quote Originally Posted by JohnDoh View Post
    internalkernel: i have setup a rule with 20 tests and then a fileinto and it saves just fine. could you post an example of one which doesnt work for you please?
    As you request... I have attached a screenshot of the rule set I attempted to make, and the result after hitting save... as well as the code produced in roundcube.sieve.

    I've made no changes in the sieverules folder (aside from copying config.inc.php.dist to config.inc.php).

    ~~
    I ended up resolving my issue with it, in part by figuring out the "List-ID" header and splitting the rules into different entries.
    ~~
    I just came across this entry in my logcheck files, seems to coordinate with the time I tried to save the filters:

    Code:
    line has bad date <[Sat Jan 23 11:24:42 2010] [error] [client xxx.xxx.xxx.xxx] ALERT - configured POST variable limit exceeded - dropped variable '_advoperator[]' (attacker 'xxx.xxx.xxx.xxx', file '/var/www/roundcube/index.php'), referer: https://my.domain.com/?_task=settings&_action=plugin.sieverules.add&_framed=1>
    Attached Images
    Attached Files
    Last edited by internalkernel; 01-23-2010 at 06:11 PM. Reason: # Update #

  6. #146
    pela020 is offline Roundcube Newcomer
    Join Date
    Jan 2010
    Location
    Sweden
    Posts
    3
    Downloads
    0
    Uploads
    0

    Thumbs up

    Quote Originally Posted by JohnDoh View Post
    looks like your dovecot config is wrong then the symlink should be in the user's directry along with a dir containing the sieve files.
    Yes, that did the trick.
    I changed from
    Code:
    sieve=~/.dovecot.sieve to 
    sieve=/home/vmail/%d/%n/.dovecot.sieve
    in the dovecot config
    Thank you for pointing me in the right direction.

  7. #147
    user20100124 is offline Roundcube Newcomer
    Join Date
    Jan 2010
    Posts
    4
    Downloads
    0
    Uploads
    0

    Default problems with regular expressions (replacement of slashes)

    In SieveRules regular expressions do not seem to be 100% working ... like "\" should be "\\" in the dovecot.sieve file. Is anybody facing similar problems?


    version information:

    Dovecot: 1.2.9
    RoundCube: 0.3.1
    SieveRules: 1.5

  8. #148
    JohnDoh is offline Super Moderator
    Join Date
    May 2007
    Posts
    1,206
    Downloads
    6
    Uploads
    0

    Default

    internalkernel and pela020 glad you got your problems sorted

    user20100124: there is nothing done to what you enter in the UI, if you want to escape a character you have to do it yourself. altering a test string behind the scenes seems a little dangerous to me, for example how would I knoww when you want \\n or \n?
    Roundcube Patches: Sieverules, SpamAssassin Prefs, and more…

  9. #149
    user20100124 is offline Roundcube Newcomer
    Join Date
    Jan 2010
    Posts
    4
    Downloads
    0
    Uploads
    0

    Default

    Example of a dovecot.sieve file:

    ------------------------------ snip ------------------------------
    require ["regex"];

    if allof (header :contains ["to", "cc"] "centos-announce@centos.org",
    header :regex "Subject" "^\\[CentOS-announce\\] .* CentOS (2|3|4) .*")
    {
    discard;
    stop;
    }
    ------------------------------ snip ------------------------------

    When loading a file like this one in the frontend i get the (correct) single slash I want ... saving is however not possible since there is a missing slash. If I use the advanced editor this is of course possible to fix ...


    edit: i have *lots* of rules with regex and it does not only break the current one you are working at.

  10. #150
    JohnDoh is offline Super Moderator
    Join Date
    May 2007
    Posts
    1,206
    Downloads
    6
    Uploads
    0

    Default

    ahh i see. check out the latest change in the repo. it should fix the disapearing slash.
    Roundcube Patches: Sieverules, SpamAssassin Prefs, and more…

+ Reply to Thread
Page 15 of 34 FirstFirst ... 5 13 14 15 16 17 25 ... LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts