Neels Hofmeyr
5ad72b91bb
hnb-test: receive Paging, add CL rx
...
Add ability to receive ConnectionLess transfers in order to read the
Paging and (so far only) print the IMSI paged for.
2016-04-19 18:19:31 +02:00
Neels Hofmeyr
bde4d3b3b7
hnb-test: request Iu Release, handle Iu Release Command
2016-04-19 18:19:30 +02:00
Neels Hofmeyr
4a0a69a88d
hnb-test: add Security Mode Command handling
2016-04-19 01:32:25 +02:00
Neels Hofmeyr
c28ed375b3
hnb-test: cosmetic: rename hnb_test_nas_tx_dt() to hnb_test_tx_dt()
...
Not all Direct Transfer messages contain a NAS PDU, see Security Mode
Complete.
2016-04-19 01:32:25 +02:00
Neels Hofmeyr
4470f93074
hnb-test: simplify crossing message layers
...
Adding the Security Mode Control command would break the current scheme of
callbacks across layers. This brought to my attention that the scheme is indeed
unnecessarily complex, so simplify it.
Instead of passing callbacks, call functions directly. Add hnb-test-layers.h to
declare those functions that cross from main to rua, to ranap and back to main
and remove the callback type definitions.
Instead of copying the NAS PDU to a newly allocated msgb, pass the data and len
directly to hnb_test_nas_rx_dtap().
Instead of repeatedly checking the gsm48_hdr length, just pass the struct
gsm48_hdr* and len around and assume the basic header length has been checked.
In some places, rename 'length' to 'len' for cosmetic consistency.
2016-04-19 01:32:25 +02:00
Neels Hofmeyr
26779f8573
hnb-test: generate SRES from hardcoded Ki
...
Previously the SRES was hardcoded, but the CN changed to generate the SRES.
So now, generate the SRES while still using the hardcoded Ki.
Fixes the Authentication Response message when testing IuCS Location Update.
2016-04-19 01:32:24 +02:00
Neels Hofmeyr
d7ad0ac238
hnb-test: parse_mm: assert MM pdisc
2016-04-06 18:58:37 +02:00
Neels Hofmeyr
998726054e
hnb-test: on auth response, make it seq nr 2
2016-04-06 18:58:37 +02:00
Neels Hofmeyr
ad00d2bee5
hnb-test: rx dtap: log message size
2016-04-06 18:58:37 +02:00
Neels Hofmeyr
8c2b4ec6d6
hnb-test: don't segfault when msgb has no l3
2016-04-06 18:58:37 +02:00
Neels Hofmeyr
7c28f6f438
hnb-test: use gsm48_hdr_pdisc() and gsm48_hdr_msg_type() instead of bitmasks
2016-04-06 18:58:36 +02:00
Neels Hofmeyr
e25faa8966
hnb-test: print sent bytes
2016-03-30 14:10:39 +02:00
Neels Hofmeyr
3588810cb7
hnb-test: answer MM Authentication Request
...
With hardcoded SRES matching the hardcoded auth tuple in openbsc's
sysmocom/iu branch for testing.
2016-03-30 14:10:39 +02:00
Neels Hofmeyr
5dbb7b2c3f
hnb-test: print LU Reject
2016-03-30 14:10:39 +02:00
Neels Hofmeyr
d4598fa453
hnb-test: factor out MM header parsing
2016-03-30 14:10:39 +02:00
Neels Hofmeyr
c04eb533e1
hnb-test: send TMSI REALLOC COMPL only when LU ACC sent a TMSI
2016-03-04 12:40:53 +01:00
Neels Hofmeyr
5f9be1ed5e
hnb-test: make hnb-gw address configurable
2016-02-29 13:33:44 +01:00
Neels Hofmeyr
ae93712977
hnb-test: add messages leading to Location Update Accept
...
But note, authentication is not there yet; the CSCN should initiate that.
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
5c1cc8cce4
hnb-test: replace some hex vals with GSM48_* constants
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
e1f709fa51
hnb-test fix id resp
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
860a12977c
hnb-test: attempt to reply to an MM Identity Request
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
b984f36f58
hnb-test: decode NAS pdu when receiving RUA from CN
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
32828708b2
hnb-test: tweak comment
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
7b81128d44
hnb-test: comment on gen_initue_lu() IMSI
2016-02-29 10:02:10 +01:00
Neels Hofmeyr
0968a58836
hnb-test: some rua rx printfs
2016-02-24 20:51:04 +01:00
Neels Hofmeyr
a0d21479a7
osmo-hnbgw, hnb-test: allow configuring VTY address
2016-02-24 20:51:04 +01:00
Neels Hofmeyr
6a62e549cd
hnb-test: fix wrong domain indicator in ranap.
...
ranap_new_msg_initial_ue() called with wrong argument order.
2016-02-18 01:30:42 +01:00
Daniel Willmann
8592716116
hnb-test: Increment UE conn_id for each new loc_upd_req
2016-01-14 15:36:49 +01:00
Daniel Willmann
11e912aa6e
Free ies struct after use in tests and hnbgw_cn/rua
2016-01-07 13:19:30 +01:00
Neels Hofmeyr
96979af054
move ranap_*.h,iu_helpers.h to include/osmocom/ranap/
...
A bit hacky: the ranap_ies_defs.h is generated together with the
ranap_encoder.c and ranap_decoder.c. See comments in src/Makefile.am and
include/osmocom/ranap/Makefile.am.
2016-01-05 15:37:23 +01:00
Harald Welte
b66c5d0e62
move tests/rua_helper.[ch] to src directory
...
The RUA Helper is not test-specific.
2016-01-03 18:04:28 +01:00
Harald Welte
056984fab1
merge (+rename) iu_helpers.c into libosmo-ranap
2016-01-03 16:31:31 +01:00
Harald Welte
87ffeb91dc
factor out some common shared test init code
2015-12-25 15:34:22 +01:00
Harald Welte
c3851220db
hnb-test: Add VTY to manually issue Iuh messages
...
We can now send Iuh messages with commands like 'hnbap hnb register',
'hnbap ue regiter imsi 12345', 'ranap reset cs', 'ranap reset ps',
and even establish connection-oriented RUA using
'channel cs lu imsi 12345'
2015-12-24 15:41:21 +01:00
Daniel Willmann
141a0baac9
hnb-test: Add an option to transmit multiple UE register/deregister msgs
2015-12-17 18:03:52 +01:00
Daniel Willmann
6637a289da
hnb-test: Handle closed connections correctly
2015-12-17 14:47:51 +01:00
Daniel Willmann
19dedbb6b1
hnb-test: Send UE de-register after receiving the UE registration accept
2015-12-17 13:09:37 +01:00
Daniel Willmann
92856e6ef2
hnb-test.c: Remove pdus.h include as it is not used
...
The messages are constructed so no need to include the binary asn1 data.
2015-12-17 13:09:37 +01:00
Daniel Willmann
3279780557
hnb-test: Add HNBAP category and reduce MAIN loglevel to INFO
2015-12-17 13:09:18 +01:00
Daniel Willmann
a7b02405be
hnb-test: Parse UE register accept
2015-12-14 10:37:26 +01:00
Daniel Willmann
4e31250367
hnb-test: Send UE register request
2015-12-14 10:36:36 +01:00
Daniel Willmann
479cb300ce
hnb-test: Send HNB register request and parse the accept
2015-12-14 10:36:36 +01:00
Daniel Willmann
4abdee0803
hnb-test: setsockopt SCTP_EVENTS is needed to get the sctp_sndrcvinfo
2015-12-14 10:36:36 +01:00
Daniel Willmann
d6a45b402c
asn1helpers: Add 28 bit conversion function and use it for Cell ID
...
The padding bits in the bit string are at the end and the byte-order is
MSB-first. This means the number needs to be shifted left so the padding
bits are the least significant.
2015-12-14 10:21:51 +01:00
Daniel Willmann
a1e202e15e
tests/hnb-test: Generate the HNBAP registration request from ASN.1
2015-12-07 17:21:07 +01:00
Daniel Willmann
4aeef6c3c4
hnb-test: Send hard-coded HNB register request for now
2015-12-03 17:02:13 +01:00
Daniel Willmann
97374c039b
tests: Add hnb-test to connect to hnbgw and tests its functions
...
Only connects currently
2015-12-03 09:37:58 +01:00