{"action":"created","issue":{"url":"https://api.github.com/repos/MailScanner/v4/issues/65","repository_url":"https://api.github.com/repos/MailScanner/v4","labels_url":"https://api.github.com/repos/MailScanner/v4/issues/65/labels{/name}","comments_url":"https://api.github.com/repos/MailScanner/v4/issues/65/comments","events_url":"https://api.github.com/repos/MailScanner/v4/issues/65/events","html_url":"https://github.com/MailScanner/v4/pull/65","id":151664510,"number":65,"title":"Do not deliver message with whole content unparsable","user":{"login":"giosh94mhz","id":5219975,"avatar_url":"https://avatars.githubusercontent.com/u/5219975?v=3","gravatar_id":"","url":"https://api.github.com/users/giosh94mhz","html_url":"https://github.com/giosh94mhz","followers_url":"https://api.github.com/users/giosh94mhz/followers","following_url":"https://api.github.com/users/giosh94mhz/following{/other_user}","gists_url":"https://api.github.com/users/giosh94mhz/gists{/gist_id}","starred_url":"https://api.github.com/users/giosh94mhz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giosh94mhz/subscriptions","organizations_url":"https://api.github.com/users/giosh94mhz/orgs","repos_url":"https://api.github.com/users/giosh94mhz/repos","events_url":"https://api.github.com/users/giosh94mhz/events{/privacy}","received_events_url":"https://api.github.com/users/giosh94mhz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":16,"created_at":"2016-04-28T14:58:57Z","updated_at":"2016-05-01T19:13:56Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/MailScanner/v4/pulls/65","html_url":"https://github.com/MailScanner/v4/pull/65","diff_url":"https://github.com/MailScanner/v4/pull/65.diff","patch_url":"https://github.com/MailScanner/v4/pull/65.patch"},"body":"There is a bad behaviour with malformed multipart messages. This happens when a message containes the following snippet (for example):\r\n\r\n```\r\nContent-Type: multipart/mixed;\r\n?boundary=\"LONG_HASH\"\r\n```\r\nNote the spurious question mark. In this situation the message is completely replaced by a configured message and sent to the user, but it can't hardly find something useful there. It is much better to quarantine the message and prevent the sending.\r\n\r\nThe fix is quite simple, as MailScanner already handle a `cantparse` situation and I've just joined two very similar situations. In the end, the message is saved in the quarantine, the log message is the same as before, but the useless placeholder message is prevented.\r\n"},"comment":{"url":"https://api.github.com/repos/MailScanner/v4/issues/comments/216065222","html_url":"https://github.com/MailScanner/v4/pull/65#issuecomment-216065222","issue_url":"https://api.github.com/repos/MailScanner/v4/issues/65","id":216065222,"user":{"login":"giosh94mhz","id":5219975,"avatar_url":"https://avatars.githubusercontent.com/u/5219975?v=3","gravatar_id":"","url":"https://api.github.com/users/giosh94mhz","html_url":"https://github.com/giosh94mhz","followers_url":"https://api.github.com/users/giosh94mhz/followers","following_url":"https://api.github.com/users/giosh94mhz/following{/other_user}","gists_url":"https://api.github.com/users/giosh94mhz/gists{/gist_id}","starred_url":"https://api.github.com/users/giosh94mhz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giosh94mhz/subscriptions","organizations_url":"https://api.github.com/users/giosh94mhz/orgs","repos_url":"https://api.github.com/users/giosh94mhz/repos","events_url":"https://api.github.com/users/giosh94mhz/events{/privacy}","received_events_url":"https://api.github.com/users/giosh94mhz/received_events","type":"User","site_admin":false},"created_at":"2016-05-01T19:13:56Z","updated_at":"2016-05-01T19:13:56Z","body":"Well, I think we are going off topic here, since we started with bugfix and we are now discussing new features and configurations.\r\n\r\nLets's recap why I think this should be merged:\r\n* MailScanner is supposed to do this already if you look at [DisinfectAndDeliver function](https://github.com/MailScanner/v4/blob/05bb0c70cc1f745a22854170e3ab134b10185102/mailscanner/bin/MailScanner/MessageBatch.pm#L1052). The current version should delete messages which cannot be disinfected, parsed, and so on... so it's not a new feature, it's a bug.\r\n* we are talking about a mail which is REALLY broken according to RFC2045 and RFC2046, and more likely than not sent by broken software. No thunderbird, Outlook, or other MUA will ever send a very broken mail like this. \r\n* Last not least, is a real problem. I got many email from real users which complain about this particular issue and I made the fix for them (well... myself actually :).\r\n\r\nAbout the notification concern, I think that this kind of error should notified with a ruleset in `Send Notices` if any.\r\n\r\nThat's my opinion, I leave to the maintainer (ping @jcbenton) the final choice. \r\n\r\nPS: I'm not a native English speaker, so no rudeness/offence intended."}}