Skip to content

Adds full test vector runner for all success cases#87

Merged
johnnyt merged 1 commit intomainfrom
76-test-vector-runner
Feb 1, 2026
Merged

Adds full test vector runner for all success cases#87
johnnyt merged 1 commit intomainfrom
76-test-vector-runner

Conversation

@johnnyt
Copy link
Member

@johnnyt johnnyt commented Feb 1, 2026

Implements comprehensive test vector validation executing 2,861 success test vectors through the complete Client.decrypt_with_keyring flow. Validates all 11 ESDK algorithm suites including both committed suites (0x0478, 0x0578).

Test Coverage:

  • 661 Raw AES tests (128/192/256-bit keys)
  • 1,100 Raw RSA tests (PKCS1, OAEP-SHA1/256/384/512)
  • 1,100 Multi-keyring tests (composition scenarios)
  • Algorithm suite coverage report showing distribution

Key Implementation Details:

  • EDK-based key name extraction for accurate keyring config
  • Header auth uses full EC with required key filtering
  • Test vectors run by default when available (+0.8% coverage)
  • CI integration with test vector caching
  • Removed deprecation warnings for cleaner output

Spec Compliance Fixes:

  • Header body serialization includes version/type bytes in AAD
  • Required encryption context properly filtered in header auth
  • Fixed Dialyzer typespec for compute_header_auth_tag/4

Closes #76

@johnnyt johnnyt force-pushed the 76-test-vector-runner branch from 6427080 to 72fda68 Compare February 1, 2026 20:10
Implements comprehensive test vector validation executing 2,861
success test vectors through the complete Client.decrypt_with_keyring
flow. Validates all 11 ESDK algorithm suites including both committed
suites (0x0478, 0x0578).

Test Coverage:
- 661 Raw AES tests (128/192/256-bit keys)
- 1,100 Raw RSA tests (PKCS1, OAEP-SHA1/256/384/512)
- 1,100 Multi-keyring tests (composition scenarios)
- Algorithm suite coverage report showing distribution

Key Implementation Details:
- EDK-based key name extraction for accurate keyring config
- Header auth uses full EC with required key filtering
- Test vectors run by default when available (+0.8% coverage)
- CI integration with test vector caching
- Removed deprecation warnings for cleaner output

Spec Compliance Fixes:
- Header body serialization includes version/type bytes in AAD
- Required encryption context properly filtered in header auth
- Fixed Dialyzer typespec for compute_header_auth_tag/4

Closes #76
@johnnyt johnnyt force-pushed the 76-test-vector-runner branch from 72fda68 to c80274a Compare February 1, 2026 20:12
@codecov
Copy link

codecov bot commented Feb 1, 2026

Codecov Report

❌ Patch coverage is 77.14286% with 16 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
lib/aws_encryption_sdk/crypto/header_auth.ex 40.00% 12 Missing ⚠️
lib/aws_encryption_sdk/stream/decryptor.ex 77.77% 2 Missing ⚠️
lib/aws_encryption_sdk/stream/encryptor.ex 81.81% 2 Missing ⚠️

❌ Your patch status has failed because the patch coverage (77.14%) is below the target coverage (85.00%). You can increase the patch coverage or adjust the target coverage.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #87      +/-   ##
==========================================
+ Coverage   92.61%   92.66%   +0.04%     
==========================================
  Files          40       40              
  Lines        1435     1472      +37     
==========================================
+ Hits         1329     1364      +35     
- Misses        106      108       +2     
Files with missing lines Coverage Δ
lib/aws_encryption_sdk/algorithm_suite.ex 100.00% <ø> (ø)
..._encryption_sdk/cmm/required_encryption_context.ex 89.36% <100.00%> (+1.55%) ⬆️
lib/aws_encryption_sdk/crypto/commitment.ex 83.33% <100.00%> (ø)
lib/aws_encryption_sdk/decrypt.ex 96.66% <100.00%> (+18.09%) ⬆️
lib/aws_encryption_sdk/encrypt.ex 96.87% <100.00%> (+0.20%) ⬆️
lib/aws_encryption_sdk/format/header.ex 89.39% <100.00%> (ø)
lib/aws_encryption_sdk/stream/decryptor.ex 87.87% <77.77%> (-0.67%) ⬇️
lib/aws_encryption_sdk/stream/encryptor.ex 92.30% <81.81%> (-0.94%) ⬇️
lib/aws_encryption_sdk/crypto/header_auth.ex 69.23% <40.00%> (-30.77%) ⬇️

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@johnnyt johnnyt merged commit 25f1173 into main Feb 1, 2026
8 of 10 checks passed
@johnnyt johnnyt deleted the 76-test-vector-runner branch February 1, 2026 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement Full Test Vector Runner for Success Cases

1 participant