Skip to content

ytnef crashes with Segmentation fault parsing winmail.dat #102

@arisdizdarevic

Description

@arisdizdarevic

Hi, Yeraze

It seems there are some new segfault errors in last 2 versions of ytnef:
ytnef.x86_64 1.9.3-1 (SOGo Repository)
ytnef.x86_64 2.0.0-1 (SOGo Repository)

OS:
Red Hat Enterprise Linux 8.7 (Ootpa)

Complete mail and extracted winmail.dat file causing segfault in ytnef):
https://www.alcad.si/programi/sogo/mail-with-attachment.eml
https://www.alcad.si/programi/sogo/winmail.dat

Error:
ytnef -h (Yerase TNEF Exporter v2.0.0)
ytnef winmail.dat
ERROR: invalid alloc size 5443388 at ytnef.c : 529, suspected corruption (exceeded 524288 bytes)
Napaka segmentacije (izpis jedra)

If needed I can search for more mails causing segfault and send them to analyze.

Overview of winmail.dat (run with tnefparse -o winmail.dat -b):
Attachments:
Untitled Attachment
image001.jpg

Objects:
TNEF Version
OEM Codepage
Message Class
MAPI Properties
Attachment Rendering Data
Attachment File Name
Attachment Modification Date
Attachment Data
Attachment Meta File
Attachment
Attachment Rendering Data
Attachment Modification Date
Attachment Meta File
Attachment Data
Attachment File Name
Attachment

Properties:
MAPI_ALTERNATE_RECIPIENT_ALLOWED
MAPI_PRIORITY
MAPI_READ_RECEIPT_REQUESTED
MAPI_CONVERSATION_TOPIC
MAPI_CONVERSATION_INDEX
MAPI_DELETE_AFTER_SUBMIT
MAPI_SENTMAIL_ENTRYID
MAPI_SUBMIT_FLAGS
MAPI_PRIMARY_SEND_ACCOUNT
MAPI_NEXT_SEND_ACCT
MAPI_INTERNET_CODEPAGE
MAPI_MESSAGE_LOCALE_ID
MAPI_INTERNET_MAIL_OVERRIDE_FORMAT
MAPI_MESSAGE_EDITOR_FORMAT
MAPI_DEPARTMENT
MAPI_EMAIL_LIST
MAPI_EMAIL3DISPLAY_NAME
MAPI_EMAIL3ENTRY_ID
MAPI_EMAIL3ADDR_TYPE
MAPI_EMAIL3EMAIL_ADDRESS
MAPI_EMAIL3ORIGINAL_ENTRY_ID
MAPI_EMAIL3RICH_TEXT_FORMAT
MAPI_RTF_IN_SYNC
MAPI_MAPPING_SIGNATURE
MAPI_STORE_RECORD_KEY
MAPI_OBJECT_TYPE
MAPI_NATIVE_BODY
MAPI_STORE_SUPPORT_MASK
MAPI_STORE_UNICODE_MASK
MAPI_MDB_PROVIDER
MAPI_TNEF_CORRELATION_KEY
MAPI_RTF_SYNC_BODY_CRC
MAPI_RTF_SYNC_BODY_COUNT
MAPI_RTF_SYNC_PREFIX_COUNT
MAPI_RTF_SYNC_TRAILING_COUNT
MAPI_RTF_SYNC_BODY_TAG

No body found

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions