Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Mailx proxy 163mailbox in Linux Centos 7 environment

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

First, install mailx

Yum-y install mailx

2. Preparation

[root@sea~] # vim / etc/mail.rcset from=sea_xyz@163.com # sender set smtp.163.com # 163smtp mail server set smtp-auth-user=youremail@163.com # your 163mailbox set smtp-auth-password=yourpass # Your 163e-mail password (set the encrypted authorization code of the page) set smtp-auth=login # action, Log in to set smtp-use-starttls # secure connection Transport set ssl-verify=ignore # ignore ssl authentication set nss-config-dir=/root/.certs # certificate path

Third, generate a certificate of 163

Mkdir-p / root/.certs/echo-n | openssl s_client-connect smtp.163.com:465 | sed-ne'/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > ~ / .certs/163.crtcertutil-A-n "GeoTrust SSL CA"-t "C,"-d ~ / .certs-I ~ / .certs/163.crtcertutil-A-n "GeoTrust Global CA"-t "C" "- d ~ / .certs-I ~ / .certs/163.crtcertutil-L-d / root/.certscd / root/.certs/certutil-A-n" GeoTrust SSL CA-G3 "- t" Pu,Pu,Pu "- d. /-I 163.crt

The following prompt indicates that it is normal.

Notice: Trust flag u is set automatically if the private key is present.

Fourth, test sending mail

Echo "Redhat7 changes the Aliyun yum source of Centos7 from yum source" | mailx-s "rpm-e yum redhat"-a Centos7_yum_org_aliyun.tar.gz othermail@126.com,yourqq@qq.com

Note: echo is the content of the message,-s is the subject of the message,-an is to add attachments, and multiple email addresses are separated by commas.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report