Roundcube-未捕获的ArithmeticError:移位为负数

我已经安装了dovecot,postfix和roundcube,但是roundcube日志给出了此错误:

[12-Nov-2019 21:23:08 UTC] PHP Fatal error:  Uncaught ArithmeticError: Bit shift by negative number in /usr/share/roundcube/program/lib/des.inc:155
Stack trace:
#0 /usr/share/roundcube/program/lib/des.inc(39): des_createKeys('rcmail-!24ByteD...')
#1 /usr/share/roundcube/program/lib/Roundcube/rcube.php(815): des('rcmail-!24ByteD...','my_pass\x80',1,'\xF5|L^c\x9ESb')
#2 /usr/share/roundcube/program/include/rcmail.php(630): rcube->encrypt('my_pass\x80')
#3 /usr/share/roundcube/index.php(108): rcmail->login('username','my_pass','localhost',true)
#4 {main}
  thrown in /usr/share/roundcube/program/lib/des.inc on line 155

鸽舍也成功登录,该日志:

Nov 12 22:06:03 vpn dovecot[5485]: auth: Debug: auth client connected (pid=7044)
Nov 12 22:06:03 vpn dovecot[5485]: auth: Debug: client in: AUTH#0111#011PLAIN#011service=imap#011secured#011session=+3239214214124214#011lip=::1#011rip=::1#011lport=143#011rport=44084#011resp=<hidden>
Nov 12 22:06:03 vpn dovecot[5485]: auth-worker(6962): Debug: pam(username,::1,<+3239214214124214>): lookup service=dovecot
Nov 12 22:06:03 vpn dovecot[5485]: auth-worker(6962): Debug: pam(username,<+3239214214124214>): #1/1 style=1 msg=Password:
Nov 12 22:06:03 vpn dovecot[5485]: auth: Debug: client passdb out: OK#0111#011user=username
Nov 12 22:06:03 vpn dovecot[5485]: auth: Debug: master in: REQUEST#0113468820481#0117044#0111#011840aec7d8b7153511515135#011session_pid=70442#011request_auth_token
Nov 12 22:06:03 vpn dovecot[5485]: auth-worker(6962): Debug: passwd(username,<+a6unSyXNKgsg;lsdg>): lookup
Nov 12 22:06:03 vpn dovecot[5485]: auth: Debug: master userdb out: USER#0113468820481#011safa#011system_groups_user=username#011uid=1000#011gid=1000#011home=/home/username#011auth_token=3239214214124214
Nov 12 22:06:03 vpn dovecot[5485]: imap-login: Login: user=<username>,method=PLAIN,rip=::1,lip=::1,mpid=7048,secured,session=<+sakd;lafkflafas>
Nov 12 22:06:03 vpn dovecot[5485]: imap(username): Logged out in=29 out=522

我在php7.2中搜索了此错误,但我不明白如何纠正该错误。我使用dovecot来获取/发送邮件,但无法与Thunderbird连接。 编辑1

我在第155行中添加了/usr/share/roundcube/program/lib/des.inc:

$temp = (($left >> 4 & $masks[4]) ^ $right) & 0x0f0f0f0f; $right ^= $temp; $left ^= ($temp << 4);
$temp = (($right >> 16 & $masks[16]) ^ $left) & 0x0000ffff; $left ^= $temp; $right ^= ($temp << -16); //155 line
$temp = (($left >> 2 & $masks[2]) ^ $right) & 0x33333333; $right ^= $temp; $left ^= ($temp << 2);
$temp = (($right >> 16 & $masks[16]) ^ $left) & 0x0000ffff; $left ^= $temp; $right ^= ($temp << -16);
$temp = (($left >> 1 & $masks[1]) ^ $right) & 0x55555555; $right ^= $temp; $left ^= ($temp << 1);

jinwenyu2002 回答:Roundcube-未捕获的ArithmeticError:移位为负数

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/3112707.html

大家都在问