Commit Graph

928 Commits

Author SHA1 Message Date
Vadim Yanitskiy a02afb26a5 pycrate_osmo.L1CTL: add missing L1CTLInfoUL() to Req messages 2022-05-13 17:23:09 +03:00
Vadim Yanitskiy e961929748 pycrate_osmo.L1CTL: fix L1CTL_H0: add missing padding
Both L1CTL_H0 and L1CTL_H1 must have equal size.
2022-05-13 17:15:04 +03:00
Vadim Yanitskiy 9acd0e0b9c pycrate_osmo.L1CTL: fix L1CTLInfoUL: remove Buf('Payload')
This Envelope represents an Uplink header, there is no payload in it.
2022-05-13 17:13:43 +03:00
Vadim Yanitskiy d1cd22d75f pycrate_osmo.L1CTL: fix wrong bl in ARFCNFlags
Fixes e3eecabc06, in which I used
wrong field length values.  ARFCNFlags should be 16 bits total.
2022-05-13 17:08:06 +03:00
p1-bmu 95aac79206 diameter: enable raw AVP value setting, whatever AVP code 2022-03-17 18:48:08 +01:00
p1-bmu acb659115e bump version in setup 2022-03-16 18:29:28 +01:00
p1-bmu 08e6ad21e9 add new GTP listing tool to setup 2022-03-16 18:16:19 +01:00
p1-bmu 347a31b6de add a tool for listing GTP messages structure and context 2022-03-16 18:15:08 +01:00
p1-bmu ae3df5b25d mobile.GTPU: export GTPUDispatcher 2022-03-16 18:14:27 +01:00
p1-bmu c51f6c31e6 mobile.GTPv2: add a dict with all interfaces supported 2022-03-16 18:14:06 +01:00
p1-bmu f3a539d4a6 mobile.GTP: align GTPIEs API to GTPv2 2022-03-16 18:13:31 +01:00
p1-bmu 0d02e5dfb2 mobile.GTP: handle GTP IE unicity with their name, and not their type 2022-03-15 17:16:32 +01:00
p1-bmu 6ca34bd75b mobile.GTP: reformat GTPIEs and GTPMsg with proper MAND and OPT attributes, aligning with GTPv2-C 2022-03-14 17:41:36 +01:00
p1-bmu bd02f24940 mobile.GTP: add ReqResp dict and simplify parsing when ignoring the msg initiator 2022-03-09 18:38:28 +01:00
p1-bmu b9a5012b95 tools.berdecode: catch exception during decoding 2022-03-07 11:51:02 +01:00
p1-bmu 736458858e test: add unit tests for GTPv1-C 2022-03-07 10:09:27 +01:00
p1-bmu f83e92af4a mobile.GTP: add all IEs for GTPv1-C and encoding / decoding routines 2022-03-07 10:08:58 +01:00
p1-bmu e93c4b7b0f mobile.GTPv2-C: use IPAddr and align some classes' name with GTPv1-C 2022-03-07 10:06:34 +01:00
p1-bmu 9960a79a3f mobile.PFCP: use IPAddr and enhance FQDN repr 2022-03-07 10:05:26 +01:00
p1-bmu 7512bb4e21 mobile: add a basic IPAddr Buf subclass in 24008_IE 2022-03-07 10:04:30 +01:00
p1-bmu 517f4c4032 core: modernize iteration loops 2022-03-07 10:03:35 +01:00
p1-bmu ef0052f08d mobile: add a TODO to MCC_MNC to reuse the external project MCC_MNC 2022-03-04 13:27:56 +01:00
p1-bmu 32154e7bc0 asn1dir: add ASN.1 specs from TCA eUICC Protection Profile Interop Format Test 2022-02-28 15:09:49 +01:00
p1-bmu ca7e9b4895 mobile: fix last GTPv1-C issues and introduce some basic tests, to be enhanced 2022-02-18 20:51:59 +01:00
p1-bmu b0cd1c45b1 mobile: fix APN decodig routine for good 2022-02-18 20:51:19 +01:00
p1-bmu 452a92c580 mobile: fix APN and DNN encoding and decoding routines 2022-02-18 20:31:06 +01:00
p1-bmu 5c5faacb3a mobile: initial support for GTPv1-C, without support for specific IE structures 2022-02-18 19:48:29 +01:00
p1-bmu 5f5f151358 cosmetic 2022-02-15 17:49:41 +01:00
p1-bmu 1ea3d66000 GTPv1: define root struct for IE 2022-02-15 17:49:31 +01:00
p1-bmu a4c3a06b63 mobile: prepare support for GTPv2 from 29.060 2022-02-14 17:57:44 +01:00
Benoit Michau 2f2cb954bc
Merge pull request #178 from axilirator/fixeria/rrctl
Add simple extNAS/RRCTL demo sending Detach Request
2022-02-04 20:38:52 +01:00
Vadim Yanitskiy 5723fc16c5 tools: add simple extNAS/RRCTL demo sending Detach Request 2022-02-05 00:06:48 +06:00
Vadim Yanitskiy c3d9fa8132 pycrate_osmo.RRCTL: fix wrong operator in RRCTLMsg.match() 2022-02-05 00:03:51 +06:00
p1-bmu 07a50e7563 Merge branch 'master' of github.com:P1sec/pycrate 2022-02-04 16:37:28 +01:00
p1-bmu a339c60d9a fix the readme part on the tool map_op_list.py 2022-02-04 16:37:24 +01:00
Benoit Michau f3f937d16e
Merge pull request #177 from axilirator/fixeria/fixes
setup.py: add missing 'pycrate_osmo' module to packages[]
2022-02-04 16:36:35 +01:00
Vadim Yanitskiy a4a5cf258a setup.py: add missing 'pycrate_osmo' module to packages[] 2022-02-04 19:43:24 +06:00
Benoit Michau 84cb0ddead
Merge pull request #175 from axilirator/fixeria/rrctl
pycrate_osmo: add RRCTL protocol definition
2022-02-01 14:07:21 +01:00
Vadim Yanitskiy b2b71e8f61 pycrate_osmo.RRCTL: add (U)SIM specific protocol extensions 2022-02-01 17:38:01 +06:00
Vadim Yanitskiy 768d6ec079 pycrate_osmo.RRCTL: reserve a range for RRCTL protocol extensions
The idea is to group protocol extensions and have one message
type (with 4 variations: Req/Ind/Cnf/Err) per group.  Similar
to the stack and heap allocation model in Linux, new entries
shall be added to the 'RRCTLMsgType' enum as follows:

  * regular messages - from the bottom downward,
  * extension groups - from the end upward.

The mask '11xxxx'B gives us 16 unique messages, one is reserved.
2022-02-01 17:37:44 +06:00
Vadim Yanitskiy 2520b19588 pycrate_osmo.RRCTL: add SecMode message for setting EEA/EIA 2022-02-01 17:37:44 +06:00
Vadim Yanitskiy d7804463f6 pycrate_osmo.RRCTL: add Paging and Param messages 2022-02-01 17:37:44 +06:00
Vadim Yanitskiy 64f10f47b1 pycrate_osmo: add initial RRCTL protocol definition
RRCTL is a simple protocol (inspired by Osmocom's L1CTL) that allows
an external NAS entity to control the RRC layer of srsUE [1][2].
The basic primitives are PLMN search, selection, and PDU transfer.

The following message types are implemented:

  * Reset - reset internal state of the external NAS interface;
  * NetworkSearch - initiates PLMN (carrier) search on pre-configured
                    EARFCN (Absolute Radio Freqency Number);
  * NetworkSelect - binds the UE to one of the previously detected
                    carriers (see `NetworkSearch`) defined by a
                    given pair of MCC and MNC;
  * ConnEstabish - establishes connection to the serving cell
                   (previously selected using `NetworkSelect`)
                   with a given cause and NAS PDU;
  * ConnRelease - releases previously established dedicated connection;
  * ConnData - encapsulates a received (Downlink) or to be transmitted
               (Uplink) NAS PDU (the former also contains LCID).

[1] https://github.com/srsran/srsRAN (original project)
[2] https://github.com/axilirator/srsLTE (extNAS fork)
2022-02-01 17:37:40 +06:00
p1-bmu 55594c6ff2 test: add an additional GTPv2-C pdu 2022-02-01 11:57:23 +01:00
Vadim Yanitskiy 12c13ed98d pycrate_osmo: add missing SEDebugMux module to __init__.py 2022-02-01 16:43:33 +06:00
Vadim Yanitskiy a3013b3ea6 pycrate_mobile: raise PycrateErr in {BufBCD,PLMN}.set_val()
Without this patch, an unexpected value (e.g. an integer) passed
to {BufBCD,PLMN}.set_val() would be silently ignored and the
actual value would remain unchanged.
2022-02-01 16:43:33 +06:00
p1-bmu 0630cc425d GTPv2c: fix cause extension transparency 2022-02-01 11:13:01 +01:00
p1-bmu a2c33338e6 tools: extend pycrate_map_op_info to also support Camel operations 2022-01-21 16:22:41 +01:00
p1-bmu b6e12c6eac media: fix filter dict in PNG 2022-01-21 12:01:25 +01:00
p1-bmu 356c5db3d8 mobile: fix Q.931 AccessTransport structure in ISUP 2022-01-21 09:00:10 +01:00