0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

容量大きいファイル(10GB+)を暗号化するメモ

Last updated at Posted at 2022-06-15

背景

  • CG データとか機械学習データを社外とやりとりしたい
  • end-to-end 暗号化したい

情報

方法

RSA だと大きいファイルは暗号化できません.
鍵長は 4096 にしておくのが無難でしょうか.

リンクにあるように, PGP でもいいかもですが, 内部的には openssl で処理している?

openssl で AES256(aes-256-cbc?) を使う場合

openssl smime -encrypt -aes256 -in file -binary -outform DEM -out file.enc your.publickey.pem

CBC は暗号強度やや落ちるっぽい?ようです(要検証)

分割する

あとはファイルを分割して暗号化という手もあります. Linux で split コマンドでいけます.

Windows だとファイルの結合は type でできます.

Windows でファイル分割の場合は PowerShell のスクリプトを使うことになるでしょうか.

その他

エンコードとデコードはそこそこ時間かかります.

zstd 圧縮は CG や機械学習などのバイナリに有効かどうかは状況によるでしょう(PNG テクスチャだとあまり効果ない)

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?