Skip to content

fix: add stateful secure session encryption - #18

Merged
kakahuote1 merged 1 commit into
kakahuote1:mainfrom
Lanen-xx:work
May 25, 2026
Merged

kakahuote1 merged 1 commit into
kakahuote1:mainfrom
Lanen-xx:work

Conversation

@Lanen-xx

Copy link
Copy Markdown
Collaborator

What changed

  • Replace the public IV-taking PKI encryption entry points with a stateful secure session API.
  • Derive AEAD IVs internally from the session key, direction role, and monotonic packet sequence.
  • Enforce receive sequence ordering to reject replayed or out-of-order packets.
  • Update PKI session tests to cover sequence assignment, replay rejection, tag rejection, and decrypt-after-failed-tag behavior.

Verification

  • powershell -ExecutionPolicy Bypass -File tools\check_format.ps1
  • cmake --build build-lanen -j 1
  • ctest --test-dir build-lanen --output-on-failure

@kakahuote1
kakahuote1 merged commit 2cc3797 into kakahuote1:main May 25, 2026
2 checks passed
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.

2 participants