Commit Graph

890 Commits

Author SHA1 Message Date
Harald Welte a102b63c28 gsmtap: add minimal support for encapsulating UMTS RRC in GSMTAP 2012-09-02 14:07:57 +02:00
Harald Welte 7c8e2cc7ac libosmogsm: Back-port SMS related fixes from openbsc
This was fixed in 9c3dc90d16a40789081c84e46620f4d66689fec1 of
openbsc.git, after the sms code had been migrated here:
    introduce HAVE_TM_GMTOFF_IN_TM

    Not all architectures have the tm.tm_gmtoff member.  This fixes cygwin builds.
2012-08-29 16:47:30 +02:00
Eric Butler b5372ab110 Use package version since git info won't be available. 2012-08-26 20:11:24 +02:00
Eric Butler 8dbdc4f3d4 Fix debian package building.
* Removed log file
* Add 'git' add 'libdpkg-perl' to build dependencies
* Disable tests (one of them is failing)
2012-08-26 20:11:24 +02:00
Holger Hans Peter Freyther 8c589d2f51 misc: Fix make distcheck of libosmocore by adding the result to the dist
Add the new result file to the EXTRA_DIST.
2012-08-25 22:03:42 +02:00
Harald Welte 30a8ec466c GSM 04.08: Add 'enum gsm48_bcap_speech_ver' 2012-08-24 23:00:05 +02:00
Harald Welte c8a0b93939 GSM 04.08: Add support for parsing CSD related bearer capabilities
Also adds a test case for both encoder and decoder of this IE
2012-08-24 21:37:59 +02:00
Harald Welte 7ccd3181c5 gsm48_ie: annotate functions with chapter numbers from 04.08 spec 2012-08-24 17:06:08 +02:00
Harald Welte eed26116c9 GSM 08.58: Add channel modes for transparent data services 2012-08-24 15:36:12 +02:00
Harald Welte fab0ae9b43 import vty_cmd_string_from_valstr() from osmo-bts
This function is able to generate a VTY help string based on an
array of 'struct value_string'.
2012-08-20 18:43:09 +02:00
Holger Hans Peter Freyther 08b286277b utils: Change semantic of OSMO_MAX/OSMO_MIN to match semantic of a function
Add parentheses around the OSMO_MAX and OSMO_MIN macro to match
the behaviour of calling a function. The current version does not
evaluate to what is expected. (OSMO_MAX(3, 2) + 13)  currently
results in 3 and not 16.
2012-08-15 17:08:21 +02:00
Harald Welte 335aedabf2 increaes libosmocgsm LIBVERSIN due to gsm_decode_lai() change 2012-08-03 10:51:10 +02:00
Harald Welte 22be129e1e serial: don't set O_NDELAY, as it is more or less O_NONBLOCK
Applications like osmocon will set O_NONBLOCK themselves or have it done
indirectly by registering it with libosmocore/select.c code.
2012-08-03 10:48:22 +02:00
Holger Hans Peter Freyther d296f4244f gb: Make suspend_ref a plain uint8_t instead of a uint8_t*
The OpenSUSE build is not happy about the uint8_t to uint8_t*
assignment. As the suspend_ref is a mandatory field we can make
it a plain uint8_t. Increase the LIBVERSION as the ABI has changed.
2012-08-03 10:08:02 +02:00
Holger Hans Peter Freyther 5a19bf7ccb libgb: Link to the libraries used by libgb
The Mandriva linker appears to be more strict in enforcing the
as-needed rules. Link to the libraries that are used by libgb.
2012-08-02 21:51:15 +02:00
Holger Hans Peter Freyther ea8f238f04 vty: Print the string using "%s", string to avoid security issues
The Mandriva GCC is more strict about handling format strings, the
copyright string might contain escape sequences and then any memory
could be read.
2012-08-02 21:26:02 +02:00
Harald Welte b53717f418 Add missing includes to timer_test.c and osmo-auc-gen.c
This fixes the build with -Werror-implicit-function-declaration.

taken from malformatted patch of Chí-Thanh Christopher Nguyễn <chithanh@gentoo.org>
2012-08-02 08:42:59 +02:00
Holger Hans Peter Freyther 317aee5878 vty: Merge from a generic section in case no specific one exists 2012-07-25 17:35:52 +02:00
Holger Hans Peter Freyther e89ad6d1dd vty: Use UTF-8 for the encoding and the ability to hide nodes
There are certain nodes one might not want to document and the
additional information can decide to hide the node.
2012-07-25 17:35:52 +02:00
Holger Hans Peter Freyther c9b3e06d99 vty: Document the .TEXT of the description 2012-07-25 13:03:43 +02:00
Holger Hans Peter Freyther 8297c819e9 vty: Add xsd and a command that can generate the documentation.
When building the doxygen documentation do not remove the other
VTY documentation files in the doc/vty folder. Create a command
that can be installed to dump all nodes and commands as XML on
the given VTY. Create a schema for the XML file and a XSL-T script
that can merge the generated file with additional information.
2012-07-25 11:58:58 +02:00
Andreas Eversberg aa5d0e8894 Fix encoding of BSSGP_IE_NUM_OCT_AFF in bssgp_tx_llc_discarded()
This is a 24bit integer value, and thus we need to encode the three
least significant octets of the network-byte-order 32bit value, not the
three most significant octets.
2012-07-21 13:33:39 +02:00
Harald Welte 007a71e332 authentication: More documentation 2012-07-18 19:47:56 +02:00
Harald Welte a9e4a1402b backtrace: update copyright notice
Holger wrote that function and I made the logging version of it.  The
header was copied during the separation of backtrace.c from gsm_utils.c
in the past, and of course gsm_utils.c had more people involved...
2012-07-14 12:31:55 +02:00
Harald Welte 45ecd04e54 backtrace: Add a variant that uses the libosmocore logging framework
I recently discovered that we can only print backtraces to stdout, which
is of course useless in a daemon environment.  We'd rather want to use
the libosmocore logging framework instead.
2012-07-14 12:30:53 +02:00
Harald Welte 2fe684755a TLV: add new "vTvLV" type for GAN
This new TLV type is specific to TS 44.318.  Contrary to the TvLV type
of TS 08.16/08.18, it has an inverted meaning of the extension (0x80)
bit:
	* if the extension bit is not set, 1-byte length
	* if the extension bit is set, 2-byte length

Futhermore, it has support for variable-length tags, where the tag part
can be optionally two bytes in length.  As this esoteric option hasn't
been seen in the wild yet, we only add encoding support but skip
decoding for now.
2012-07-14 01:50:33 +02:00
Harald Welte a9250b9ebc gsm48_decode_lai(): return real integers for mcc/mnc, not hex!
This is to make it orthogonal with gsm48_encode_lai()
2012-07-13 22:57:31 +02:00
Harald Welte e866473f2a add gsm48_decode_lai() to map file 2012-07-13 21:48:35 +02:00
Harald Welte 774a9de8b3 import gsm48_decode_lai() function from osmocom-bb/mobile sysinfo.c 2012-07-13 21:35:13 +02:00
Harald Welte e30b6ac5d1 timer: Add function osmo_timer_remaining() to determine remainign time 2012-07-13 12:22:20 +02:00
Holger Hans Peter Freyther 3c16de2954 freebsd: Make libgb compile on FreeBSD
Include header files for recfrom/AF_INET and include a
struct ip_hdr as it is not available on *BSD.
2012-07-12 14:13:41 +02:00
Andreas Eversberg 3c6a2cef5e VTY: Allow to compile vty.h and command.h headers with C++ 2012-07-12 09:42:36 +02:00
Holger Hans Peter Freyther fb4bfc2ad5 logging: Fix compile breakage introduced by the warning fixes
Make sure the declaration and definition match, add const to
the functions called by logp/logp2.

Compile output:
logging.c:317: error: conflicting types for 'logp'
../include/osmocom/core/logging.h:34: note: previous declaration of 'logp' was here
logging.c:327: error: conflicting types for 'logp2'
../include/osmocom/core/logging.h:168: note: previous declaration of 'logp2' was here
make[3]: *** [logging.lo] Error 1
2012-07-12 09:26:25 +02:00
Alexander Huemer e62651f220 correct inverted logic from commit f3ba8a 2012-07-11 11:00:02 +02:00
Andreas Eversberg 2d6563b78e logging: Avoid compiler warnings when compiling c++ code
this patch i use to suppress warnings when compiling osmo-pcu (c++).
since __FILE__ is constant, the called logging function with parameter
"file" must be constant too, in order to avoid compiler warnings.
2012-07-10 13:10:15 +02:00
Harald Welte 2d956a82c8 bssgp: check for IMSI being a null pointer, not just an empty string. 2012-07-04 21:55:23 +02:00
Diego Elio Pettenò c5f055f9e5 build: use LT_INIT(pic-only) instead of forcing -fPIC.
This actually allows for the user to override the decision and at the
same time supports compilers that might not be able to use -fPIC at
all.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:44 +02:00
Diego Elio Pettenò f3ba8abc97 vty: avoid using a .data variable.
no_password_check was the only initialized, non-relocated data in the
set of libraries, inverting its logic let us keep it in .bss
(non-initialized data, which is mapped to the zero page).

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:44 +02:00
Diego Elio Pettenò 23431c75c8 codec: make data tables constant.
When declaring them constant, they are written on the .rodata section
instead of .data, which means that they can be mapped directly from
disk to memory.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:44 +02:00
Diego Elio Pettenò 200710e3eb build: use default htmldir directory.
Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò 7e007e0f87 build: avoid multi-level recursion for src/ directory.
Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò 406777cfdb build: LT_INIT already replaces AC_PROG_LIBTOOL.
Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò 001ef7ea4d build: avoid calling undefined macro.
This line was reporting "command not found" and should not be a
problem, as there's a check for the same thing later on.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò 8dd81fa31f build: avoid duplication of automake options, add no-dist-gzip.
There's little to no point to build the gzip version of the tarball
when we're building the bzip2 version.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò a1ed2f0bb1 build: use BUILT_SOURCES for the generated source files.
This avoids possible race conditions on heavily multi-core systems.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò f5df9ab549 build: use the standard AM_V_GEN definition for output.
This actually allows for the command to be printed if using `make V=1`

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò d471a21920 build: simplify headers management and remove recursion
There is no real reason to keep the include directory a multi-level
recursion, so instead declare everything within include (so that we
can use proper nobase_ declarations) and be it.

Please note that since we removed the sub-Makefile.am, ./configure
will not create the directory structure for us on out-of-tree builds,
so we have to make sure the directory we're generating to exists first.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:43 +02:00
Diego Elio Pettenò ea0e1eca2b build: simplify test handling and speed up build.
Instead of using a ./configure parameter to decide whehter to build
tests or not, use the check_PROGRAMS variable so that the tests are
only built when running `make check`.

To avoid slowing down the test phase itself, collapse the declaration
of the test targets in the tests/Makefile.am file, this way they can
be built and linked in parallel before the testsuite is executed.

Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
2012-06-30 22:01:42 +02:00
Harald Welte 327009e420 GAN/UMA: use correct IE Identifier foer T3920
As Dieter found out, there has been a mix-up of 3902 with 3920 :/
2012-06-29 21:14:52 +02:00
Harald Welte 57799ed87f osmo-auc-gen: Add "-I" mode for generating triplets.dat for strongswan
If you want to use eap-sim-file with strongswan, you need a triplets.dat
file in a specific format.  osmo-auc-gen can now generate the respective
format automatically.
2012-06-27 15:06:19 +02:00