Windows command implements anonymous mail sending

Source: Internet
Author: User
Tags nslookup

In the development of daily tools, there is often a need to send mail. In some high-level languages, such as python,c#, there are specialized mail-sending modules, such as the Smtplib module in Python. So, how is a message sent to a specific mailbox?

For example: use [email protected] to send an e-mail to [email protected].

First, look at the components of the mail system, such as

Then look at the whole process of sending mail, such as:


① senders use the SMTP protocol to send messages to their mailbox servers

②163 mail server uses the SMTP protocol to send mail to the QQ mail server

③ recipients use the POP3 protocol to read messages from the server side

In the above process we will find two questions:

The ①163 mail server needs to verify that the sender is a legitimate user. In other words, during the whole sending process, it is necessary to use the password of [email protected] to complete the mail sending process.

How does the ②163 mail server send mail to the QQ mail server? In fact, there is a process of domain name resolution in the middle. The sender resolves its server domain name (qq.com) according to the recipient's mailbox and, during that resolution, asks for the address of its mail server.

Since the verification process is in the 163 mail server, then we can not directly around the past, direct simulation request and QQ mail server to interact with it? The answer is yes, and the whole process of sending a message can be abstracted into

We can find the key point is how to resolve the QQ mail server address. Here we use the Windows command nslookup for Domain name resolution. To view the qq.com mail server address, you can use the command: Nslookup-qt=mx qq.com, the results are as follows:


where mail exchanger is followed by the qq.com mail server address.

In this way, we bypass the process of password verification, send the message directly to the recipient's mail server, want to know how the code is implemented, welcome to view the previous article "Python Write automated message anonymous send"

Windows command implements anonymous mail sending

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.