千家信息网

Blat-windows cmd命令行脚本SMTP模式发邮件的开源工具参数详细说明

发表于:2025-02-07 作者:千家信息网编辑
千家信息网最后更新 2025年02月07日,Blat-windows cmd命令行脚本SMTP模式发邮件的开源工具参数详细说明blat工具可以在命令行下使用发邮件,所以可能被×××用来盗取计算机文件。所以(1)不建议安装部署到system32目
千家信息网最后更新 2025年02月07日Blat-windows cmd命令行脚本SMTP模式发邮件的开源工具参数详细说明

Blat-windows cmd命令行脚本SMTP模式发邮件的开源工具参数详细说明

blat工具可以在命令行下使用发邮件,所以可能被×××用来盗取计算机文件。
所以(1)不建议安装部署到system32目录,也不要去设置环境变量; 建议自己编写的脚本与blat工具放在同一个目录即可;
(2)此工具会被360等安全软件报毒,所以安装部署前要先受信文件夹;
(3)英文本来源官网,中文版为理解学习对照 不保证翻译的准确性


syntax:

Blat -to [optional switches (see below)]
Blat -install [[[]]] [-q]
Blat -profile [-delete | ""] [profile1] [profileN] [-q]
Blat -h
--看不太懂!看个简单的用法:


Blat -body "test mail" -s "测试test" -t nn1183@qq.com -server smtp.qq.com -f 442624872@qq.com -u 442624872@qq.com -pw lcgcaflcjewvb


--邮件内容:test mail ;邮件主题:测试test ;收件人:n1183@qq.com ;发件人服务器:smtp.qq.com ;发件人:442624872@qq.com ; 账号:442624872@qq.com ; 密码:lcgcaflcjewvb;更多功能在这行命令的基础上去优化完善即可;


blat -h


--查看详细命令参数:

------------Installation (初始化设置) -----------

-install[SMTP|NNTP|POP3] [
[ [ [ []]]]]
: set server, sender, number of tries and port for profile
( and may be replaced by '-')
port defaults are SMTP=25, NNTP=119, POP3=110
default profile can be specified with a '-'
username and/or password may be stored to the registry
order of options is specific
use -installNNTP for storing NNTP information
use -installPOP3 for storing POP3 information
(sender and try are ignored, use '-' in place of these)

--设置服务器地址、发信邮箱、失败尝试次数、端口号、发信邮箱用户名、发信邮箱密码;
--端口号如果不设置,默认:SMTP=25, NNTP=119, POP3=110
--用户名和密码可以存到注册表中。

-------- The Basics (邮件与收信人)-----------

: file with the message body to be sent
if your message body is on the command line, use a hyphen (-)
as your first argument, and -body followed by your message
if your message will come from the console/keyboard, use the
hyphen as your first argument, but do not use -body option.
--邮件内容文件路径;如果是命令行的内容要 -body开头;
个人觉得使用文件路径比较好。

-of : text file containing more options (also -optionfile)

-to : recipient list (also -t) (comma separated)

--收件人名单;逗号分隔;简写"-t"。

-tf : recipient list filename

--收件人名单文件路径。

-cc : carbon copy recipient list (also -c) (comma separated)
--抄送人名单;逗号分隔;简写"-c"。

-cf : cc recipient list filename
--抄送人名单文件路径。

-bcc : blind carbon copy recipient list (also -b)(comma separated)
--密送人名单;逗号分隔;简"-b"。

-bf : bcc recipient list filename
--密送人名单文件路径。

-maxNames : send to groups of number of recipients
-ur : set To: header to Undisclosed Recipients if not using the -to and -cc options

-subject : subject line, surround with quotes to include spaces(also -s)

--邮件主题;简写"-s";

-ss : suppress subject line if not defined
-sf : file containing subject line

--包含主题的邮件内容;

-body : message body, surround with quotes to include spaces

--命令行邮件内容;

-sig : text file containing your email signature
--签名内容文件路径;

-tag : text file containing taglines, to be randomly chosen
-ps : final message text, possibly for unsubscribe instructions

--------- Registry overrides (发件参数) -----------

-p : send with server, user, and port defined in
: use username and password if defined in
-profile : list all profiles in the Registry
-server : specify SMTP server to be used (optionally, addr:port)

--服务器地址;

-serverSMTP
: same as -server
-serverNNTP
: specify NNTP server to be used (optionally, addr:port)
-serverPOP3
: specify POP3 server to be used (optionally, addr:port)
when POP3 access is required before sending email
-f : override the default sender address (must be known to server)

--发件人邮箱;

-i : a 'From:' address, not necessarily known to the server
-port : port to be used on the SMTP server, defaults to SMTP (25)
--端口号;一般放到server即可;
-portSMTP : same as -port
-portNNTP : port to be used on the NNTP server, defaults to NNTP (119)
-portPOP3 : port to be used on the POP3 server, defaults to POP3 (110)
-u : username for AUTH LOGIN (use with -pw)

--用户;

-pw : password for AUTH LOGIN (use with -u)

--密码;

-pu : username for POP3 LOGIN (use with -ppw)
-ppw : password for POP3 LOGIN (use with -pu)

---------- Miscellaneous RFC header switches(交互设置) --------------
-organization
: Organization field (also -o and -org)
-ua : include User-Agent header line instead of X-Mailer
-x
: custom 'X-' header. eg: -x "X-INFO: Blat is Great!"
-noh : prevent X-Mailer/User-Agent header from showing Blat homepage
-noh3 : prevent X-Mailer header entirely
-d : request disposition notification
-r : request return receipt
-charset : user defined charset. The default is ISO-8859-1
-a1

: add custom header line at the end of the regular headers
-a2
: same as -a1, for a second custom header line
-dsn : use Delivery Status Notifications (RFC 3461)
n = never, s = successful, f = failure, d = delayed
can be used together, however N takes precedence
-hdrencb : use base64 for encoding headers, if necessary
-hdrencq : use quoted-printable for encoding headers, if necessary
-priority : set message priority 0 for low, 1 for high

---------------- Attachment and encoding options(附件与设置) -----------------------
-attach : attach binary file(s) to message (filenames comma separated)

--附件是二进制文件路径;

-attacht : attach text file(s) to message (filenames comma separated)
--附件是文本文件路径;
-attachi : attach text file(s) as INLINE (filenames comma separated)

-embed : embed file(s) in HTML. Object tag in HTML must specify
content-id using cid: tag. eg:
-af : file containing list of binary file(s) to attach (comma separated)
-atf : file containing list of text file(s) to attach (comma separated)
-aef : file containing list of embed file(s) to attach (comma separated)
-base64 : send binary files using base64 (binary MIME)
-uuencode : send binary files UUEncoded
-enriched : send an enriched text message (Content-Type=text/enriched)
-unicode : message body is in 16- or 32-bit Unicode format
-html : send an HTML message (Content-Type=text/html)
-alttext : plain text for use as alternate text
-alttextf : plain text file for use as alternate text
-mime : MIME Quoted-Printable Content-Transfer-Encoding
-8bitmime : ask for 8bit data support when sending MIME
-multipart
: send multipart messages, breaking attachments on
KB boundaries, where is per 1000 bytes
-nomps : do not allow multipart messages

------- NNTP specific options (NNTP专用参数选项)-------------
-groups
: list of newsgroups (comma separated)

---------- Other options ------------------
-h : displays this help (also -?, /?, -help or /help)
-q : suppresses all output to the screen
--关闭回显;类似 echo off;

-debug : echoes server communications to a log file or screen (overrides -q if echoes to the screen)
-log : log everything but usage to
-timestamp : when -log is used, a timestamp is added to each log line
-ti : set timeout to 'n' seconds. Blat will wait 'n' seconds for
server responses
-try : how many times blat should try to send (1 to 'INFINITE')
-binary : do not convert ASCII | (pipe, 0x7c) to CrLf in the message
body
-hostname : select the hostname used to send the message via SMTP
this is typically your local machine name
-raw : do not add CR/LF after headers
-delay : wait x seconds between messages being sent when used with
-maxnames or -multipart
-comment : use this character to mark the start of commments in
options files and recipient list files. The default is ;
-superdebug : hex/ascii dump the data between Blat and the server
-superdebugT : ascii dump the data between Blat and the server


Note that if the '-i' option is used, is included in 'Reply-to:'
and 'Sender:' fields in the header of the message.

Optionally, the following options can be used instead of the -f and -i
options:

-mailfrom The RFC 821 MAIL From: statement
-from The RFC 822 From: statement
-replyto The RFC 822 Reply-To: statement
-returnpath The RFC 822 Return-Path: statement
-sender The RFC 822 Sender: statement

For backward consistency, the -f and -i options have precedence over these
RFC 822 defined options. If both -f and -i options are omitted then the
RFC 821 MAIL FROM statement will be defaulted to use the installation-defined
default sender address.

文件 邮件 路径 命令 内容 名单 参数 工具 密码 邮箱 主题 发件人 口号 收件人 服务器 用户 简写 逗号 附件 服务 数据库的安全要保护哪些东西 数据库安全各自的含义是什么 生产安全数据库录入 数据库的安全性及管理 数据库安全策略包含哪些 海淀数据库安全审计系统 建立农村房屋安全信息数据库 易用的数据库客户端支持安全管理 连接数据库失败ssl安全错误 数据库的锁怎样保障安全 昆山樱桃玩互联网科技有限公司 光遇服务器哪家做的 金仓数据库sql命令语句 dnf怀旧服租服务器 怎么连接一个网站和数据库 互联网时代怎样保证网络安全 廊坊网络技术培训班 税控盘怎么检查服务器是否在维护 双路服务器pcie的拓展口 软件开发简称什么 wifi定位服务器 水务服务器安全加固 java数据库沙箱 数据库中医治病 盘锦互助盘软件开发 宝腾网络技术有限公司 数据库局部变量声明 天津天空之城网络技术有限公司 网络安全维护难不 成都电力时间频率同步服务器 碧天网络技术有限公司 谈谈对数据库的认识400字左右 宝山区安装网络技术服务 做好冬奥行业网络安全工作 水务服务器安全加固 数据仓库是数据库的组成部分吗 曙光涉密服务器安全卡设置 港服ps4实况足球连不上服务器 四川软件开发专业哪个学校好 中国刑事警察学院网络安全
0