Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: Support AWS Cryptographic Material Providers Library (MPL) #685

Merged
merged 40 commits into from
Nov 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
ac79bc8
feat: Add MPL and hierarchy keyring example (#634)
lucasmcdonald3 Apr 23, 2024
44d9192
feat: Required encryption context CMM (#645)
lucasmcdonald3 Apr 26, 2024
91d06ae
chore: Merge from master (#670)
lucasmcdonald3 Apr 30, 2024
750bb68
chore: Added KMS keyring example (#659)
RitvikKapila May 2, 2024
88e6d58
chore: added raw rsa and raw aes keyring examples (#661)
RitvikKapila May 2, 2024
428fe95
chore: added keyring examples (kms_rsa, multi, discovery) (#671)
RitvikKapila May 3, 2024
52ad465
chore(examples): Added mrk and mrk_multi keyring examples (#673)
RitvikKapila May 3, 2024
e47e441
chore(examples): added mrk discovery keyring examples (#675)
RitvikKapila May 6, 2024
2a35192
chore(examples): Added file_streaming, migration and set_encryption_a…
RitvikKapila May 7, 2024
986f54c
feat(test_vector_handlers): TestVectors test with MPL constructs (#650)
lucasmcdonald3 May 8, 2024
70d1364
chore(keyring examples): refactor keyring examples and move master ke…
RitvikKapila May 10, 2024
bd32c79
chore: Sync from master (#682)
lucasmcdonald3 May 20, 2024
ebbc26b
chore: performance tests for ESDK-python (#680)
RitvikKapila Jun 5, 2024
39d4498
chore(performance_tests): added hierarchy keyring and caching cmm tes…
RitvikKapila Jun 7, 2024
3476816
chore(migration examples): added KMS, raw AES and raw RSA keyring/MKP…
RitvikKapila Jun 13, 2024
fc8fd38
chore(custom_cmm_example.py): added test for custom_cmm_example.py (#…
RitvikKapila Jun 26, 2024
fceb2b0
chore(MPL): Update README and primary pydocs (#658)
lucasmcdonald3 Jul 30, 2024
ca7e159
chore: Change MPL branch, remove PYTHONPATH workarounds (#683)
lucasmcdonald3 Aug 5, 2024
0de58cd
feat(test_vector_handlers): Hierarchy keyring test vectors (#674)
lucasmcdonald3 Aug 7, 2024
5e813e7
chore(examples): Added raw RSA/AES keyring multithreaded examples (#694)
lucasmcdonald3 Aug 8, 2024
ffe28d9
merge
lucasmcdonald3 Aug 9, 2024
ff29a05
merge
lucasmcdonald3 Aug 9, 2024
1c73a65
test: Required encryption context CMM integration tests (#691)
lucasmcdonald3 Aug 16, 2024
1df7dbc
fix(Examples): Validate EC on decrypt (#697)
lucasmcdonald3 Aug 19, 2024
91aca72
chore: Refer to renamed MPL libraries (#698)
lucasmcdonald3 Sep 6, 2024
0f19a45
Update README.rst
lucasmcdonald3 Oct 2, 2024
219c905
fix(CI): Fix oracle linting (#702)
lucasmcdonald3 Oct 3, 2024
45f386e
fix(test): Fix building ESDK-Net (#703)
lucasmcdonald3 Oct 4, 2024
5b2b116
chore(examples): fix comments (#705)
RitvikKapila Oct 8, 2024
ea82181
chore(MPL): Rename MPL Python package (#706)
lucasmcdonald3 Oct 23, 2024
f37b355
Merge branch 'master' into mpl-reviewed
lucasmcdonald3 Oct 23, 2024
c14f7fe
chore: Point at PyPI MPL (#709)
lucasmcdonald3 Oct 24, 2024
cb56504
chore(release): Bump ESDK version, add changelog (#710)
lucasmcdonald3 Oct 28, 2024
2bdd114
chore(CI): Fix TestVectors timeout (#711)
lucasmcdonald3 Oct 28, 2024
8383b06
Update src/aws_encryption_sdk/internal/formatting/deserialize.py
lucasmcdonald3 Oct 29, 2024
9cddd41
feat(TestVectors): Decrypt "golden" manifest (#721)
lucasmcdonald3 Oct 30, 2024
abfca22
chore(CI): Bump from macOS 12 to 13 (#723)
lucasmcdonald3 Nov 4, 2024
dcf2de7
chore: Bump to MPL 1.7.4 (#727)
lucasmcdonald3 Nov 11, 2024
311b8f7
Merge from master
lucasmcdonald3 Nov 12, 2024
7e7c12a
chore: Increase timeout for CodeBuild CI (#729)
lucasmcdonald3 Nov 12, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# .coveragerc file when running coverage WITHOUT coverage for the MPL
# This prevents the ESDK without the MPL from considering the MPL-specific modules as "missed" coverage
[run]
omit = */aws_encryption_sdk/materials_managers/mpl/*

[report]
omit = */aws_encryption_sdk/materials_managers/mpl/*
1 change: 1 addition & 0 deletions .coveragercmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# .coveragerc file when running coverage WITH coverage for the MPL
4 changes: 2 additions & 2 deletions .github/workflows/ci_codebuild-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ jobs:
with:
role-to-assume: ${{ secrets.CI_AWS_ROLE_ARN }}
aws-region: us-west-2
role-duration-seconds: 3600
role-duration-seconds: 4200
- name: Run python-${{ matrix.python.python_version }} ${{ matrix.codebuild_file_name }}
uses: aws-actions/aws-codebuild-run-build@v1
timeout-minutes: 60
timeout-minutes: 70
with:
project-name: python-esdk
buildspec-override: codebuild/py${{ matrix.python.python_version }}/${{ matrix.codebuild_file_name }}
Expand Down
27 changes: 25 additions & 2 deletions .github/workflows/ci_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,17 +40,40 @@ jobs:
category:
- local
- accept
- mpllocal
# These require credentials.
# Enable them once we sort how to provide them.
# - integ
# - examples
# Append '-mpl' to some test environments.
# This suffix signals to tox to install the MPL in the test environment.
optional_mpl_dependency:
- ""
- -mpl
exclude:
# x86 builds are only meaningful for Windows
- os: ubuntu-latest
architecture: x86
- os: macos-13
architecture: x86
# MPL is not supported on <3.11
- python: 3.7
optional_mpl_dependency: -mpl
- python: 3.8
optional_mpl_dependency: -mpl
- python: 3.9
optional_mpl_dependency: -mpl
- python: 3.10
optional_mpl_dependency: -mpl
# mpllocal requires the MPL to be installed
- category: mpllocal
optional_mpl_dependency: ""
steps:
# Support long Dafny filenames (used in MPL and DBESDK repos)
- name: Support longpaths
run: |
git config --global core.longpaths true

- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
Expand All @@ -61,7 +84,7 @@ jobs:
pip install --upgrade -r dev_requirements/ci-requirements.txt
- name: run test
env:
TOXENV: ${{ matrix.category }}
TOXENV: ${{ matrix.category }}${{ matrix.optional_mpl_dependency }}
run: tox -- -vv
upstream-py311:
runs-on: ubuntu-latest
Expand All @@ -81,5 +104,5 @@ jobs:
pip install --upgrade -r dev_requirements/ci-requirements.txt
- name: run test
env:
TOXENV: ${{ matrix.category }}
TOXENV: ${{ matrix.category }}${{ matrix.optional_mpl_dependency }}
run: tox -- -vv
13 changes: 11 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@ docs/build
__pycache__
*.egg-info

# Coverage.py
.coverage*
# Coverage.py, NOT .coveragerc nor .coveragercmpl
.coverage
.coverage.py

# MyPy
.mypy_cache
Expand All @@ -30,6 +31,14 @@ __pycache__

# PyTest
.pytest_cache
# Ignore key materials generated by examples or tests
test_keyrings/
# Ignore results of performance test
performance_tests/results/*.csv
performance_tests/results/*.pstats
performance_tests/results/*.png
# Ignore the memory profile logs
mprofile_*

# PyCharm
.idea/
Expand Down
27 changes: 27 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,33 @@
Changelog
*********

4.0.0 -- 2024-10-29
===================

Features
--------
* Add support for constructs from the `AWS Cryptographic Material Providers Library (MPL) <https://github.com/aws/aws-cryptographic-material-providers-library>`_.
The MPL contains new constructs for encrypting and decrypting your data.
We highly recommend installing the MPL. See `Installing <https://github.com/aws/aws-encryption-sdk-python/tree/master?tab=readme-ov-file#installation>`_ for instructions.

Breaking Changes
^^^^^^^^^^^^^^^^
* The MPL introduces the Required Encryption Context Cryptographic Materials Manager
("required EC CMM") as a new construct for protecting your data.
On encrypt, the required EC CMM will use specific configured
encryption context key-value pairs to calculate the message signature,
but will not store those pairs in the ESDK message.
On decrypt, decryptors must supply these same pairs that were used when encrypting the message.
All messages that have been encrypted with versions of the ESDK <4.0.0 are forward compatible with this change.
However, messages that are constructed with the required EC CMM are not backward compatible with ESDK <4.0.0,
as no version of ESDK <4.0.0 supports reading messages encrypted with the required EC CMM.
A message that is encrypted with the required EC CMM from the MPL must be decrypted with a CMM from the MPL.

Fixes
-----------
* fix: MKPs attempt to decrypt with remaining keys if a preceding raw RSA key failed to decrypt
`#707 <https://github.com/aws/aws-encryption-sdk-python/pull/707>`_

3.3.0 -- 2024-05-20
===================

Expand Down
Loading
Loading