aws / aws/aws-encryption-sdk-javascript
Examples for all new canonical examples
- Dominant language
- TypeScript
- Stars
- 260
- Forks
- 68
- Avg merge
- 22h 19m
- Merged PRs (30d)
- 2
Description
We are standardizing examples across all implementations. We started with Python[1] and Java[2], so all new implementations need to match those examples.
Related to https://github.com/awslabs/aws-encryption-sdk-specification/issues/103, it is important that these examples be as near as possible direct copies. The premise wording needs to be the same, wording of the step-by-step comments need to be the same, and we need to hit all the major points in the example.
# Necessary Examples
## API
- [ ] [How to encrypt and decrypt](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/onestep_defaults.py)
- [ ] [How to change the algorithm suite](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/onestep_unsigned.py)
- [ ] [How to encrypt and decrypt data streams in memory](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/in_memory_streaming_defaults.py)
- [ ] [How to encrypt and decrypt data streamed between files](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/file_streaming_defaults.py)
## Keyrings
### AWS KMS
- [ ] [How to use one AWS KMS CMK](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/single_cmk.py)
- [ ] [How to use multiple AWS KMS CMKs in different regions](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/multiple_regions.py)
- [ ] [How to decrypt when you don't know the CMK](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/discovery_decrypt.py)
- [ ] [How to decrypt within a region](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/discovery_decrypt_in_region_only.py)
- [ ] [How to decrypt with a preferred region but failover to others](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/discovery_decrypt_with_preferred_regions.py)
- [ ] [How to use AWS KMS clients with custom configuration](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/custom_kms_client_config.py) (details pending client supplier discussions)
- [ ] [How to use different AWS KMS client for different regions](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/aws_kms/custom_client_supplier.py) (details pending client supplier discussions)
### Raw keyrings
- [ ] [How to use a raw AES wrapping key](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/raw_aes/raw_aes.py)
- [ ] [How to use a raw RSA wrapping key](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/raw_rsa/keypair.py)
- [ ] [How to use a raw RSA wrapping key when the key is PEM or DER encoded](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/raw_rsa/keypair_from_pem.py)
- [ ] [How to encrypt with a raw RSA public key wrapping key without access to the private key](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/raw_rsa/public_private_key_separate.py)
### Multi-keyrings
- [ ] [How to combine AWS KMS with an offline escrow key](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/keyring/multi/aws_kms_with_escrow.py)
## Cryptographic Materials Managers
- [ ] [How to reuse data keys across multiple messages](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/crypto_materials_manager/caching/simple_cache.py)
- [ ] [How to restrict algorithm suites](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/crypto_materials_manager/custom/algorithm_suite_enforcement.py)
- [ ] [How to require encryption context fields](https://github.com/aws/aws-encryption-sdk-python/blob/master/examples/src/crypto_materials_manager/custom/requiring_encryption_context_fields.py)
[1] https://github.com/aws/aws-encryption-sdk-python/tree/master/examples
[2] https://github.com/aws/aws-encryption-sdk-java/tree/master/src/examples
Contributor guide
Assessment
This issue has not been assessed yet.