9
0
Fork 0
Commit Graph

94 Commits

Author SHA1 Message Date
Harald Welte 629e986ea4 libgtp: introduce cb_recovery() callback
The cb_recovery() callback enables the user application to detect
a change in the restart counter and thus start the appropriate
recovery procedures.
2010-12-24 20:58:09 +01:00
Yann BONNAMY 944dce3e66 Add support for GTP IE's from 3GPP R7
This adds support for the followng new GTP Information Elements:
	RAT_TYPE, USER_LOC, MS_TZ, IMEI_SV

Furthermore, it allows to specify those fields as sgsnemu command line
arguments.
2010-10-29 17:07:44 +02:00
Emmanuel Bretelle 111e054543 Fix warning on unused fscanf return code
Relevant output of make:

gtp.c: In function ‘log_restart’:
gtp.c:697: warning: ignoring return value of ‘fscanf’, declared with
attribute warn_unused_result

Signed-off-by: Emmanuel Bretelle <chantra@debuntu.org>
2010-10-20 11:04:51 +02:00
Harald Welte dc3744fda0 Extend 'struct pdp_t' with a void *priv pointer for application use 2010-06-03 05:52:10 +02:00
Harald Welte a1bd7367d4 [libgtp] Fix GTPIE parsing segfault on 64bit architectures
Pointers are not always 4 bytes in size...
2010-05-16 00:35:39 +02:00
Harald Welte 7b3347b083 [libgtp] add comments with references to the GTP specification sections 2010-05-15 12:18:46 +02:00
Harald Welte cc9f083be0 sgsnemu: delete pdp context - teardown must be before NSAPI
in front of Cisco and Alcatel GGSN's, we meet the following error :

5 packets transmitted
Disconnecting PDP context #0
openggsn[24940]: gtp.c: 2417: Unexpected cause value received: 193. Packet from 172.29.5.130:2123, length: 14, content: 32 15 00 06 00 00 00 01 04 02 00 00 01 c1

it is because in the sgsnemu requests packet, the teardown field is after the NSAPI field :

No. Time Source Destination Protocol Info
24 10.940094 172.21.5.1 172.29.5.130 GTP Delete PDP context request

Frame 24 (58 bytes on wire, 58 bytes captured)
Ethernet II, Src: HewlettP_55:23:8d (00:11:0a:55:23:8d), Dst: Alcatel-_f6:8e:32 (00:d0:95:f6:8e:32)
Internet Protocol, Src: 172.21.5.1 (172.21.5.1), Dst: 172.29.5.130 (172.29.5.130)
User Datagram Protocol, Src Port: gtp-control (2123), Dst Port: gtp-control (2123)
GPRS Tunneling Protocol
Flags: 0x32
Message Type: Delete PDP context request (0x14)
Length: 8
TEID: 0x00000739
Sequence number: 0xbc02
N-PDU Number: 0x00
Next extension header type: No more extension headers (0x00)
[--- end of GTP header, beginning of extension headers ---]
NSAPI: 0
Teardown Indicator: True
[Response In: 25]

Taken from http://sourceforge.net/tracker/index.php?func=detail&aid=2865662&group_id=68956&atid=522957
2010-05-04 11:16:09 +02:00
Harald Welte f54a1f4d43 Fix various compiler warnings throughout the code
Mostly signed/unsigned and typecasting issues

Taken from http://sourceforge.net/tracker/index.php?func=detail&aid=1811517&group_id=68956&atid=522957
2010-05-04 11:08:38 +02:00
Harald Welte e67556e96f [SECURITY] Fix GTPIE parsing DoS
This is taken from http://sourceforge.net/tracker/index.php?func=detail&aid=1811511&group_id=68956&atid=522957 and http://www.mail-archive.com/debian-bugs-dist@lists.debian.org/msg402969.html and addresses a DoS:

The problem lies in the parsing of information elements in GTP messages, which
is implemented in the gtpie_decaps function of gtp/gtpie.c file.

The implementation has a bug that does not check if there are too many
information elements in the message thus causing the software to loop
infinitely in the while-loop.

In addition, handling routine for the error situation had to be implemented
outside the while-loop.
2010-05-04 10:59:23 +02:00
Harald Welte c5ef88ce71 remove autotools-generated files
All those will be re-generated by "autoreconf -i" anyway, so
there's no point in keeping them in the repository.

Also, the 'bootstrap' script is no longer working with recent
autotools versions anyway.
2010-05-04 10:48:23 +02:00
jjako acba8e6c62 Added new version of autotools 2005-03-14 21:53:10 +00:00
jjako e31b2401ab 0.84 release 2004-12-30 23:07:42 +00:00
jjako 0fe0df0079 qos length bugfix and apple support plus header cleanup 2004-09-17 11:30:40 +00:00
jjako 77edc82781 Improved configure script under Solaris 2004-09-10 17:19:31 +00:00
jjako 9b4971d4a6 Charging characteristics made optional 2004-05-27 20:30:19 +00:00
jjako 1f1586458f Added IP address alias capability for FreeBSD 2004-02-05 20:39:57 +00:00
jjako 1ea6634851 Added FreeBSD route capability 2004-01-28 09:27:34 +00:00
jjako d48c5ff86b Fixed long constant warning on FreeBSD 2004-01-26 22:25:40 +00:00
jjako 06e9f12588 FreeBSD porting and IMSI bugfix 2004-01-19 18:37:58 +00:00
jjako 98200dfdf9 Fix NSAPI bug in create pdp context 2004-01-09 15:18:42 +00:00
jjako be61ef25a8 Removed NSAPI from version 0 create pdp context request 2004-01-09 12:22:29 +00:00
jjako bae2cd4c6a Removed stdint.h include 2004-01-09 12:04:39 +00:00
jjako 00816a9223 Removed ansi flag 2004-01-09 12:00:02 +00:00
jjako b7b93fc78f Rename u_int to uint 2004-01-09 11:56:48 +00:00
jjako 193e8b1b01 Added --net, --nsapi, --gtpversion options 2003-11-10 12:31:41 +00:00
jjako 0b076a331e Fixed sgsnemu freepdp on failed create context. 2003-10-25 15:59:31 +00:00
jjako ccc564f878 Fixed deallocation of pdp context on failed create context. 2003-10-25 15:40:48 +00:00
jjako 581c9f0e29 sgsnemu timelimit bug fix. Readme update 2003-10-22 11:28:20 +00:00
jjako 2c3813354e GTP1 functionality 2003-10-21 19:09:53 +00:00
jjako 08d331db63 First attempt at a GTP1 implementation 2003-10-13 20:33:30 +00:00
jjako 0a120b211f Mode checking i gtp_new() 2003-07-10 18:35:50 +00:00
jjako 02b93f52fd Installation of include files 2003-07-08 11:31:34 +00:00
jjako a9639f3e00 doc in makefile.am 2003-07-07 15:30:11 +00:00
jjako 1db1c81302 Improved GTP error handling 2003-07-06 20:53:57 +00:00
jjako a7cd249501 added ippool.h and ippool.c 2003-04-11 09:40:12 +00:00
jjako afb2a970de Improved sgsnemu ping 2003-01-29 21:04:13 +00:00
jjako 286bc984ed Autotools makefile update 2003-01-28 23:17:50 +00:00
jjako 3c13e30b57 Include config.h 2003-01-28 22:17:29 +00:00
jjako b24a6397bd Removed gtp/.deps 2003-01-28 21:20:35 +00:00
jjako 2e840a3cb9 Paranoid buffer overflow checking improvements. 2003-01-28 16:05:18 +00:00
jjako 546787ea59 Removed excess autotools files 2003-01-14 14:56:45 +00:00
jjako b9015be2ba Removing gtpie.h warnings from dobble defines 2003-01-14 14:45:51 +00:00
jjako b88f61601d Setting ipnext and tidnext to NULL in settid and setip
CVS :cit ----------------------------------------------------------------------
2003-01-05 18:09:07 +00:00
jjako 52c2414f6c Initial revision 2002-12-16 13:33:51 +00:00