[srslte-users] RRC msg decoding

Merlin Chlosta merlin.chlosta+srslte-users at rub.de
Fri Feb 21 15:30:17 UTC 2020


Hi all,

I need some pointers how the new ASN1 decoding works. In my lab setup, 
srsUE receives a somewhat malformed message, and doesn't seem to notice.

> 15:23:47.983714 [RRC ] [D] SRB1 - Rx securityModeCommand (129 B)
>              0000: 34 da 35 8d ab 88 ac 3d b7 f7 af 86 1d 2f 0f 05 
>              0010: d6 0a 5e df 29 04 42 68 72 06 6b 1b 86 53 9b 21
> 15:23:47.983730 [RRC ] [D] Content:
> [{"DL-DCCH-Message": {
>       "message": {
>         "c1": {
>           "securityModeCommand": {
>             "rrc-TransactionIdentifier": 2,
>             "criticalExtensions": {
>               "c1": {
>               }}}}}}}]
> 15:23:47.983739 [RRC ] [E] Invalid field access for choice type "c1" ("securityModeCommand-r8"!="spare1")
So the fields for ciphering and integrity algorithms are missing here. 
The message handler doesn't seem to check for that case and just tries 
to access the values:

> case dl_dcch_msg_type_c::c1_c_::types::security_mode_cmd:
>       transaction_id = c1->security_mode_cmd().rrc_transaction_id;
> 
>       cipher_algo = (CIPHERING_ALGORITHM_ID_ENUM)c1->security_mode_cmd()
>                         .crit_exts.c1()
>                         .security_mode_cmd_r8()
>                         .security_cfg_smc
>                         .security_algorithm_cfg
>                         .ciphering_algorithm.value;

The only check seems to occur during printing (hence the "invalid field 
access") warning.

What am I missing here? Any help is appreciated. Thanks!

Viele Grüße
Merlin



More information about the srsran-users mailing list