|
The most affected setup by this bug is Outlook connected via EAS
In webmail only single (problematic) mail is not displayed but in Outlook whole sync process get stocked for a while. |
|
|
do you have a stacktrace in coredumpctl? (you'll have to install debug packages to see them) |
|
|
do you really need it from my side?
it's 100% reproducible - just import eml from the link above to any mail folder (via IMAP client like Thunderbold) and try to access this mail via SoGo webmail |
|
|
Any progress? Any mail with TNEF attachment blocks Outlook sync completely |
|
|
Hi,
@the_nic and @AndreyEver the problem persists on Red Hat Enterprise Linux 8.7 in latest sogo 5.8.0 (sogo-5.8.0.20230219-1.el8.x86_64) - upgraded it today - 20.02.2023.
If I upload mail to my Maildir/new when opening in webmail error is still poping-up:
Feb 20 12:26:22 pushmail kernel: sogod[147591]: segfault at 10 ip 00007fe14aa59976 sp 00007ffd338756f0 error 4 in Mailer[7fe14a9f7000+78000]
Feb 20 12:26:22 pushmail kernel: Code: ff c6 85 51 f9 ff ff 00 c6 85 52 f9 ff ff 01 80 bd 51 f9 ff ff 00 0f 84 8f 00 00 00 48 8b 85 80 f9 ff ff 48 8b 00 48 83 c0 10 <8b> 00 89 85 58 f9 ff ff 8b 85 58 f9 ff ff 89 c7 e8 95 15 fd ff 85
More and more users are complaining EAS is not receiving new mails, for now the only solution is deleting mail in webmail and after that everything works.
@the_nic if needed I can post more sample emails to analyze
Br, Aris. |
|
|
Hi,
Just imported the eml on my dev env and sync with Window's mail through Active Sync and I didn't get any issue.
I have already met this case and the issue was in libytnef . I have 1.9.3 on no issue :
root@f392e0547ef8:/data/scripts# apt-cache policy libytnef0
libytnef0:
Installed: 1.9.3-1
Candidate: 1.9.3-1
Version table:
*** 1.9.3-1 500
500 http://ports.ubuntu.com/ubuntu-ports focal/universe arm64 Packages
100 /var/lib/dpkg/status
Could you try to upgrade this lib and try again ?
Sebastien |
|
|
Hi,
@sebastien regarding latest Sogo 5.8.0 and the same problem should I open new Issue or should we continue in this thread?
You should test inside sogo-webmail to reproduce the error.
Also I noticed problem (segfault) does not happend inside YTNEF but inside sogod-Mailer.
In SOGo repository the latest ytnef (also installed in our environment):
ytnef-2.0.0-1.x86_64 : Yerase's TNEF Stream Reader
Repo : SOGo
Matched from:
Provide : ytnef = 2.0.0-1
I'm aware of a problem in history of Sogo v5.7.1 and YTNEF (libytnef segfault with installed ytnef-2.6-12.el7.x86_64 from EPEL release), but this was solved after updating to ytnef-2.0.0-1.x86_64 from SOGo repo. Now new problem (happens ) is segfault in Mailer for some Microsoft RTF (TNEF-encoded) mails. |
|
|
No continue this thread.
Please provide :
Sebastien |
|
|
Bactrace of the segfault on our server (with sample mail from AndreyEver https://drive.google.com/file/d/11GKYok2fhuZsrV9f82zAb0rsKWZvfKnt/view?usp=sharing):
Feb 21 06:38:30 sogod [3941]: 192.168.5.191 "POST /SOGo/connect HTTP/1.0" 403 33/93 0.002 - - 0 - 14
Feb 21 06:41:16 sogod [3941]: 192.168.5.191 "GET /SOGo/ HTTP/1.0" 200 10412/0 0.013 37312 72% 0 - 14
Feb 21 06:41:22 sogod [3941]: 192.168.5.191 "POST /SOGo/so/passwordRecoveryEnabled HTTP/1.0" 403 0/53 0.002 - - 0 - 14
Feb 21 06:41:24 sogod [3941]: 192.168.5.191 "POST /SOGo/so/passwordRecoveryEnabled HTTP/1.0" 403 0/53 0.001 - - 0 - 14
Feb 21 06:41:24 sogod [3941]: <0x0x555555c74ef0[GCSChannelManager]> db for mysql://195.216.253.147/sogo/users is now back up
Feb 21 06:41:24 sogod [3941]: SOGoRootPage successful login from '192.168.5.191' for user 'aris.dizdarevic@alcad.si' - expire = -1 grace = -1
Feb 21 06:41:24 sogod [3941]: 192.168.5.191 "POST /SOGo/connect HTTP/1.0" 200 48/93 0.019 - - 0 - 16
Feb 21 06:41:25 sogod [3941]: 192.168.5.191 "GET /SOGo/aris.dizdarevic%40alcad.si HTTP/1.0" 302 0/0 0.005 - - 0 - 16
Feb 21 06:41:25 sogod [3941]: 192.168.5.191 "GET /SOGo/aris.dizdarevic%40alcad.si/view HTTP/1.0" 302 0/0 0.007 - - 0 - 16
Feb 21 06:41:25 sogod [3941]: 192.168.5.191 "GET /SOGo/so/aris.dizdarevic@alcad.si/Mail HTTP/1.0" 302 0/0 0.004 - - 0 - 16
Feb 21 06:41:25 sogod [3941]: 192.168.5.191 "GET /SOGo/so/aris.dizdarevic@alcad.si/Mail/view HTTP/1.0" 200 23202/0 0.054 89562 74% 2M - 16
Feb 21 06:41:26 sogod [3941]: <0x0x555555c1ae80[NGImap4Client]> TLS started successfully.
Feb 21 06:41:26 sogod [3941]: 192.168.5.191 "POST /SOGo/so/aris.dizdarevic@alcad.si/Mail/0/folderINBOX/changes HTTP/1.0" 200 27/126 0.354 - - 28K - 17
Feb 21 06:41:26 sogod [3941]: <0x0x5555561d6510[SOGoWebDAVAclManager]> entry '{DAV:}write' already exists in DAV permissions table
Feb 21 06:41:26 sogod [3941]: <0x0x5555561d6510[SOGoWebDAVAclManager]> entry '{DAV:}write-properties' already exists in DAV permissions table
Feb 21 06:41:26 sogod [3941]: <0x0x5555561d6510[SOGoWebDAVAclManager]> entry '{DAV:}write-content' already exists in DAV permissions table
Feb 21 06:41:26 sogod [3941]: 192.168.5.191 "GET /SOGo/so/aris.dizdarevic@alcad.si/Calendar/alarmslist?browserTime=1676979686 HTTP/1.0" 200 60/0 0.013 - - 0 - 17
Feb 21 06:41:27 sogod [3941]: 192.168.5.191 "GET /SOGo/so/aris.dizdarevic@alcad.si/Mail/0/view HTTP/1.0" 200 2116/0 0.192 - - 0 - 17
Feb 21 06:41:27 sogod [3941]: 192.168.5.191 "POST /SOGo/so/aris.dizdarevic@alcad.si/Mail/0/folderINBOX/view HTTP/1.0" 200 32711/48 0.488 - - 4M - 17
Feb 21 06:41:27 sogod [3941]: 192.168.5.191 "POST /SOGo/so/aris.dizdarevic@alcad.si/Mail/unseenCount HTTP/1.0" 200 19/31 0.081 - - 0 - 17
Feb 21 06:41:28 sogod [3941]: 192.168.5.191 "GET /SOGo/so/aris.dizdarevic@alcad.si/Mail/0/folderINBOX/labels HTTP/1.0" 200 223/0 0.113 - - 0 - 17
Feb 21 06:41:51 sogod [3941]: [RM:MailerUI] LOOKUP FAILED: UIxMailPartTNEFViewer
Feb 21 06:41:51 sogod [3941]: [RM:MailerUI] PARENT (<0x0x555555a6e250[WEResourceManager]:>) SAID: (null)
ERROR: invalid alloc size 1340286 at ytnef.c : 529, suspected corruption (exceeded 524288 bytes)
Feb 21 06:41:52 sogod [3941]: [WARN] <0x555556573b10[SOGoTNEFMailBodyPart]:2> Unidentified extension .pdf
Feb 21 06:41:52 sogod [3941]: [WARN] <0x555556573b10[SOGoTNEFMailBodyPart]:2> Unidentified extension .xlsx
Feb 21 06:41:52 sogod [3941]: [WARN] <0x555556573b10[SOGoTNEFMailBodyPart]:2> Unidentified extension .jpg
Feb 21 06:41:52 sogod [3941]: [WARN] <0x555556573b10[SOGoTNEFMailBodyPart]:2> Unidentified extension .doc
Feb 21 06:41:52 sogod [3941]: [WARN] <0x555556573b10[SOGoTNEFMailBodyPart]:2> Unidentified extension .pdf
Program received signal SIGSEGV, Segmentation fault.
-[SOGoTNEFMailBodyPart decodeBLOB] (self=0x555556573b10, _cmd=0x7fffe86091c0 <_OBJC_SELECTOR_TABLE+96>) at SOGoTNEFMailBodyPart.m:708
708 SOGoTNEFMailBodyPart.m: Datoteka ali imenik s tem imenom ne obstaja.
(gdb)
"Datoteka ali imenik s tem imenom ne obstaja" translates to english "A file or directory with this name does not exist" |
|
|
- Do you have step by step guide to reproduce ? This is not reproductible on my side
- Try reproduce on demo.sogo.nu
- Do you have enough memory on the server ?
Sebastien |
|
|
-
I can not reproduce on demo.sogo.nu: 1. I don't have SSH access to upload mail-file, 2. I don't have webmail access, 3. In webmail interface there is no error visible - upon select of faulty mail it doesn't show anything, just loading forever
-
free -m is showing Total: 16gB, used: 4gB, free 9Gb, buff/cache 3g Instance of redhat and sogo is clean-install and only 2 users are on this server (was made just for purpose of checking and trying to solve this problem).
-
Step-by-step guide:
ssh mailserver
cd /var/vmail/aris.dizdarevic@alcad.si/new
wget https://www.alcad.si/programi/sogo/mail-with-attachment.eml (Another sample of mail-file we noticed the same problem)
chown vmail. mail-with-attachment.eml
on my personal computer in Google Chrome I open pushmail2.alcad.si (Sogo-webmail - login with aris.dizdarevic@alcad.si)
in webmail interface select uploaded mail-file in inbox (Sender and title: Aljaž Riner: Sestanek Unior) - segfault error occurs
There is another way I tried manuall test of ytnef and I have reproduced and acknowledged error is indeed inside YTNEF (Perhaps we should send problem to https://github.com/Yeraze/ytnef):
mimeexplode mail-with-attachment.eml
ytnef msg1/winmail.dat
ERROR: invalid alloc size 5443388 at ytnef.c : 529, suspected corruption (exceeded 524288 bytes)
Or visible also in debug mode of sogo (upon selection of mail in webmail interface):
Feb 21 08:41:41 sogod [10263]: [RM:MailerUI] LOOKUP FAILED: UIxMailPartTNEFViewer
Feb 21 08:41:41 sogod [10263]: [RM:MailerUI] PARENT (<0x0x555555a6e1a0[WEResourceManager]:>) SAID: (null)
ERROR: invalid alloc size 5443388 at ytnef.c : 529, suspected corruption (exceeded 524288 bytes)
Program received signal SIGSEGV, Segmentation fault.
-[SOGoTNEFMailBodyPart decodeBLOB] (self=0x5555560ecb40, _cmd=0x7fffe86091c0 <_OBJC_SELECTOR_TABLE+96>) at SOGoTNEFMailBodyPart.m:708
708 SOGoTNEFMailBodyPart.m: Datoteka ali imenik s tem imenom ne obstaja.
And for last thing I downgraded ytnef to version you are reffering:
dnf install ytnef-1.9.3-1.x86_64
ytnef (shows Yerase TNEF Exporter v1.9.3)
ytnef msg1/winmail.dat
ERROR: invalid alloc size 5443628 at ytnef.c : 1183, suspected corruption
ERROR processing file
Additional info of server and repositories:
Linux pushmail2 4.18.0-425.3.1.el8.x86_64 0000001 SMP Fri Sep 30 11:45:06 EDT 2022 x86_64 x86_64 x86_64 GNU/Linux (Red Hat Enterprise Linux 8.7 (Ootpa))
ytnef.x86_64 2.0.0-1 (Repository: @SOGo)
ytnef.x86_64 1.9.3-1 (Repository: @SOGo) - Tried also this version
sogo.x86_64 5.8.0.20230220-1.el8 (Repository: @SOGo)
sogo-activesync.x86_64 (Repository: @SOGo)
sogo-ealarms-notify.x86_64 (Repository: @SOGo)
sogo-tool.x86_64 (Repository: @SOGo) |
|
|
I can reproduce this on the demo.sogo.nu webinterface:
- write a message
- attach the problematic eml (original download link)
- save as a draft
- try to view this draft
result: the GET request to https://demo.sogo.nu/SOGo/so/sogo1/Mail/view#!/Mail/0/Drafts/4 finishes with status 502, ui doesn't display the mail but a "Proxy Error"
I also attached the problematic eml directly to this ticket. |
|
|
@sebastien
root@mail:~# apt-cache policy libytnef0
libytnef0:
Installed: 2.0-1
Candidate: 2.0-1
Version table:
*** 2.0-1 500
500 https://packages.inverse.ca/SOGo/nightly/5/debian bullseye/bullseye amd64 Packages
100 /var/lib/dpkg/status
1.9.3-3 500
500 http://deb.debian.org/debian bullseye/main amd64 Packages
root@mail:~# uname -a
Linux mail.--- 5.10.0-20-amd64 0000001 SMP Debian 5.10.158-2 (2022-12-13) x86_64 GNU/Linux
To reproduce:
- upload eml (from the top message) via IMAP
- view it via SoGo webmail or Outloot EAS
(in case of Sogo webmail: segfault + cannot display mail, in case of Outloot EAS: segfault + stuck in Outlook replication for good)
|
|
|
More and more mails are coming to mail server generating segfault. Latest one was sent from Outlook 2007
I just uploaded another 2 samples you can use to analyze. |
|
|
Hi there,
I cannot reproduced on Ubuntu 20.04 (arm) with libytnef 1.9.3 (provided by packages).
So I compiled libytnef 2.0 and after that the problem appeared. There is a memcopy on NULL data.
This is probably an issue in libtynef.
I made a fix to avoid segfault : https://github.com/Alinto/sogo/commit/02f855059babc7e01b25c1cf01d44dae52c777a1
Will be available in next nightly build.
Sebastien |
|