Harald Welte
77847ad020
add copyright statement and AGPLv3 headers to source code files
2015-10-06 22:07:04 +02:00
Harald Welte
6286880caa
the Context ID is a 24bit number, we cannot use len = 4 bytes!
2015-09-18 01:23:55 +02:00
Harald Welte
1c2ada0e7f
ranap: receive/parse DirectTransfer
2015-09-11 20:10:17 +02:00
Harald Welte
80401adcb0
ranap: Parse InitialUE message and hex-print NAS PDU
2015-09-11 19:48:06 +02:00
Harald Welte
0f0ea8112f
RUA: hand off RANAP from all PDU types, not just UnitDataTransfer
...
Also, we now offer a ranap_tx_dt() message for connection-oriented
RANAP transfers. A far as I understand the RUA spec, on RUA layer,
all operations are Class 2, i.e. without any response/confirmation.
2015-09-11 18:58:28 +02:00
Harald Welte
cc27bebd30
ranap: prepare decoding of InitialUE message
2015-09-11 18:45:39 +02:00
Harald Welte
1d2c39d83b
various cleanups (compiler warnings, coding style)
2015-09-11 17:49:37 +02:00
Harald Welte
35cbc11757
add unit test for BCD encoding/decoding
2015-09-11 17:36:59 +02:00
Harald Welte
208b7b0778
iu_helpers: fix encoding of BCD (like IMSI) into OCTET STING
2015-09-11 17:35:52 +02:00
Harald Welte
393f2bd9fb
move BCD string encoding/decoding functions to iu_helpers.[ch]
2015-09-11 17:13:51 +02:00
Harald Welte
3af1db87ed
hnbap: Print error messages in error cases
2015-09-11 17:03:16 +02:00
Harald Welte
10dfc5a97d
respond to HNBAP UE REGISTER REQ withe correspnding ACCEPT
...
The Accept incudes the IMSI that the phone presented, but
somehow we fail to encode the Context ID as bitstring, see
../pcap/20150911-hnbap-ue_register.pcap
2015-09-11 01:36:44 +02:00
Harald Welte
256c67ad81
ue context: fix linked list insert
2015-09-11 01:22:29 +02:00
Harald Welte
6289cc6248
remove obsolete asn1c makefiles in the asn1c/ hierarchy
...
we are generating the code locally in src/{ranap,rua,hnbap}
2015-09-11 00:17:07 +02:00
Harald Welte
b534e5c085
introduce ue_context management
...
We keep one 'ue_context' structure for every UE that we see
a UE REGISTER REQUEST for.
2015-09-11 00:15:54 +02:00
Harald Welte
e2e5d4dd53
Back RUA/RANAP integration until RANAP Reset works for cs+ps
...
The hNodeB is now actively transmitting and we are getting up to the
HNBAP UE-REGISTER.req with the IMSI of the MS.
2015-09-10 23:49:45 +02:00
Harald Welte
350814a5cb
first dispatch of RUA into RANAP
...
This is becoming more and more of a hack, as asn1c + asn1tostruct.py
don't really deal well with the RANAP syntax :(
2015-09-10 22:32:15 +02:00
Harald Welte
ac9c024432
ranap: Add more manual definitions to RANAP-PDUs
...
It seems that individual IEs contain nested containers, and
asn1c is not generating code for that unless we help it by some
hand-crafted additional definitions. *sigh*
2015-09-10 21:18:16 +02:00
Harald Welte
68fcff219f
don't attempt to regenerate ranap-common, it is not auto generated!
2015-09-10 19:35:09 +02:00
Harald Welte
64b4ebe57c
rua: dispatch different message types and print context/cause
2015-09-10 19:29:59 +02:00
Harald Welte
318e4d5713
actually dispatch RUA messages to RUA handling code
2015-09-10 18:47:08 +02:00
Harald Welte
656ad301a8
enable building + linking of RUA support
2015-09-10 18:33:47 +02:00
Harald Welte
84839c04ea
asn1tostruct.py: Add support for type prefixing
...
If asn1c generates prefixed type names, the asn1tostruct.py of course
also needs to be modified to do so.
2015-09-10 18:33:14 +02:00
Harald Welte
3bc7ff0bb5
hnbap Makefile: add asn1c include directory
2015-09-10 16:43:44 +02:00
Harald Welte
71733fe9b3
add AGPLv3 license text
2015-09-10 11:02:31 +02:00
Harald Welte
b908f638f4
Add README file about current state
2015-09-10 11:01:59 +02:00
Harald Welte
0ec7f13667
Cleanups (rename 'asn1c' to 'hnbap', Makefile sanitizing)
2015-09-10 10:53:37 +02:00
Harald Welte
b90c37dbaf
build + link to RUA and RANAP libraries
2015-09-10 10:53:36 +02:00
Harald Welte
ee0918971f
add asn1c generated C source for RANAP (and Makefile to regenerate)
2015-09-10 10:53:36 +02:00
Harald Welte
019830c460
add asn1c generated RUA c+header files
2015-09-10 10:53:36 +02:00
Harald Welte
3ca78c8607
add Makefile.local to generate prefixed RUA code
2015-09-10 10:53:36 +02:00
Harald Welte
f2f3000457
msgb_free() all received messages after handling
2015-09-08 00:09:23 +02:00
Harald Welte
17878e267f
avoid parsing SCTP noficiations as user data
2015-09-08 00:09:13 +02:00
Harald Welte
7b54e32c63
hnbap: Don't enqueue a NULL msgb for transmit
2015-09-07 22:41:45 +02:00
Harald Welte
9e270b4834
hnbgw.c: Fix double-free in wait-queue transmit code
2015-09-07 22:41:26 +02:00
Harald Welte
1c1c53ca11
hnbap encode: don't pass 0 as available buffer space
2015-09-07 22:41:02 +02:00
Harald Welte
c060b7bf2c
more error logging in hnbap TX successful outcome
2015-09-07 22:40:41 +02:00
Harald Welte
cfcc1e67ad
use htonl(ppid) when sending a SCTP message
2015-09-07 22:39:56 +02:00
Harald Welte
3f71256750
Use implement HNBAP transmit using per-hnb write_queue
2015-09-07 22:25:35 +02:00
Harald Welte
2204f9d43d
hnbgw: zero-initialize the output struct before aper_decode()
...
asn1c has this strange behavior that the _output_ struct must be
zero-initialized.
2015-09-07 22:25:35 +02:00
Harald Welte
5c11c94637
hnbgw: Fix SCTP server/receiver
...
* we need to swap PPID endianness
* we need to explicitly subscrie to the event(s) for sctp_sndrcvinfo
2015-09-07 22:25:35 +02:00
Harald Welte
08a793be9f
hnbgw: Initialize linked list header of hnbgw's
2015-09-07 22:25:35 +02:00
Harald Welte
1c0f538a8b
hnbgw: Bind to INADDR_ANY, not to localhost only
2015-09-07 22:25:35 +02:00
Harald Welte
385836171b
update .gitignore
2015-08-31 09:58:12 +02:00
Harald Welte
ff4750fde8
cosmetics: asn1c now no longer explicitly states -fnative-types
2015-08-31 09:55:28 +02:00
Harald Welte
08de638790
start using the shared libasn1c, now that it has aper support
2015-08-31 09:54:45 +02:00
Harald Welte
9da9697f55
makefile: asn1tostruct.py rules for RUA and RANAP
2015-08-31 09:38:13 +02:00
Harald Welte
0bdea4da55
Makefile: chrdir to asn1c subdir and build library there
2015-08-30 23:13:06 +02:00
Harald Welte
d523a69dbe
import ans1c generated C sources for HNBAP
...
TODO: split the HNBAP specific code from the core runtime code
and use libosmo-asn1c instead. This is required as we will be
dealing with multiple ASN.1 data formats from within a single
executable.
2015-08-30 23:11:19 +02:00
Harald Welte
11e0306a3a
add .gitignore for src directory
2015-08-30 23:10:13 +02:00