jenkinsci / poll-mailbox-trigger-plugin

A Jenkins plugin, to poll an email inbox, and trigger jobs based on new emails.
https://plugins.jenkins.io/poll-mailbox-trigger-plugin/
MIT License
40 stars 32 forks source link

Unable to download email attachments with .msg extension #26

Open Jyothi-Prakash opened 7 years ago

Jyothi-Prakash commented 7 years ago

We would need to be able to download an outlook item(*.msg file), which is an attachment of an e-mail. With the latest version of the plugin we are able to download files with extensions such as txt,jpg,zip,html etc but it fails to save the msg file.

Steps to reproduce

Send a mail to the user, with subject line , matching the outlook rule criteria, which has another outlook mail item attached to it.

Expected behaviour

The attached outlook item should be saved to the timestamped directory.

Actual behaviour

The attachment is ignored, even though the configuration is to download it to a timestamped directory.

Server configuration

Operating system: Windows Server 2008

Jenkins Version: Jenkins ver. 1.651.1

Plugin Version: 1.025

Mail Server:

Additional Steps/Questions

We have a scenario, where we would receive a mail from our integration team with certain information required to trigger our build job. This release mail has an email attached to it, from which we would need to be able to get a file location. In outlook we have created a rule which would move the mails with a particular subject to a specific folder, that will be polled for new mails.

Config : pollingconfig

fukusuket commented 5 years ago

Same issue to me.

Content-disposition attachment filename doesn't seem to be given when attaching email in Outlook. (This issue was not reproduced in Thunderbird.) The bug reproduction MIME text is as follows.

Return-Path: foo@example.com Received: from MyComputer ([2001:268:c009:b51d:5d43:7228:929:e169]) by smtp.gmail.com with ESMTPSA id t8sm3847745pji.24.2019.08.09.00.37.21 for foo@example.com (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 09 Aug 2019 00:37:22 -0700 (PDT) From: foo@example.com To: foo@example.com Subject: Attachment file is msg Date: Fri, 9 Aug 2019 16:37:24 +0900 Message-ID: 0d4e01d54e85$4a833f70$df89be50$@gmail.com MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_0D4F_01D54ED0.BA6C1FF0" X-Mailer: Microsoft Outlook 16.0 Thread-Index: AdVOhUKIsCzQUhiQTZWiD5m4conwOg== Content-Language: ja

This is a multipart message in MIME format.

------=_NextPart_000_0D4F_01D54ED0.BA6C1FF0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit

Attachment file is msg

------=_NextPart_000_0D4F_01D54ED0.BA6C1FF0 Content-Type: message/rfc822 Content-Transfer-Encoding: 7bit Content-Disposition: attachment

Received: from MyComputer ([2001:268:c009:b51d:5d43:7228:929:e169]) by smtp.gmail.com with ESMTPSA id w18sm126883496pfj.37.2019.08.09.00.32.31 for foo@example.com (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 09 Aug 2019 00:32:32 -0700 (PDT) From: foo@example.com To: foo@example.com Subject: test msg Date: Fri, 9 Aug 2019 16:32:33 +0900 Message-ID: 06b901d54e84$9d63f140$d82bd3c0$@gmail.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQLChAekuaJ98UcUhDkT1J+MjG4I+A== Content-Language: ja

hello

------=_NextPart_000_0D4F_01D54ED0.BA6C1FF0--