Encrypt each packet with its own EAX cipher

TS3 derives a packet's key and nonce from its id, so resending a packet
encrypts it under the same pair again. BouncyCastle has since learned to
refuse that on a cipher that has already used the pair ("cannot reuse
nonce for EAX encryption"), which broke resends on the current version
the Android build uses. A fresh cipher per packet keeps them working.

Moves to bcprov-jdk18on 1.86, the maintained line, so every platform runs
the same BouncyCastle.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-09-25 08:42:48 +00:00
co-authored by Claude Opus 5.5
parent 3625cc24cf
commit 5a5fb6baaf
3 changed files with 17 additions and 15 deletions
+2 -2
View File
@@ -36,8 +36,8 @@
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<version>1.67</version>
<artifactId>bcprov-jdk18on</artifactId>
<version>1.86</version>
</dependency>
<dependency>