delphij's Chaos

选择chaos这个词是因为~~实在很难找到一个更合适的词来形容这儿了……

23 Oct 2022

UGFzc3dvcmQ6 是什么?

今天无意中看了一眼服务器日志,结果发现了一些奇怪的消息:

warning: unknown[122.168.199.151]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[176.8.89.240]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[185.232.21.42]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[206.217.216.13]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[220.196.249.145]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[5.253.204.74]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[70.45.212.49]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[93.177.73.82]: SASL LOGIN authentication failed: UGFzc3dvcmQ6
warning: unknown[93.177.75.66]: SASL LOGIN authentication failed: UGFzc3dvcmQ6

这里的 UGFzc3dvcmQ6 是什么呢?从直觉上看似乎是个 base64 编码的字符串。解码试试看,果然:

echo "UGFzc3dvcmQ6" | base64 --decode
Password:

这是个 Postfix 特有的特性,为了防止不慎在日志中写下用户的密码,它记录的是 SASL 库发给客户端的消息而不是用户名。

这里记一笔,方便以后找这个串来解谜的其他人。