Age | Commit message (Collapse) | Author | Files | Lines |
|
This is fixing a segfault due calling bsc_unregsiter_fd twice
without being in the list.
|
|
Check if we do have the msc_data before invoking code in
bssap.c. We might have lost the MSC connection and asked
for the channel to be taken down but we might have received
one last message from the BTS.
|
|
Sending a RLSD with SCCP failure makes the MSC free all the resources
(MGCP, audio channels), right now we are ignoring the RLC we get from
the network and print a unhandled message.
|
|
|
|
|
|
This allows that we can print the Nr. next to the lac
and it allows us to change the lac at runtime without
reconnecting the BSC.
|
|
|
|
|
|
|
|
|
|
|
|
Currently vty_interface.c is used for the BSC config, in case of
the MGCP Gateway or the BSC Nat process these logging commands are
not available. Move the commands to a new vty_interface_cmds.c file
to allow to share basic commands across different programs.
|
|
Use the fd of the BSC Connection to determine the IP address of the
BTS as we are seeing it.
|
|
|
|
For the nat we might or might not want to patch it, do not
patch if we have no valid rtp payload type.
|
|
This value is copied into the bts_audio_payload when allocating
a BTS MGCP endpoint. For the nat we have actually no interest in
patching MGCP messages. We will patch them to the network because
the code will do it anyway, we will not patch things back to the
BTS.
|
|
|
|
Remove the code to parse port as we need to discover the
BTS behind the nat and most likely it will have a different
port than the one advertised by the BTS.
This reverts commit c6a1fe773d16eb20d4cb1d3097761419436f4537.
|
|
The value might be a non printable one.
|
|
|
|
We need to patch the source/dest reference inside the messages
as well otherwise we will see failures in the SCCP connection
on long calls.
|
|
Cleanup all endpoints that belonged to a given BSC. This is
one part of the cleanup, the other is to bring down the SCCP
link properly.
|
|
|
|
Make exit from the MGCP node work properly.
|
|
Make sure exit in nat and nat/bsc is working and we go one
level up.
|
|
Fix the test to search for the original message instead
of the already patched one that should not find any items
anyway.
The remove is called on already patched connections so we
need to match it with the patch reference count.
|
|
Before the connection was not properly removed from the list of
connections and our connection list contained a dangling pointer.
|
|
E.g. when the underlying connection transport medium is gone
one needs to force to close SCCP connections, add this helper.
It will remove the connection from the list of connections and
it will free the data.
|
|
This allows to more easily compare the numbers with traces
seen in wireshark.
|
|
|
|
Print some more information, e.g. when a BSC is connected
and authenticated, print the SCCP ref number.
|
|
This message can get in the way during a re-establishment
of the MSC connection while the MSCs gateway is still sending
data to us.
|
|
The SCCP might have been freed by the error case already
so we need to check this one for zero.
|
|
|
|
Extract the port from the BSS's MGCP Gateway so we know
where to forward the data to.
|
|
|
|
|
|
Instead of checking the token for NULL we need to check if running
was set to null. Look at the data of the token and check if the line
was ending with a \r\n or \n and then when rewriting a line use that
line ending as well. Add a new test for that.
|
|
The length field of the IPA header allows to have 16bit numbers
and I just ran into the 300 byte limit with MGCP messages. Make it
three times the size and see how long this is going to be enough.
|
|
The endp is part of an array allocated by talloc and simple
array members do not qualify as a context start address.
|
|
The MGCP protocol parsing is adding '\0' to make sure we do not
parse beyond where we should parse. This does not mix with strtok
or similiar routines.
For now we will read the msg into a global array first, then copy
it to the msgb for mgcp protocol handling and if we are required
to forward it to the MGCP we have a untouched copy we will modify
into our own msgb.
|
|
|
|
we need to set the msgb l2h to the right position otherwise
when trying to dump it we will have a nice crash.
|
|
len contains the actual length of the message and data_len
contains the size of the message. We want to read up to
data_len and not up to 0 bytes.
|
|
|
|
|
|
The autobind is not working as I wanted it to work. So we will
revert this for now and then try something else.
This reverts commit fd876b7488a8ae924f1a09144265d4474495408f.
|
|
When moving it up here the code started to reject
the identity responses of the bsc and we would
never authenticate. Move it back down.
|
|
When reading MGCP is failing (e.g. because the udp socket
is not connected yet) we would have freed the msgb but we
didn't return and then executed msgb_put on a dead buffer.
|
|
Attempt to find the message by transaction id, then patch
the response and use the IP/PORT of the local network, update
the ci with the one from the BSC.
This is currently not tracking any state of the MGCP and will
not handle two bsc's... this will need to happen later.
With this in we should be feature complete and now enter the
mode of making all of this work reliable and fixing thinko's
and other bugs.
|