WIP OTA testing
Change-Id: I96d4556fb9b1978cc2a1bfdcfbab9a13284423e4
This commit is contained in:
@@ -492,6 +492,7 @@ class OtaDialectSms(OtaDialect):
|
||||
else:
|
||||
raise OtaCheckError('Unknown por_rc_cc_ds: %s' % spi['por_rc_cc_ds'])
|
||||
|
||||
print(res)
|
||||
# TODO: ExpandedRemoteResponse according to TS 102 226 5.2.2
|
||||
if res.response_status == 'por_ok' and len(res['secured_data']):
|
||||
dec = CompactRemoteResp.parse(res['secured_data'])
|
||||
|
||||
@@ -76,6 +76,10 @@ class Test_SMS_AES128(unittest.TestCase):
|
||||
|
||||
def test_open_channel(self):
|
||||
spi = self.spi_base
|
||||
self.od = OtaKeyset(algo_crypt='aes_cbc', kic_idx=1,
|
||||
algo_auth='aes_cmac', kid_idx=1,
|
||||
kic=h2b('000102030405060708090a0b0c0d0e0f'),
|
||||
kid=h2b('101112131415161718191a1b1c1d1e1f'))
|
||||
tpdu = h2b('40048111227ff6407070611535007e070003000201700000781516011212000001ccda206e8b0d46304247bf00bfdc9853eed2a826f9af8dc7c2974ce2cb9bb55cc1a8577e047cc8f5d450380ba86b25354fe69f58884f671d7ace0c911f7c74830dc1d58b62cce4934568697ba1f577eecbca26c5dbfa32b0e2f0877948a9fb46a122e4214947386f467de11c')
|
||||
#'40048111227ff6407070611535000a0500030002027b6abed3'
|
||||
submit = SMS_DELIVER.from_bytes(tpdu)
|
||||
@@ -93,7 +97,7 @@ class Test_SMS_AES128(unittest.TestCase):
|
||||
print("UDHD: %s" % udhd2)
|
||||
print("DATA: %s" % b2h(data2))
|
||||
dec_tar, dec_spi, dec_apdu = self.dialect.decode_cmd(self.od, data + data2)
|
||||
print(dec_apdu)
|
||||
print(b2h(dec_tar), b2h(dec_apdu))
|
||||
|
||||
|
||||
class Test_SMS_3DES(unittest.TestCase):
|
||||
|
||||
Reference in New Issue
Block a user