LoginSignup
0
0

More than 1 year has passed since last update.

thunderbirdのOpenPGPで復号化できなかったメールをコマンドラインから

Last updated at Posted at 2021-09-22

メールをファイルとして保存(~/Downloads/message.eml)してから、下記のコマンドで復号します。

gpg -d --ignore-mdc-error Downloads/message.eml

メールの文字コードがISO-2022-JPの場合は、続けて文字コード変換します。

gpg -d --ignore-mdc-error Downloads/message.eml | iconv -f ISO2022JP -t UTF-8

文字コードが分からない場合は、メールのソースの下記の箇所を確認します。

Content-Type: text/plain; charset=Shift_JIS

メールの文字コードがShift_JISであれば、次のように変換します。

gpg -d --ignore-mdc-error Downloads/message.eml | iconv -f SJIS -t UTF-8
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0