Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Getting BCC: header from a message.

by da (Friar)
on Jun 30, 2001 at 02:27 UTC ( [id://92826]=note: print w/replies, xml ) Need Help??


in reply to Getting BCC: header from a message.

I suspect you can use sendmail rules to rewrite the headers of the message, so it records the SMTP envelope "To" as a line in the message header, such as "X-Envelope-To".

Once upon a time, I was better at sendmail rules; but since I've switched my server to Exim, it's become a lot easier to handle things like this! ;-)

Update: I looked up the sendmail docs in the Bat Book. How's this for an idea: you could remove the "To" line from the email before it gets processed by sendmail. According to the docs, it will then record an "Apparently-To" header, which takes the address from the envelope.

35.10.2 Apparently-To:

When the message lacks a recipient

(sendmail) If the header of a mail message lacks recipient information (lacks all of the To:, Cc:, and Bcc: header lines), sendmail adds an Apparently-To: header line and puts the recipient's address from the envelope into the field of that line. This behavior is hard-coded into pre-8.7 sendmail, but beginning with version 8.7, it can be tuned with the NoRecipientAction option (see Section 34.8.43).

The Apparently-To: header name is not defined in RFC822. It is added by pre-8.7 sendmail because RFC822 requires at least one To: or Cc: header, and neither is present.

An Apparently-To: header should never be defined in the configuration file.

___
-DA

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://92826]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (2)
As of 2024-04-20 03:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found