From a1dc9a65193aae623695689807efc1777b745b42 Mon Sep 17 00:00:00 2001 From: Seb3thehacker Date: Mon, 2 Nov 2026 16:52:58 -0800 Subject: [PATCH] TlsSelfTest moves to the tests, where its trust-anything peer belongs Only the unit tests ran it, but it shipped in the APK and code scanning flagged its trust manager. --- .../java/app/seb3thehacker/gearslip/TlsSelfTest.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) rename gearslip/src/{main => test}/java/app/seb3thehacker/gearslip/TlsSelfTest.kt (97%) diff --git a/gearslip/src/main/java/app/seb3thehacker/gearslip/TlsSelfTest.kt b/gearslip/src/test/java/app/seb3thehacker/gearslip/TlsSelfTest.kt similarity index 97% rename from gearslip/src/main/java/app/seb3thehacker/gearslip/TlsSelfTest.kt rename to gearslip/src/test/java/app/seb3thehacker/gearslip/TlsSelfTest.kt index 741e190..b8d1cac 100644 --- a/gearslip/src/main/java/app/seb3thehacker/gearslip/TlsSelfTest.kt +++ b/gearslip/src/test/java/app/seb3thehacker/gearslip/TlsSelfTest.kt @@ -11,7 +11,10 @@ import javax.net.ssl.SSLEngineResult import javax.net.ssl.SSLEngineResult.HandshakeStatus import javax.net.ssl.X509ExtendedTrustManager -/** Checks mutual TLS and an encrypted data round trip with an in-process head-unit peer. */ +/** + * Checks mutual TLS and an encrypted data round trip with an in-process head-unit peer. Test code + * only: the peer trusts any certificate, which is the point here and must never ship in the app. + */ object TlsSelfTest { private val log = GearslipLog.tagged("TLS")