SMTP header information

SMTP header information

The email contains header information. Why do you need header information other than the body?

 Consider mail. The post office has a registered mail service. This service records the delivery process of mail, etc. from acceptance to delivery, and compensates for the amount of damage in the unlikely event that the mail, etc. is damaged or does not arrive.

 You can also check the delivery status with the postal tracking system by using the acceptance number written on the registered receipt.

Email works in a similar way. To achieve this, the transfer process is recorded in the mail header.

 The email header contains a history of how the email was sent to its destination. All we see with our mailers is the body text below the headers. Mailers usually hide the mail headers.

 Unless you're having trouble, you don't need to check the information in the email headers. This is because there is no need to check the contents of the email headers for normal use.

 It's not that the email headers can't be verified. The mailer allows you to check the contents of the header from the menu.

 By recording the transfer process, you can check the sender's address, computer and server information, so you can identify spam mail and virus mail.

 Spam mails and virus mails disguise senders, computers and servers that pass through as false ones. In addition to the forwarding process, the email header also records CC and BCC information for sending emails to multiple people.

The mail header contains the items in the table below.

● SMTP header information

Date:Sent date and time of the email
From:Email sender address
Senders:Email sender's address.
 From: indicates the author of the email manuscript, and multiple addresses can be specified for From: when co-authored. Sender: represents the address of the person who actually sent the email.
 Due to the restrictions of mailers, there are many that can only describe one address in From:, so Sender: is usually not considered.
To:E-mail destination address
CC:Mail joint destination address
Bcc:Ditto (deleted on the recipient's email)
Subject:email subject
Message-Id:E-mail identification ID. It is assigned a unique value in the network.
Received:The name of the server received on the delivery path of the email. It is added for each MTA and used for route tracing.
Reply-to:Added when requesting a reply to an e-mail address different from the sender. The contents of the MAIL FROM: of the envelope.
In-Reply-To:A header that indicates which email you are replying to when replying. Message-ID is usually quoted.
References:Headers used when replying. References: and Message-Id: are quoted. Many mailers use this value to display threads.
Return-path:Address for sending an error notification when the mail does not reach the destination.
Mime-Version:Indicates the MIME version.
Content-Transfer-Encoding:Indicates the encoding type.

SMTP header information

The mail server also performs sorting by reading this header information.

 It's a bit confusing, but mail headers are not used in actual SMTP communication. It seems that the mail header indicates the address of the sender and the address written on the envelope in postal mail, but in SMTP communication, the envelope that plays the role of the envelope is used.

 When you compose an email using a mailer, an email header and an email body are created. When actually sending an email, communication is performed using the SMTP command, so the information in the email header is copied to the envelope and the communication is performed.

Email headers and envelopes

An email consists of an email header and body.

 The mail header consists of FROM (sender), TO (destination), Subject (title), etc. This is described in more detail in SMTP Header Information above. The text contains the text of the email to be sent to the other party.

 Here, although it is easy to misunderstand, mail headers are not used in actual SMTP communication. It seems that the mail header represents the address of the envelope and the address of the sender in terms of postal mail, but in SMTP communication, it is the envelope that plays the role of the envelope.

 Envelope is a word that means an envelope in English. The MTA (Message Transfer Agent) adds the sender and destination to the envelope. Mailers such as Outlook Express hide it from users.

 The mail header information is copied into the envelope during actual communication. This envelope information is used at the SMTP command level and is automatically created by the mailer, so it cannot be entered generally.

 The flow of communication in SMTP is to first connect with TCP, then send data in the order of source address, destination address, and mail text.

 To send the From address, use the MAIL command and specify "MAIL FROM:" as the argument to send the From address. After that, send the destination address with the RCPT command specifying "RCPT TO:" as an argument. Finally, the body of the email is sent.