Home
last modified time | relevance | path

Searched refs:IccUtils (Results 1 – 25 of 66) sorted by relevance

123

/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/uicc/euicc/asn1/
DIccUtilsTest.java25 import com.android.internal.telephony.uicc.IccUtils;
34 assertEquals(0, IccUtils.bytesToInt(new byte[] {}, 0, 0)); in testBytesToInt()
35 assertEquals(0, IccUtils.bytesToInt(new byte[] {0}, 0, 0)); in testBytesToInt()
36 assertEquals(0x1234, IccUtils.bytesToInt(new byte[] {0x12, 0x34}, 0, 2)); in testBytesToInt()
37 assertEquals(0x34, IccUtils.bytesToInt(new byte[] {0x12, 0x34}, 1, 1)); in testBytesToInt()
38 assertEquals(0xFF, IccUtils.bytesToInt(new byte[] {-2, 0, -1, -3, -4}, 1, 2)); in testBytesToInt()
39 assertEquals(0x7FFFFFFF, IccUtils.bytesToInt(new byte[] {0x7F, -1, -1, -1}, 0, 4)); in testBytesToInt()
40 assertEquals(0x80, IccUtils.bytesToInt(new byte[] {0x00, -128}, 0, 2)); in testBytesToInt()
46 IccUtils.bytesToInt(new byte[] {1, 2, 3, 4, 4}, 0, 5); in testBytesToInt_IllegalLength()
52 IccUtils.bytesToInt(new byte[] {1, 2}, 0, 3); in testBytesToInt_IndexOutOfBounds()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/
DSimUtilsTest.java20 import com.android.internal.telephony.uicc.IccUtils;
37 data = IccUtils.hexStringToBytes("981062400510444868f2"); in testBasic()
38 assertEquals("8901260450014484862", IccUtils.bcdToString(data, 0, data.length)); in testBasic()
41 assertEquals("0126045001448486", IccUtils.bcdToString(data, 1, data.length - 2)); in testBasic()
44 data = IccUtils.hexStringToBytes("98E062400510444868f2"); in testBasic()
45 assertEquals("890", IccUtils.bcdToString(data, 0, data.length)); in testBasic()
48 data = IccUtils.hexStringToBytes("98F062400510444868f2"); in testBasic()
49 assertEquals("890260450014484862", IccUtils.bcdToString(data, 0, data.length)); in testBasic()
55 assertEquals(98, IccUtils.gsmBcdByteToInt((byte) 0x89)); in testBasic()
58 assertEquals(8, IccUtils.gsmBcdByteToInt((byte) 0x8c)); in testBasic()
[all …]
DAdnRecordTest.java25 import com.android.internal.telephony.uicc.IccUtils;
44 IccUtils.hexStringToBytes("566F696365204D61696C07918150367742F3FFFFFFFFFFFF")); in testBasic()
54 IccUtils.hexStringToBytes("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF")); in testBasic()
63 adn = new AdnRecord(IccUtils.hexStringToBytes( "FF")); in testBasic()
73 IccUtils.hexStringToBytes("566F696365204D61696C07FF8150367742F3FFFFFFFFFFFF")); in testBasic()
83 IccUtils.hexStringToBytes("566F696365204D61696C07818150367742F3FFFFFFFFFFFF")); in testBasic()
93 IccUtils.hexStringToBytes("566F696365204D61696C0F918150367742F3FFFFFFFFFFFF")); in testBasic()
103 IccUtils.hexStringToBytes("566F696365204D61696C00918150367742F3FFFFFFFFFFFF")); in testBasic()
113 IccUtils.hexStringToBytes("566F696365204D61696C0291FF50367742F3FFFFFFFFFFFF")); in testBasic()
123 IccUtils.hexStringToBytes("566F696365204D61696C0291F150367742F3FFFFFFFFFFFF")); in testBasic()
[all …]
DGsmAlphabetTest.java20 import com.android.internal.telephony.uicc.IccUtils;
240 unpacked = IccUtils.hexStringToBytes("566F696365204D61696C"); in testBasic()
244 assertEquals(IccUtils.bytesToHexString(unpacked), in testBasic()
245 IccUtils.bytesToHexString( in testBasic()
348 unpacked = IccUtils.hexStringToBytes("61626320646566FF"); in testGsm8BitUpackedWithEuckr()
353 unpacked = IccUtils.hexStringToBytes("C5D7BDBAC6AEFF"); in testGsm8BitUpackedWithEuckr()
DAppSmsManagerTest.java24 import com.android.internal.telephony.uicc.IccUtils;
66 intent.putExtra("pdus", new byte[][]{IccUtils.hexStringToBytes(PDU), null, null}); in testHandleSmsReceivedIntent()
DMissedIncomingCallSmsFilterTest.java32 import com.android.internal.telephony.uicc.IccUtils;
80 byte[][] pdus = {IccUtils.hexStringToBytes(smsPduString)}; in testMissedIncomingCallwithCallerId()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/uicc/
DIccUtilsTest.java42 byte[] encodedFplmns = IccUtils.encodeFplmns(FPLMNS_SAMPLE, DATA_LENGTH); in encodeFplmns()
45 String parsed = IccUtils.bcdPlmnToString(encodedFplmns, i * IccUtils.FPLMN_BYTE_SIZE); in encodeFplmns()
58 byte[] result = IccUtils.stringToAdnStringField(alphaTag); in stringToAdnStringField_gsmBasic()
60 assertThat(IccUtils.adnStringFieldToString(result, 0, result.length)) in stringToAdnStringField_gsmBasic()
68 byte[] result = IccUtils.stringToAdnStringField(alphaTag); in stringToAdnStringField_nonGsm()
71 assertThat(IccUtils.adnStringFieldToString(result, 0, result.length)) in stringToAdnStringField_nonGsm()
79 byte[] result = IccUtils.stringToAdnStringField(alphaTag); in stringToAdnStringField_mixed()
82 assertThat(IccUtils.adnStringFieldToString(result, 0, result.length)) in stringToAdnStringField_mixed()
90 byte[] result = IccUtils.stringToAdnStringField(alphaTag); in stringToAdnStringField_gsmWithEmoji()
92 assertThat(IccUtils.adnStringFieldToString(result, 0, result.length)) in stringToAdnStringField_gsmWithEmoji()
[all …]
DUiccCarrierPrivilegeRulesTest.java89 IccIoResult iir = new IccIoResult(0x90, 0x00, IccUtils.hexStringToBytes(hexString)); in testHelper()
331 IccIoResult iir = new IccIoResult(0x90, 0x00, IccUtils.hexStringToBytes(hexString)); in testAID_OnlyARAM()
392 IccIoResult iir = new IccIoResult(0x90, 0x00, IccUtils.hexStringToBytes(hexString)); in testAID_OnlyARAD()
449 IccIoResult iir = new IccIoResult(0x90, 0x00, IccUtils.hexStringToBytes(hexString)); in testAID_BothARAMandARAD()
611 IccUtils.hexStringToBytes(binaryContent.get(currentFileId.get()))); in testAID_ARFSucceed()
636 IccUtils.hexStringToBytes( in testAID_ARFSucceed()
642 IccUtils.hexStringToBytes( in testAID_ARFSucceed()
710 IccUtils.hexStringToBytes(binaryContent.get(currentFileId.get()))); in testAID_ARFFallbackToACRF()
735 IccUtils.hexStringToBytes( in testAID_ARFFallbackToACRF()
741 IccUtils.hexStringToBytes( in testAID_ARFFallbackToACRF()
[all …]
DSIMRecordsTest.java123 byte[] encodedFplmn = IccUtils.encodeFplmns(SHORT_FPLMNS_LIST, EF_SIZE); in testSetForbiddenPlmnsPad()
138 byte[] encodedFplmn = IccUtils.encodeFplmns(LONG_FPLMNS_LIST, EF_SIZE); in testSetForbiddenPlmnsTruncate()
153 byte[] encodedFplmn = IccUtils.encodeFplmns(EMPTY_FPLMN_LIST, EF_SIZE); in testSetForbiddenPlmnsClear()
187 byte[] encodedFplmn = IccUtils.encodeFplmns(SHORT_FPLMNS_LIST, EF_SIZE); in testGetForbiddenPlmns()
255 byte[] encodedFplmn = IccUtils.encodeFplmns(EMPTY_FPLMN_LIST, EF_SIZE); in testGetForbiddenPlmnsEmptyList()
388 IccUtils.stringToBcdPlmn(plmn, data, 0); in encodeOpl()
/frameworks/base/telephony/java/com/android/internal/telephony/uicc/asn1/
DAsn1Node.java21 import com.android.internal.telephony.uicc.IccUtils;
106 byte[] dataBytes = IccUtils.signedIntToBytes(value); in addChildAsInteger()
148 return addChildAsBytes(tag, IccUtils.hexStringToBytes(hex)); in addChildAsBytesFromHex()
174 dataBytes[0] = IccUtils.countTrailingZeros(dataBytes[dataLength - 1]); in addChildAsBits()
227 byte[] tagBytes = IccUtils.unsignedIntToBytes(tag); in isConstructedTag()
235 len += IccUtils.byteNumForUnsignedInt(length); in calculateEncodedBytesNumForLength()
253 IccUtils.byteNumForUnsignedInt(mTag) in Asn1Node()
270 IccUtils.byteNumForUnsignedInt(mTag) in Asn1Node()
402 return IccUtils.bytesToInt(mDataBytes, mDataOffset, mDataLength); in asInteger()
421 return IccUtils.bytesToRawLong(mDataBytes, mDataOffset, mDataLength); in asRawLong()
[all …]
DAsn1Decoder.java19 import com.android.internal.telephony.uicc.IccUtils;
36 this(IccUtils.hexStringToBytes(hex)); in Asn1Decoder()
106 tag = IccUtils.bytesToInt(mSrc, tagStart, offset - tagStart); in nextNode()
127 dataLen = IccUtils.bytesToInt(mSrc, offset, lenLen); in nextNode()
/frameworks/base/telephony/java/android/telephony/
DSmsCbEtwsInfo.java26 import com.android.internal.telephony.uicc.IccUtils;
184 int year = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[0]); in getPrimaryNotificationTimestamp()
185 int month = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[1]); in getPrimaryNotificationTimestamp()
186 int day = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[2]); in getPrimaryNotificationTimestamp()
187 int hour = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[3]); in getPrimaryNotificationTimestamp()
188 int minute = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[4]); in getPrimaryNotificationTimestamp()
189 int second = IccUtils.gsmBcdByteToInt(mWarningSecurityInformation[5]); in getPrimaryNotificationTimestamp()
199 int timezoneOffset = IccUtils.gsmBcdByteToInt((byte) (tzByte & (~0x08))); in getPrimaryNotificationTimestamp()
DUiccAccessRule.java28 import com.android.internal.telephony.uicc.IccUtils;
123 byte[] certificateHash = IccUtils.hexStringToBytes(splitStr[0]); in decodeRulesFromCarrierConfig()
209 return IccUtils.bytesToHexString(mCertificateHash); in getCertificateHexString()
271 return matches(IccUtils.hexStringToBytes(certHash), packageName); in matches()
306 return "cert: " + IccUtils.bytesToHexString(mCertificateHash) + " pkg: " + in toString()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/uicc/euicc/
DEuiccSpecVersionTest.java25 import com.android.internal.telephony.uicc.IccUtils;
92 IccUtils.hexStringToBytes("E00582030201039000"))); in testFromOpenChannelResponse()
99 IccUtils.hexStringToBytes("E00F05820202039000"))); in testFromOpenChannelResponseError()
102 IccUtils.hexStringToBytes("E005820202039000"))); in testFromOpenChannelResponseError()
105 IccUtils.hexStringToBytes("E10482030201039000"))); in testFromOpenChannelResponseError()
DEuiccCardTest.java51 import com.android.internal.telephony.uicc.IccUtils;
122 return IccUtils.bcdToBytes("987654321012345"); in setUp()
266 IccUtils.hexStringToBytes( in testGetProfile()
513 assertEquals("BF2003010203", IccUtils.bytesToHexString(resultCaptor.result)); in testGetEuiccInfo1()
525 assertEquals("BF2203010203", IccUtils.bytesToHexString(resultCaptor.result)); in testGetEuiccInfo2()
546 assertEquals("BF3802A000", IccUtils.bytesToHexString(resultCaptor.result)); in testAuthenticateServer()
603 assertEquals("BF3802A000", IccUtils.bytesToHexString(resultCaptor.result)); in testAuthenticateService_devCap()
619 IccUtils.hexStringToBytes("4131423243332D583459355A36"), // hashCc in testPrepareDownload()
625 assertEquals("BF2102A000", IccUtils.bytesToHexString(resultCaptor.result)); in testPrepareDownload()
638 IccUtils.hexStringToBytes("4131423243332D583459355A36"), // hashCc in testPrepareDownload_Error()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/uicc/
DAnswerToReset.java147 return b == null ? null : IccUtils.byteToHex(b); in byteToStringHex()
175 loge("Unrecognized convention byte " + IccUtils.byteToHex(value)); in parseConventionByte()
195 if (VDBG) log("lastTD: " + IccUtils.byteToHex(lastTD)); in parseInterfaceBytes()
202 if (VDBG) log("lastTD & TA_MASK: " + IccUtils.byteToHex((byte) (lastTD & TA_MASK))); in parseInterfaceBytes()
211 if (VDBG) log("lastTD & TB_MASK: " + IccUtils.byteToHex((byte) (lastTD & TB_MASK))); in parseInterfaceBytes()
220 if (VDBG) log("lastTD & TC_MASK: " + IccUtils.byteToHex((byte) (lastTD & TC_MASK))); in parseInterfaceBytes()
229 if (VDBG) log("lastTD & TD_MASK: " + IccUtils.byteToHex((byte) (lastTD & TD_MASK))); in parseInterfaceBytes()
298 byte[] atrBytes = IccUtils.hexStringToBytes(atr); in parseAtrString()
486 .append(IccUtils.byteToHex(getConventionByte())).append(","); in toString()
496 sb.append(IccUtils.byteToHex(b)).append(","); in toString()
DSIMRecords.java536 + " mEfCfis=" + IccUtils.bytesToHexString(mEfCfis)); in setVoiceCallForwardingFlag()
557 + " invalid mEfCfis=" + IccUtils.bytesToHexString(mEfCfis)); in setVoiceCallForwardingFlag()
661 log("EF_MBI: " + IccUtils.bytesToHexString(data)); in handleMessage()
785 if (DBG) log("EF_MWIS : " + IccUtils.bytesToHexString(data)); in handleMessage()
806 if (DBG) log("EF_CPHS_MWI: " + IccUtils.bytesToHexString(data)); in handleMessage()
829 mIccId = IccUtils.bcdToString(data, 0, data.length); in handleMessage()
830 mFullIccId = IccUtils.bchToString(data, 0, data.length); in handleMessage()
847 log("EF_AD: " + IccUtils.bytesToHexString(data)); in handleMessage()
886 log("EF_CFF_CPHS: " + IccUtils.bytesToHexString(data)); in handleMessage()
1000 if (DBG) log("iCPHS: " + IccUtils.bytesToHexString(mCphsInfo)); in handleMessage()
[all …]
DIccIoResult.java195 this(sw1, sw2, IccUtils.hexStringToBytes(hexString)); in IccIoResult()
205 + (TelephonyUtils.IS_DEBUGGABLE ? IccUtils.bytesToHexString(payload) : "*******") in toString()
DRuimRecords.java239 if (DBG) log("EF_PL=" + IccUtils.bytesToHexString(mEFpl)); in onRecordLoaded()
267 if (DBG) log("EF_LI=" + IccUtils.bytesToHexString(mEFli)); in onRecordLoaded()
282 IccUtils.bytesToHexString(data)); in onRecordLoaded()
370 if (DBG) log("CSIM_MDN=" + IccUtils.bytesToHexString(data)); in onRecordLoaded()
373 mMdn = IccUtils.cdmaBcdToString(data, 1, mdnDigitsNum); in onRecordLoaded()
395 if (DBG) log("data=" + Rlog.pii(LOG_TAG, IccUtils.bytesToHexString(data))); in onRecordLoaded()
512 if (DBG) log("CSIM_EPRL=" + IccUtils.bytesToHexString(data)); in onGetCSimEprlDone()
691 mIccId = IccUtils.bcdToString(data, 0, data.length); in handleMessage()
692 mFullIccId = IccUtils.bchToString(data, 0, data.length); in handleMessage()
/frameworks/opt/telephony/src/java/com/android/internal/telephony/gsm/
DGsmSMSDispatcher.java37 import com.android.internal.telephony.uicc.IccUtils;
195 mCi.sendSMSExpectMore(IccUtils.bytesToHexString(smsc), in sendSms()
196 IccUtils.bytesToHexString(pdu), reply); in sendSms()
198 mCi.sendSMS(IccUtils.bytesToHexString(smsc), in sendSms()
199 IccUtils.bytesToHexString(pdu), reply); in sendSms()
202 mCi.sendImsGsmSms(IccUtils.bytesToHexString(smsc), in sendSms()
203 IccUtils.bytesToHexString(pdu), tracker.mImsRetry, in sendSms()
DUsimDataDownloadHandler.java33 import com.android.internal.telephony.uicc.IccUtils;
93 String smsc = IccUtils.bytesToHexString( in handleUsimDataDownload()
97 IccUtils.bytesToHexString(smsMessage.getPdu()), in handleUsimDataDownload()
181 String encodedEnvelope = IccUtils.bytesToHexString(envelope); in handleDataDownload()
272 IccUtils.bytesToHexString(smsAckPdu), null); in sendSmsAckForEnvelopeResponse()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/uicc/euicc/apdu/
DApduSenderTest.java37 import com.android.internal.telephony.uicc.IccUtils;
108 assertEquals("A1A1A19000", IccUtils.bytesToHexString(mSelectResponse)); in testSendEmptyCommands()
140 assertEquals("A1A1A1", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSend()
160 assertEquals("A4", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendMultiApdus()
187 assertEquals("A3", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendMultiApdusStopEarly()
207 assertEquals("A1A1A1B2B2B2B2C3C3", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendLongResponse()
235 assertEquals("C3", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendStoreDataLongDataLongResponse()
263 assertEquals("B2222B", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendStoreDataLongDataMod0()
281 assertEquals("B2222B", IccUtils.bytesToHexString(mResponseCaptor.response)); in testSendStoreDataLen0()
DLogicalChannelMocker.java30 import com.android.internal.telephony.uicc.IccUtils;
106 byte[] responseBytes = IccUtils.hexStringToBytes("00" + responseHex); in getSelectResponse()
/frameworks/opt/telephony/src/java/com/android/internal/telephony/uicc/euicc/
DEuiccCard.java41 import com.android.internal.telephony.uicc.IccUtils;
282 Tags.TAG_ICCID, IccUtils.bcdToBytes(padTrailingFs(iccid))) in getProfile()
315 byte[] iccidBytes = IccUtils.bcdToBytes(padTrailingFs(iccid)); in disableProfile()
354 byte[] iccidBytes = IccUtils.bcdToBytes(padTrailingFs(iccid)); in switchToProfile()
406 String eid = IccUtils.bytesToHexString(parseResponse(response) in getEid()
430 IccUtils.bcdToBytes(padTrailingFs(iccid))) in setNickname()
455 byte[] iccidBytes = IccUtils.bcdToBytes(padTrailingFs(iccid)); in deleteProfile()
1126 IccUtils.bcdToBytes(imei, imeiBytes); in getDeviceId()
1144 IccUtils.bcdToBytes(imei, imeiBytes); in getDeviceId()
1251 "Cannot parse response: " + IccUtils.bytesToHexString(response), e)); in sendApdu()
[all …]
/frameworks/base/telephony/java/android/telephony/gba/
DGbaAuthRequest.java25 import com.android.internal.telephony.uicc.IccUtils;
156 + IccUtils.bytesToHexString(mSecurityProtocol) in toString()

123