From efadd5383b5a98dcc249d3b8700142d3d748989f Mon Sep 17 00:00:00 2001 From: Etan Cohen Date: Wed, 21 Jun 2017 11:22:22 -0700 Subject: [AWARE] Mask passphrase/pmk information Bug: 62866763 Test: validated that logs don't show pmk/passphrase anymore Change-Id: I8ce5b2e6192af05f8748bee51e13312b65185a1d --- .../server/wifi/aware/WifiAwareStateManager.java | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'service') diff --git a/service/java/com/android/server/wifi/aware/WifiAwareStateManager.java b/service/java/com/android/server/wifi/aware/WifiAwareStateManager.java index 988485634..fc0013529 100644 --- a/service/java/com/android/server/wifi/aware/WifiAwareStateManager.java +++ b/service/java/com/android/server/wifi/aware/WifiAwareStateManager.java @@ -2329,13 +2329,14 @@ public class WifiAwareStateManager implements WifiAwareShellCommand.DelegatedShe int channel, byte[] peer, String interfaceName, byte[] pmk, String passphrase, boolean isOutOfBand) { if (VDBG) { - Log.v(TAG, - "initiateDataPathSetupLocal(): transactionId=" + transactionId - + ", networkSpecifier=" + networkSpecifier + ", peerId=" + peerId - + ", channelRequestType=" + channelRequestType + ", channel=" + channel - + ", peer=" + String.valueOf(HexEncoding.encode(peer)) - + ", interfaceName=" + interfaceName + ", pmk=" + pmk - + ", passphrase=" + passphrase + ", isOutOfBand=" + isOutOfBand); + Log.v(TAG, "initiateDataPathSetupLocal(): transactionId=" + transactionId + + ", networkSpecifier=" + networkSpecifier + ", peerId=" + peerId + + ", channelRequestType=" + channelRequestType + ", channel=" + channel + + ", peer=" + + String.valueOf(HexEncoding.encode(peer)) + ", interfaceName=" + interfaceName + + ", pmk=" + ((pmk == null) ? "" : "*") + ", passphrase=" + ( + (passphrase == null) ? "" : "*") + ", isOutOfBand=" + + isOutOfBand); } boolean success = mWifiAwareNativeApi.initiateDataPath(transactionId, peerId, @@ -2354,10 +2355,10 @@ public class WifiAwareStateManager implements WifiAwareShellCommand.DelegatedShe Log.v(TAG, "respondToDataPathRequestLocal(): transactionId=" + transactionId + ", accept=" + accept + ", ndpId=" + ndpId + ", interfaceName=" + interfaceName - + ", pmk=" + pmk + ", passphrase=" + passphrase + ", isOutOfBand=" + + ", pmk=" + ((pmk == null) ? "" : "*") + ", passphrase=" + + ((passphrase == null) ? "" : "*") + ", isOutOfBand=" + isOutOfBand); } - boolean success = mWifiAwareNativeApi.respondToDataPathRequest(transactionId, accept, ndpId, interfaceName, pmk, passphrase, isOutOfBand, mCapabilities); if (!success) { -- cgit v1.2.3