|
| 1 | +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. |
| 2 | +// SPDX-License-Identifier: Apache-2.0 |
| 3 | + |
| 4 | +// The AWS Encryption SDK - Java does not implement |
| 5 | +// any of the Keyring interface at this time. |
| 6 | + |
| 7 | +//= compliance/framework/aws-kms/aws-kms-mrk-aware-multi-keyrings.txt#2.5 |
| 8 | +//= type=exception |
| 9 | +//# The caller MUST provide: |
| 10 | +//# |
| 11 | +//# * A set of Region strings |
| 12 | +//# |
| 13 | +//# * An optional discovery filter that is an AWS partition and a set of |
| 14 | +//# AWS accounts |
| 15 | +//# |
| 16 | +//# * An optional method that can take a region string and return an AWS |
| 17 | +//# KMS client e.g. a regional client supplier |
| 18 | +//# |
| 19 | +//# * An optional list of AWS KMS grant tokens |
| 20 | +//# |
| 21 | +//# If an empty set of Region is provided this function MUST fail. If |
| 22 | +//# any element of the set of regions is null or an empty string this |
| 23 | +//# function MUST fail. If a regional client supplier is not passed, |
| 24 | +//# then a default MUST be created that takes a region string and |
| 25 | +//# generates a default AWS SDK client for the given region. |
| 26 | +//# |
| 27 | +//# A set of AWS KMS clients MUST be created by calling regional client |
| 28 | +//# supplier for each region in the input set of regions. |
| 29 | +//# |
| 30 | +//# Then a set of AWS KMS MRK Aware Symmetric Region Discovery Keyring |
| 31 | +//# (aws-kms-mrk-aware-symmetric-region-discovery-keyring.md) MUST be |
| 32 | +//# created for each AWS KMS client by initializing each keyring with |
| 33 | +//# |
| 34 | +//# * The AWS KMS client |
| 35 | +//# |
| 36 | +//# * The input discovery filter |
| 37 | +//# |
| 38 | +//# * The input AWS KMS grant tokens |
| 39 | +//# |
| 40 | +//# Then a Multi-Keyring (../multi-keyring.md#inputs) MUST be initialize |
| 41 | +//# by using this set of discovery keyrings as the child keyrings |
| 42 | +//# (../multi-keyring.md#child-keyrings). This Multi-Keyring MUST be |
| 43 | +//# this functions output. |
| 44 | + |
| 45 | +//= compliance/framework/aws-kms/aws-kms-mrk-aware-multi-keyrings.txt#2.6 |
| 46 | +//= type=exception |
| 47 | +//# The caller MUST provide: |
| 48 | +//# |
| 49 | +//# * An optional AWS KMS key identifiers to use as the generator. |
| 50 | +//# |
| 51 | +//# * An optional set of AWS KMS key identifiers to us as child |
| 52 | +//# keyrings. |
| 53 | +//# |
| 54 | +//# * An optional method that can take a region string and return an AWS |
| 55 | +//# KMS client e.g. a regional client supplier |
| 56 | +//# |
| 57 | +//# * An optional list of AWS KMS grant tokens |
| 58 | +//# |
| 59 | +//# If any of the AWS KMS key identifiers is null or an empty string this |
| 60 | +//# function MUST fail. At least one non-null or non-empty string AWS |
| 61 | +//# KMS key identifiers exists in the input this function MUST fail. All |
| 62 | +//# AWS KMS identifiers are passed to Assert AWS KMS MRK are unique (aws- |
| 63 | +//# kms-mrk-are-unique.md#Implementation) and the function MUST return |
| 64 | +//# success otherwise this MUST fail. If a regional client supplier is |
| 65 | +//# not passed, then a default MUST be created that takes a region string |
| 66 | +//# and generates a default AWS SDK client for the given region. |
| 67 | +//# |
| 68 | +//# If there is a generator input then the generator keyring MUST be a |
| 69 | +//# AWS KMS MRK Aware Symmetric Keyring (aws-kms-mrk-aware-symmetric- |
| 70 | +//# keyring.md) initialized with |
| 71 | +//# |
| 72 | +//# * The generator input. |
| 73 | +//# |
| 74 | +//# * The AWS KMS client that MUST be created by the regional client |
| 75 | +//# supplier when called with the region part of the generator ARN or |
| 76 | +//# a signal for the AWS SDK to select the default region. |
| 77 | +//# |
| 78 | +//# * The input list of AWS KMS grant tokens |
| 79 | +//# |
| 80 | +//# If there is a set of child identifiers then a set of AWS KMS MRK |
| 81 | +//# Aware Symmetric Keyring (aws-kms-mrk-aware-symmetric-keyring.md) MUST |
| 82 | +//# be created for each AWS KMS key identifier by initialized each |
| 83 | +//# keyring with |
| 84 | +//# |
| 85 | +//# * AWS KMS key identifier. |
| 86 | +//# |
| 87 | +//# * The AWS KMS client that MUST be created by the regional client |
| 88 | +//# supplier when called with the region part of the AWS KMS key |
| 89 | +//# identifier or a signal for the AWS SDK to select the default |
| 90 | +//# region. |
| 91 | +//# |
| 92 | +//# * The input list of AWS KMS grant tokens |
| 93 | +//# |
| 94 | +//# NOTE: The AWS Encryption SDK SHOULD NOT attempt to evaluate its own |
| 95 | +//# default region. |
| 96 | +//# |
| 97 | +//# Then a Multi-Keyring (../multi-keyring.md#inputs) MUST be initialize |
| 98 | +//# by using this generator keyring as the generator keyring (../multi- |
| 99 | +//# keyring.md#generator-keyring) and this set of child keyrings as the |
| 100 | +//# child keyrings (../multi-keyring.md#child-keyrings). This Multi- |
| 101 | +//# Keyring MUST be this functions output. |
| 102 | + |
| 103 | + |
| 104 | + |
0 commit comments