From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: From: erik quanstrom Date: Sat, 11 Apr 2009 10:56:28 -0400 To: 9fans@9fans.net MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: [9fans] bogus header chars and empty messages, courtesy smtpd Topicbox-Message-UUID: da281402-ead4-11e9-9d60-3106f5b1d025 in the process of trying to make smtpd reject email with garbage characters in the headers, i ran headlong into a few long standing smtpd annoyances. smtpd has had an annoying habit of delivering empty messages when bad things happen, like sender timeout. it turns out that the problem is that writing to /dev/%d/notepg, which smtpd does to abort partially-delivered email is illegal if you are running as none. (/sys/src/9/port/devproc.c:425,426) it also turns out that setting pp to nil in the note catcher is antisocial and tends to leave behind broken processes. to address this, nupas smtpd now - uses syskill not syskillpg - doesn't set pp in the note catcher, and finally - insures that every character in the header is at least legal unicode. i put the source up at /n/sources/contrib/quanstro/nupas/smtp/smtpd.c - erik