HiraokaHyperTools / msgreader

35 stars 9 forks source link

Distinguish between images attached and imaged nested in the body mail #14

Closed DevPan29 closed 3 years ago

DevPan29 commented 3 years ago

Hi @kenjiuno , this is not an issue but a question: sometimes an email can have images inside the body mail and images as attachments. I would like to know how to distinguish these two kind of attachments. I though that images in the body mail would have pidContentId field , infact I use that field to find cid: related and substitute it in the body mail with data:image/jpg;base64, conversion. Unfortunately also attached images has pidContentId but them shouldn't be inserted in the body mail.

How can I distinguish these two kind of images?

Kind regards.

kenjiuno commented 3 years ago

Hi. PidTagAttachmentHidden Canonical Property | Microsoft Docs will be possible data.

1.6.6 has been published and this will extract it:

DevPan29 commented 3 years ago

Hi @kenjiuno , thank you for your answer. It works correctly :-).

Kind regards. Alessandro

rakeshrio commented 1 year ago

Hi @kenjiuno ,

{ "dataType": "attachment", "extension": ".png", "name": "abz-logo-gray-green.png", "fileName": "abz-logo-gray-green.png", "dataId": 167, "contentLength": 23719, "fileNameShort": "abz-lo~1.png", "pidContentId": "abz-logo-gray-green.png@SNC.ff224570c491543c", "creationTime": "Tue, 09 May 2023 11:56:21 GMT", "lastModificationTime": "Tue, 09 May 2023 11:56:21 GMT", "attachmentHidden": true, "dataUrl": "blob:http://localhost:9091/b6c03749-6c9c-4cbf-9bde-73d33ef8e694" }.

Iam getting dataURL but if its not working its showing undefined when i paste in search url pf browser, is there any other way to extract the attachment. Thanks in advance