osmo-pcu/src
Neels Hofmeyr 59fc0bda6e paging: pass struct osmo_mobile_identity, not encoded IE bytes
In get_paging_mi(), before this, an encoded buffer of Mobile Identity bytes is
returned. Code paths following this repeatedly decode the Mobile Identity
bytes, e.g. for logging. Also, in get_paging_mi(), since the TMSI is read in
from a different encoding than a typical Mobile Identity IE, the TMSI was
manually encoded into a typical Mobile Identity IE. This is essentially a code
dup of osmo_mobile_identity_encode(). Stop this madness.

Instead, in get_paging_mi(), return a decoded struct osmo_mobile_identity. Code
paths after this use the struct osmo_mobile_identity directly without repeated
decoding.

At the point of finally needing an encoded Mobile Identity IE (in
Encoding::write_paging_request()), do a proper osmo_mobile_identity_encode().

Since this may return errors, add an rc check for the caller of
write_paging_request(), gprs_rlcmac_paging_request().

A side effect is stricter validation of the Mobile Identity passing through the
Paging code path. Before, invalid MI might have passed through unnoticed.

Change-Id: Iad845acb0096b75dc453105c9c16b2252879b4ca
2020-08-24 01:12:16 +00:00
..
osmo-bts-litecell15 direct-phy: fix handle_ph_ra_ind(): handle PH-RA.ind on PRACH SAPI 2020-08-12 18:20:33 +00:00
osmo-bts-oc2g direct-phy: fix handle_ph_ra_ind(): handle PH-RA.ind on PRACH SAPI 2020-08-12 18:20:33 +00:00
osmo-bts-sysmo direct-phy: fix handle_ph_ra_ind(): handle PH-RA.ind on PRACH SAPI 2020-08-12 18:20:33 +00:00
.gitignore Adding .gitignore to source directory 2012-06-27 17:45:15 +02:00
Makefile.am Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
bts.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
bts.h paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
coding_scheme.c Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
coding_scheme.h Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
csn1.c csn1: fix csnStreamEncoder(): always check the choice index 2020-05-23 18:00:53 +07:00
csn1.h csn1: fix: never use enumerated types in codec structures 2020-05-23 19:26:58 +07:00
cxx_linuxlist.h llist: Add missing const qualifier in llist cast method 2015-08-24 12:23:50 +02:00
decoding.cpp decoding.cpp: Improve logging in malformed UL data parsing 2020-06-30 21:33:49 +02:00
decoding.h Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
egprs_rlc_compression.cpp decompress_crbb: add length argument for search_runlen 2019-06-24 13:51:06 +00:00
egprs_rlc_compression.h egprs_rlc_compression: fix white spaces 2019-06-17 02:04:09 +02:00
encoding.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
encoding.h paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
gprs_bssgp_pcu.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
gprs_bssgp_pcu.h Use clock_gettime(CLOCK_MONOTONIC) and timespec everywhere 2020-03-16 10:31:56 +00:00
gprs_codel.c Use clock_gettime(CLOCK_MONOTONIC) and timespec everywhere 2020-03-16 10:31:56 +00:00
gprs_codel.h Use clock_gettime(CLOCK_MONOTONIC) and timespec everywhere 2020-03-16 10:31:56 +00:00
gprs_debug.cpp gprs_debug: Use only LOGL_NOTICE as default loglevel 2020-05-13 16:41:55 +00:00
gprs_debug.h TBF: add dedicated log categories 2018-01-19 18:49:16 +01:00
gprs_ms.cpp Introduce log macro helper LOGPMS 2020-08-18 20:26:25 +02:00
gprs_ms.h Introduce log macro helper LOGPMS 2020-08-18 20:26:25 +02:00
gprs_ms_storage.cpp bts: Drop specific functions to add values to stats 2020-05-14 11:19:05 +00:00
gprs_ms_storage.h MS store: move test helper to unit test 2019-03-19 15:05:51 +00:00
gprs_rlcmac.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
gprs_rlcmac.h paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
gprs_rlcmac_meas.cpp Introduce log macro helper LOGPMS 2020-08-18 20:26:25 +02:00
gprs_rlcmac_sched.cpp bts: Drop specific functions to add values to counters 2020-05-14 11:19:05 +00:00
gprs_rlcmac_ts_alloc.cpp bts: Drop specific functions to increase counters 2020-05-14 11:19:05 +00:00
gsm_rlcmac.c RLC/MAC: implement decoding of EGPRS Packet Channel Request 2020-05-23 19:38:35 +07:00
gsm_rlcmac.h RLC/MAC: implement decoding of EGPRS Packet Channel Request 2020-05-23 19:38:35 +07:00
gsm_timer.cpp gsm_timer: fix comparison of constant LONG_MAX with an integer 2020-01-29 06:14:54 +07:00
gsm_timer.h pcu_l1_if: add frame number to log output 2018-04-10 13:35:24 +02:00
llc.cpp bts: Drop specific functions to increase counters 2020-05-14 11:19:05 +00:00
llc.h Use clock_gettime(CLOCK_MONOTONIC) and timespec everywhere 2020-03-16 10:31:56 +00:00
mslot_class.c mslot_class: two more: use uint32_t to shift 1 << 31 2018-03-28 14:44:47 +02:00
mslot_class.h Simplify TS alloc: move slot check into functions 2018-02-21 12:08:40 +00:00
osmobts_sock.cpp Use OSMO_FD_* instead of deprecated BSC_FD_* 2020-05-09 19:18:06 +02:00
pcu_l1_if.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
pcu_l1_if.h l1if: fix: s/pcu_rx_rach_ind_pdtch/pcu_rx_rach_ind_ptcch/g 2020-05-22 21:09:22 +07:00
pcu_main.cpp Support setting rt-prio and cpu-affinity mask through VTY 2020-08-20 08:44:54 +00:00
pcu_utils.h Use clock_gettime(CLOCK_MONOTONIC) and timespec everywhere 2020-03-16 10:31:56 +00:00
pcu_vty.c bts: add send_gsmtap_rach(), also send PTCCH/U over GSMTAP 2020-06-11 01:29:12 +07:00
pcu_vty.h Remove undefined param passed to {logging,osmo_stats}_vty_add_cmds 2019-08-05 14:30:47 +02:00
pcu_vty_functions.cpp Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
pcu_vty_functions.h VTY: fix command 'show tbf all': properly filter TBFs 2019-10-09 22:00:54 +07:00
pdch.cpp paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
pdch.h paging: pass struct osmo_mobile_identity, not encoded IE bytes 2020-08-24 01:12:16 +00:00
poll_controller.cpp Move out tbf subclasses from tbf.h to their own headers 2019-09-25 17:50:06 +02:00
poll_controller.h Update header includes 2018-02-19 08:43:46 +00:00
rlc.cpp Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
rlc.h Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
sba.cpp bts: Drop specific functions to increase counters 2020-05-14 11:19:05 +00:00
sba.h Update header includes 2018-02-19 08:43:46 +00:00
tbf.cpp tbf: Drop unneeded method set_tlli_from_ul 2020-06-26 14:35:01 +02:00
tbf.h tbf: Drop unneeded method set_tlli_from_ul 2020-06-26 14:35:01 +02:00
tbf.txt Doc: Update on README and tbf.txt 2012-12-18 10:04:03 +01:00
tbf_dl.cpp tbf_dl: uint8_t is enough to store a TA value 2020-07-07 17:18:14 +02:00
tbf_dl.h Get rid of class GprsCodingScheme 2020-05-20 11:07:07 +00:00
tbf_ul.cpp tbf: Drop unneeded method set_tlli_from_ul 2020-06-26 14:35:01 +02:00
tbf_ul.h tbf_ul: Fix UL ACK not sent to MS if intermediate UL block is lost 2020-05-19 09:30:23 +00:00
wireshark_compat.h Move gsm_rlcmac.cpp -> .c 2020-03-30 10:08:02 +00:00