Skip to content

Conversation

@jon-signal
Copy link
Contributor

Section 5.1 of the The Noise Protocol Framework, revision 34 states in the description for DecryptWithAd that:

If an authentication failure occurs in DECRYPT() then n is not incremented and an error is signaled to the caller.

…but noise-java currently increments the nonce unconditionally. This change defers incrementing the nonce until encryption/decryption operations actually succeed.

@BigPanda97
Copy link

@rweather why don't you pull this pull-request?

github-actions bot pushed a commit to eyedeekay/i2p.i2p that referenced this pull request Apr 6, 2025
…ryption operation succeeds

Adapted from rweather/noise-java#18

Section 5.1 of the The Noise Protocol Framework, revision 34 states in the description for DecryptWithAd that:

If an authentication failure occurs in DECRYPT() then n is not incremented and an error is signaled to the caller.

But noise-java currently increments the nonce unconditionally.
This change defers incrementing the nonce until encryption/decryption operations actually succeed.
vituperative added a commit to I2PPlus/i2pplus that referenced this pull request Apr 8, 2025
…tion/decryption operation succeeds

Adapted from rweather/noise-java#18

Section 5.1 of the The Noise Protocol Framework, revision 34 states in the description for DecryptWithAd that:

If an authentication failure occurs in DECRYPT() then n is not incremented and an error is signaled to the caller.

But noise-java currently increments the nonce unconditionally.
This change defers incrementing the nonce until encryption/decryption operations actually succeed.
(manual merge of upstream commit 5b40c01)
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