aws / aws/aws-encryption-sdk-java
duplicate requests on CMM cache miss
- 主要言語
- Java
- スター
- 240
- フォーク
- 125
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
### Problem:
While profiling an application we noticed duplicate request for encryption keys and decryption keys, typically after an DEK has just expired
### Solution:
The cause of this was on a miss used by expiration of an encryption DEK or a decryption DEK. In our case both were related to TTL
for a simple example - imaging 10 threads encrypting data, using the same keys. The key expires, and 10 threads, make 10 request to the MasterKey for 10 new encryption DEKs, which causes a little more latency, and cost (if the underlying KMS charges)
I think that the library can easily de-duplicate these requests (maybe as an option). We have done this in our application
Happy to contribute/colaborate on this but will need some steer from the maintainers
### Out of scope:
Is there anything the solution will intentionally NOT address?
[//]: # (NOTE: If you believe this might be a security issue, please email aws-security@amazon.com instead of creating a GitHub issue. For more details, see the AWS Vulnerability Reporting Guide: https://aws.amazon.com/security/vulnerability-reporting/ )
コントリビューションガイド
調査の方向性
まず、暗号化および復号における DEK の期限切れに関する CMM の cache miss 経路を追跡し、リクエストがどのように MasterKey に到達するかを確認します。並行スレッドと期限切れの TTL を使って報告されたケースを再現します。同等の並行 miss が重複排除され、キー取得の動作を変更しないこと、そして API またはオプションの設計について maintainer の指針が得られることを完了条件とします。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- cryptography, security
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100