aws / aws/aws-encryption-sdk-java

Allow to pass overrideConfiguration per request

未关闭
#2,107 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
Java
星标
240
派生
125
PR 合并指标
30 天内没有已合并 PR

描述

### Security issue notifications

If you discover a potential security issue in the AWS Encryption SDK we ask that you notify AWS Security via our [vulnerability reporting page](https://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public GitHub issue.

### Problem:

If i want to pass additional headers with Decrypt call (e.g Confused Deputy protection). I need to provide for each account own KmsClient. Instead in SdkV2 i can call .overrideConfiguration on request (you already use it for API_NAMESPACE).

If it will be possible to add .overrideConfiguration per call encrypt/decrypt i can use the same KmsClient for all accounts.

### Solution:

A description of the possible solution in terms of Encryption SDK architecture.

I see 2 options:
1. in AwsCrypto.decryptData/ecryptData provide additional argument with options
2. When construct KmsMasterKeyProvider ask for supplier for override. But there we need to send something in addition to identify context of request

### 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/ )

贡献指南

打开贡献指南

调研方向

首先跟踪 AwsCrypto.decryptData/encryptData 和 KmsMasterKeyProvider,以了解每个请求的 AWS SDK v2 overrideConfiguration 可以在哪里引入。将现有的 API_NAMESPACE 用法与提出的两个选项进行比较,然后定义 encrypt 和 decrypt 所需的请求上下文及 API 形式。完成的标准是,一个 KmsClient 可以为多个账户的请求提供服务,并且额外的 header 可以传递到 KMS 调用中。

由索引模型根据 Issue 内容生成。

评估

技术栈
aws, java
领域
backend-api-design, security
Issue 类型
功能
难度
5/5
预计耗时
一周以上
活跃度
停滞
描述清晰度
需要澄清
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。