Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!sdd.hp.com!ucsd!ucbvax!naggum.uu.no!erik From: erik@naggum.uu.no (Erik Naggum) Newsgroups: comp.protocols.tcp-ip Subject: Re: An SMTP Question Message-ID: <9008072209.AAsvarte10538@svarte.ifi.uio.no> Date: 7 Aug 90 22:09:52 GMT References: <130400009@S61.Prime.COM> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 33 In article <130400009@S61.Prime.COM>, John Bradley writes: > I have an SMTP implementation that may or may not have a problem concerning > null characters in the mail data. RFC 821 states that the mail data may > contain any of the 128 ASCII character codes. This statement implys that > the null character must also be handled as mail data. Is this correct. That's what the standard says. I regard it as correct, and sendmail (et al) as broken. Yet another design flaw and disregard of standards in sendmail. Flame... > I spoke with some people about this and they do not know of any > implementation that supports this. We have a customer who feels > this is a problem. The mail text with a null will truncate that > line of the mail data since we are using C string functions. Any > comments or pointers will be appreciated. I think it's _wrong_ to use C string functions with Internet stuff. I made my own string library for use with network stuff. Would've been easier to do with C++ than C, but it still works pretty neatly. ((short*)string)[-1] is a length word. (256 bytes in a string is a little short of the goal, when RFC 821 says minimum maximum length of lines is 1000 characters.) Some very neat and usual expressions don't work this way. In fact, I think it's about as appropriate to use UNIX and C standard ways of doing things with the Internet as it would be with ASN.1 BER, but it tends to work most of the time, so people don't care. Aarrgghh!! [Erik Naggum] (a.k.a. "that damn purist") PS: I hope that mailing to tcp-ip and namedroppers is going to get rid of the ucbvax bogosity of using my Path field in the From header. Sorry about the problem. I didn't know this was done to my articles.