<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html;
      charset=windows-1252">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p><br>
    </p>
    <br>
    <div class="moz-cite-prefix">Op 30/05/2018 om 21:15 schreef Barry
      Pearce:<br>
    </div>
    <blockquote type="cite"
cite="mid:DB6P189MB04872861758C0AC7CBD47DBDC66C0@DB6P189MB0487.EURP189.PROD.OUTLOOK.COM">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      <style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
      <div style="font-family: Arial, Helvetica, sans-serif; font-size:
        12pt; color: rgb(0, 0, 0);">
        <br>
        Thanks for that. Turns out it was an issue with exim stripping
        the local part suffix from the envelope before passing over lmtp
        to dovecot. Fixed in the exim router config!<br>
        <br>
        Although if you turn on trace with spamtest it does result in a
        crash during mail receipt:<br>
        <br>
        <span style="font-family:monospace"><span
            style="font-weight:bold;color:#ff5454;background-color:#ffffff;">lmtp(<a class="moz-txt-link-abbreviated" href="mailto:test@test.net">test@test.net</a>)<7988><cDK3ADztDls0HwAANIsFaQ>:
            Panic: Unsupported 0x30 specifier starting at #38 in
            'extracted score=%.3f, max=%.3f, ratio=%.0f %%'</span><span
            style="color:#000000;background-color:#ffffff;"></span><br>
          <span
            style="font-weight:bold;color:#ff5454;background-color:#ffffff;"><br>
lmtp(<a class="moz-txt-link-abbreviated" href="mailto:test@test.net">test@test.net</a>)<7988><cDK3ADztDls0HwAANIsFaQ>: Error:
            Raw backtrace: /usr/lib/dovecot/libdovecot.so.0(+0xc7e87)
            [0x7fa1c8cf1e87] ->
            /usr/lib/dovecot/libdovecot.so.0(+0xc7f4a) [0x7fa<span><span
style="font-weight:bold;color:#ff5454;background-color:#ffffff;">1c8cf1f4a]
                -> /usr/lib/dovecot/libdovecot.so.0(i_fatal+0)
                [0x7fa1c8c5ebc9] ->
                /usr/lib/dovecot/libdovecot.so.0(+ [snip...]</span></span></span></span></div>
      <div style="font-family: Arial, Helvetica, sans-serif; font-size:
        12pt;"><span style="font-family: monospace;"><span
            style="font-weight: bold;"><font color="#ffffff"><span
                style="background-color: rgb(0, 0, 0);"><br>
              </span></font><font color="#ff5454"><span
                style="background-color: rgb(255, 255, 255);">lmtp(<a class="moz-txt-link-abbreviated" href="mailto:test@test.net">test@test.net</a>)<7988><cDK3ADztDls0HwAANIsFaQ>:
                Fatal: master: service(lmtp): child 7988 killed with
                signal 6 (core not dumped -
                <a class="moz-txt-link-freetext" href="https://dovecot.org/bugreport.html#coredumps">https://dovecot.org/bugreport.html#coredumps</a> - set </span></font><span
              style="color: rgb(255, 84, 84); background-color: rgb(255,
              255, 255);"><span
                style="font-weight:bold;color:#ff5454;background-color:#ffffff;">/proc/sys/fs/suid_dumpable
                to 2)</span></span></span><br>
        </span><br>
      </div>
    </blockquote>
    <br>
    Apparently, this is fixed for v2.3.2 already.<br>
    <br>
    Regards,<br>
    <br>
    Stephan.<br>
    <br>
    <blockquote type="cite"
cite="mid:DB6P189MB04872861758C0AC7CBD47DBDC66C0@DB6P189MB0487.EURP189.PROD.OUTLOOK.COM">
      <div style="font-family: Arial, Helvetica, sans-serif; font-size:
        12pt;">At least my problem is fixed - so thank you!<br>
        <br>
      </div>
      <hr style="display:inline-block;width:98%" tabindex="-1">
      <div id="divRplyFwdMsg" dir="ltr"><font style="font-size:11pt"
          face="Calibri, sans-serif" color="#000000"><b>From:</b>
          Stephan Bosch <a class="moz-txt-link-rfc2396E" href="mailto:stephan@rename-it.nl"><stephan@rename-it.nl></a><br>
          <b>Sent:</b> 30 May 2018 13:41<br>
          <b>To:</b> Barry Pearce; <a class="moz-txt-link-abbreviated" href="mailto:dovecot@dovecot.org">dovecot@dovecot.org</a><br>
          <b>Subject:</b> Re: Struggling with sieve, fileinto and
          variables.</font>
        <div> </div>
      </div>
      <div class="BodyFragment"><font size="2"><span
            style="font-size:11pt;">
            <div class="PlainText"><br>
              <br>
              Op 30-5-2018 om 14:01 schreef Barry Pearce:<br>
              > Hi,<br>
              ><br>
              > Im on Manjaro linux fully up to date running<br>
              ><br>
              >     dovecot 2.3.1-2<br>
              >     pigeonhole 0.5.1-2<br>
              ><br>
              ><br>
              > All is running well except I am having problems with
              fileinto - it <br>
              > refuses to use variables, and mailboxexists is also
              failing for me.<br>
              ><br>
              > Im just dealing with plus addressing - should be
              simple but the <br>
              > behaviour Im experiencing isnt right.<br>
              ><br>
              >     require ["variables", "envelope", "fileinto",
              "subaddress",<br>
              >     "mailbox"];<br>
              >     if envelope :matches :detail "to" "*" {<br>
              >         set :lower "name" "${1}";<br>
              >     }<br>
              >     fileinto :create "folder3";<br>
              ><br>
              ><br>
              > This works, but changing the last line to:<br>
              ><br>
              >     fileinto :create "${name}";<br>
              ><br>
              ><br>
              > fails and files into inbox. As does:<br>
              ><br>
              >     fileinto :create "${1}";<br>
              ><br>
              ><br>
              > It makes no difference if the fileinto is placed
              inside the if <br>
              > statement or otherwise. Using sieve-test suggests the
              basic scriptit <br>
              > should work and traces show the right action.<br>
              ><br>
              > On a related matter the script Im actually trying to
              get to work is:<br>
              ><br>
              >     require ["variables", "envelope", "fileinto",
              "subaddress",<br>
              >     "mailbox"];<br>
              ><br>
              >     if envelope :matches :detail "to" "*" {<br>
              >         set :lower "name" "${1}";<br>
              >     }<br>
              >     if mailboxexists "${name}" {<br>
              >             fileinto :create "${name}";<br>
              >     }<br>
              ><br>
              ><br>
              > But fails and files in the inbox.<br>
              <br>
              This happens for a reason, which you can either find in
              your syslog or <br>
              in the user log file (e.g. ~/.dovecot.sieve ->
              ~/.dovecot.sieve.log).<br>
              <br>
              <br>
              > Modifying the script to:<br>
              ><br>
              >     require ["variables", "envelope", "fileinto",
              "subaddress",<br>
              >     "mailbox"];<br>
              ><br>
              >     if envelope :matches :detail "to" "*" {<br>
              >         set :lower "name" "${1}";<br>
              >     }<br>
              ><br>
              >     if mailboxexists "${name}" {<br>
              >             fileinto :create "folder7";<br>
              >     } else {<br>
              >       fileinto :create "folder8";<br>
              >     }<br>
              ><br>
              ><br>
              > Files into folder8. So the mailboxexists is failing.<br>
              ><br>
              >      ## Started executing script 'plus-addressing'<br>
              >   3: envelope test<br>
              >   3:   starting `:matches' match with
              `i;ascii-casemap' comparator:<br>
              >   3:   getting `to' part from message envelope<br>
              >   3:   extracting `detail' part from address
              <a class="moz-txt-link-rfc2396E" href="mailto:test+folder4@test.net"><test+folder4@test.net></a><br>
              >   3:   matching value `folder4'<br>
              >   3:     with key `*' => 1<br>
              >   3:   finishing match with result: matched<br>
              >   3: jump if result is false<br>
              >   3:   not jumping<br>
              >   4: set command<br>
              >   7:   modify :lower "folder4" => "folder4"<br>
              >   7:   assign `name' [0] = "folder4"<br>
              >   7: mailboxexists test<br>
              >   7:   mailbox `folder4' cannot be opened<br>
              >   7:   some mailboxes are unavailable<br>
              >   7: jump if result is false<br>
              >   7:   jumping to line 9<br>
              >  10: fileinto action<br>
              >  10:   store message in mailbox `folder8'<br>
              >      ## Finished executing script 'plus-addressing'<br>
              ><br>
              > Here folder4 actually does exist - so the sieve-test
              confirms that <br>
              > issue.  Im at a loss as to whats going on. Im
              particularly perplexed <br>
              > by the difference in behaviour between sieve-test and
              the result under <br>
              > the live server.<br>
              <br>
              You can also get a trace for the live server: <br>
              <a
href="https://wiki2.dovecot.org/Pigeonhole/Sieve/Configuration#Trace_Debugging"
                moz-do-not-send="true">https://wiki2.dovecot.org/Pigeonhole/Sieve/Configuration#Trace_Debugging</a><br>
              <br>
              Regards,<br>
              <br>
              Stephan.<br>
              <br>
            </div>
          </span></font></div>
    </blockquote>
    <br>
  </body>
</html>