malware_mailの日記

個人メールアドレスに届いたマルウェアメールを記録

◎10/6

件名:Your Remittance Advice

From:accounts <accounts@適当なドメイン>

本文:

Please find attached.

Kind regards

Accounts Dept

SAVE PAPER – THINK BEFORE YOU PRINT!

This E-mail is confidential

It also may be legally privileged. If you are not the addressee you may not copy, forward, dislose or use any part of it. If you have received this message in error, please delete it and all copies from your system and notify the sender immediately by return E-mail.

Internet communications cannot be guaranteed to be timely secure, error or virus-free. The sender does not accept liability for any errors or ommisions.

 

 添付ファイル:数字4~6桁 Remittance.7z

ところが、

Content-Transfer-Encoding: quoted-printable 

と、base64になっていないため、保存しても7zファイル形式ではなく

それをbase64エンコードしたファイル(要はメールソースのまま)が保存されてしまいます。

certutil -decodeコマンドで復元してみました。

2017/10/06 21:15 3,972 4249 Remittance.7z
2017/10/06 21:15 3,976 609885 Remittance.7z
2017/10/06 21:15 3,972 6254 Remittance.7z
3 個のファイル 11,920 バイト


C:\1006YourRemittance>certutil -decode "4249 Remittance.7z" 4249.7z
入力長 = 3972
出力長 = 2898
CertUtil: -decode コマンドは正常に完了しました。

 

C:\1006YourRemittance>certutil -decode "609885 Remittance.7z" 609885.7z
入力長 = 3976
出力長 = 2901
CertUtil: -decode コマンドは正常に完了しました。

 

C:\1006YourRemittance>certutil -decode "6254 Remittance.7z" 6254.7z
入力長 = 3972
出力長 = 2898
CertUtil: -decode コマンドは正常に完了しました。

 

2017/10/06 21:15 3,972 4249 Remittance.7z
2017/10/06 21:18 2,898 4249.7z
2017/10/06 21:15 3,976 609885 Remittance.7z
2017/10/06 21:19 2,901 609885.7z
2017/10/06 21:15 3,972 6254 Remittance.7z
2017/10/06 21:19 2,898 6254.7z

 

復元した7zファイルの中身は、数字5~6桁 Remittance.vbs でした。

7zは3つありましたが、中身は一つ重複して2種類

https://www.virustotal.com/#/file/247bb27a3e16fbcbe7e4915827a10e9d59ace526f560db25201ea77587bb8b0c/detection

 

https://www.virustotal.com/#/file/ba427db647f875d5d22c8255637fb01a7422ef022e3df2a94470e6694bc2209b/detection

 

さらに3通追加。base64記述がないのは変わりません。

https://www.virustotal.com/#/file/3dbd1a4e8fbed310482842739cf468a4c1f60cb1cd21ab94a10d494942d5a566/detection

 

https://www.virustotal.com/#/file/9a9b49ae90011d8b4b6f9d8d156179ecbbd233e76b574c3c18d3f30922295226/detection

 

https://www.virustotal.com/#/file/f565375af657e5ca07a807e9ce099c6f6a770746a4cde2cac6953a56de395bf8/detection

 

さらに1通追加。デコードがエラーになったので保存された添付ファイルと、メールのソースを比較すると、末尾のパディング文字の「=」が2文字だったものが、保存すると1文字に減っていました。(これまでのメールはたまたまパディング文字なし)

テキストエディタで、末尾の「=」を「==」に修正してデコード。

C:\1006YourRemittance>certutil -decode "8818 Remittance.7z" 8818.7z
DecodeFile は データが無効です。 0x8007000d (WIN32: 13 ERROR_INVALID_DATA) を返しました
CertUtil: -decode コマンド エラーです: 0x8007000d (WIN32: 13 ERROR_INVALID_DATA)
CertUtil: データが無効です。

C:\1006YourRemittance>certutil -decode "8818 Remittance.7z" 8818.7z
入力長 = 3979
出力長 = 2902
CertUtil: -decode コマンドは正常に完了しました。

C:\1006YourRemittance>

7zファイルの中身は、54927 Remittance.vbsでした。

https://www.virustotal.com/#/file/5e9c3e3edd31f23d813abb6afbaa9f5caf18cfd4b94198e37bb40c1ccd8813b9/detection