mirror of
https://github.com/twinksoftware/Gearslip.git
synced 2026-11-10 16:02:25 +01:00
leave the car's Bluetooth address out of logs
This commit is contained in:
1 parent
3ac815eee4
commit
e318b651bb
1 file changed
+5
-2
@@ -352,8 +352,11 @@ class GearslipRunner(
|
|||||||
|
|
||||||
private fun onServiceDiscoveryResponse(body: ByteArray) {
|
private fun onServiceDiscoveryResponse(body: ByteArray) {
|
||||||
log.i("<- ServiceDiscoveryResponse (${body.size} bytes, decrypted successfully)")
|
log.i("<- ServiceDiscoveryResponse (${body.size} bytes, decrypted successfully)")
|
||||||
// Field 5 is the car's serial number. Logs get shared, so it stays out of them.
|
// Field 5 is the car's serial number, and the Bluetooth service carries the car's
|
||||||
val described = Protobuf.describe(body).replace(Regex("(?m)^ #5 string = .*$"), " #5 string = (car serial, left out)")
|
// Bluetooth address. Either one identifies the car, and logs get shared, so both stay out.
|
||||||
|
val described = Protobuf.describe(body)
|
||||||
|
.replace(Regex("(?m)^ #5 string = .*$"), " #5 string = (car serial, left out)")
|
||||||
|
.replace(Regex("([0-9A-Fa-f]{2}:){5}[0-9A-Fa-f]{2}"), "(Bluetooth address, left out)")
|
||||||
log.i("head unit describes itself as:\n" + described)
|
log.i("head unit describes itself as:\n" + described)
|
||||||
log.verdict(
|
log.verdict(
|
||||||
"VIABLE",
|
"VIABLE",
|
||||||
|
|||||||
Reference in new issue
Block a user