Unable to process attachments using logstash 7.6.0 IMAP Input plugin

I have configured logstash input to process emails from Gmail/Outlook using IMAP Input plugin. I am getting error when the email contains attachments or images. 
Sample config below-

input {
	imap {
		host => "xyz.com"
		password => "acc"
		user => "user"
		content_type => "multipart/alternative"
	 }
}

Below error details-
Encountered error NoMethodError {:message=>Can not
decode an entire message, try calling #decoded on the various fields and body or parts if it is a multipart message.

Any help appreciated.

Thanks.

Hello @Diptee

You seem to be facing this limitation:

There are few pending Pull Request to improve attachment behavior:

I've never personally used the Logstash imap input plugin, but there's an option strip_attachments (doc) to ignore them

Thank you! @Luca_Belluccini

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.