>> I mean, that's not a reason in my thinking? Like, WHY do people want >> that? > >To be able to uniquely refer to that email in future by knowing what the >message-id field contains. The reference may be to oneself or to other >recipients. That is the purpose of the field. Not knowing the field's >value lessens its worth to tracing the flow through downstream parties >in log files.
I think we're probably not going to agree whether or not those reasons qualify as "vague", but, fine. That's not really my point; I honestly don't care if people want to generate their own Message-IDs. What I _do_ care about is when they do and then complain that nmh is using the "wrong" hostname to do so; I do not believe there is solution to this that will universally work, or even work in a large majority of cases considering the configuration of the modern Internet. To Mike's question: >Can we just use "localname" from mts.conf? We COULD, it would just be wrong for some people. That's the "local" hostname, and is used for a bunch of things INCLUDING constructing the default hostname for email addresses. But here's a thought experiment: let's say you set it to 'gmail.com' because your email is hosted at gmail. There's no way you could guarantee your Message-ID isn't going to be used by gmail.com already. Yes, you could send your default email address via another mechanism, but a quick glance at the code makes me realize that's still used for a bunch of things. We could add another knob, but honestly I'd rather people just use 'random' if the existing logic doesn't work for you. To Mike's other point: >> FWIW, I took a quick look at the MTAs Postfix and Sendmail; Postfix does >> not seem to have any Message-ID-specific configuration knobs, it hardcodes >> adding a Message-ID based on it's idea of the local hostname. Sendmail, >> yes, it looks like you could change it if you really want to; it also >> defaults to something based on the local hostname. I am personally >> skeptical that people actually configure this. > >gethostname() is not the same as what you said we were doing, which takes a >trip through /etc/hosts. Well, technically, it's constructing the Message-ID based on the value of the 'j' Sendmail macro, which is used for a ton of things; that macro value is configurable and in my limited sendmail experience you usually do explicitly configure it (I do not know what that defaults to). --Ken