Merge "Prevent any app except LPA to create logical channel to AID of ISD-R." into oc-dr1-dev

am: f1328fee0d

Change-Id: I8646c7983330beaf90f7935d01675f33df2bf7ef
This commit is contained in:
Derek Tan
2017-07-07 23:18:54 +00:00
committed by android-build-merger
2 changed files with 4 additions and 3 deletions

View File

@@ -3765,7 +3765,7 @@ public class TelephonyManager {
try {
ITelephony telephony = getITelephony();
if (telephony != null)
return telephony.iccOpenLogicalChannel(subId, AID, p2);
return telephony.iccOpenLogicalChannel(subId, getOpPackageName(), AID, p2);
} catch (RemoteException ex) {
} catch (NullPointerException ex) {
}
@@ -6762,4 +6762,3 @@ public class TelephonyManager {
return null;
}
}

View File

@@ -623,11 +623,13 @@ interface ITelephony {
* Input parameters equivalent to TS 27.007 AT+CCHO command.
*
* @param subId The subscription to use.
* @param callingPackage the name of the package making the call.
* @param AID Application id. See ETSI 102.221 and 101.220.
* @param p2 P2 parameter (described in ISO 7816-4).
* @return an IccOpenLogicalChannelResponse object.
*/
IccOpenLogicalChannelResponse iccOpenLogicalChannel(int subId, String AID, int p2);
IccOpenLogicalChannelResponse iccOpenLogicalChannel(
int subId, String callingPackage, String AID, int p2);
/**
* Closes a previously opened logical channel to the ICC card.