AgeCommit message (Collapse)AuthorFilesLines
8 daysmncc: mncc_create_remote_leg: use mncc_write instead of write direct to the fdHEADmasterAlexander Couzens1-2/+1
Change-Id: I870c16d7ee5e5424304f3c1c9fb78af418ae2577
8 daysmncc: Introduce mncc_rtp_write similiar to mncc_writeAlexander Couzens1-9/+16
Concentrate the write() to the socket in 2 places. One for struct gsm_mncc and one for struct gsm_mncc_rtp. Improve debugging as now all function debug print the MNCC primitiv. Change-Id: Ia84602955b913a3bb13de7a6a92048799f2e1955
9 daysmncc: add return code for write/send functionAlexander Couzens1-10/+20
Allow to get errors back for the caller to clean up state. Change-Id: Ic926d192c238ef84fb3ad2be27e507e010b0e93f
9 daysmncc: remove callref argument from mncc_write()Alexander Couzens1-6/+6
The callref is always included in the struct mncc argument. Change-Id: Ia156010194c1f4334a4966d01aadfd02fa7097a8
10 dayscontrib/jenkins: don't build osmo-gsm-manualsOliver Smith1-1/+0
Related: OS#4912 Change-Id: Iae17e6d6f4242f98676dd3a1b01c419ac7288047
2020-10-12contrib/jenkins: Enable parallel make in make distcheckPau Espin Pedrol1-2/+2
Change-Id: I17e1adac40ac01daee0dd83da0a6aaebd78ea0dc Related: OS#4421
2020-09-18sdp: Don't select addresses failing to parsePau Espin Pedrol1-6/+7
Change-Id: Ibfc308bdfab77d0032d8f20c2f0df913e336b75b
2020-09-10mncc: Support IPv6 addresses (new version mncc 7)pespin/ipv6Pau Espin Pedrol5-49/+75
Change-Id: I3b1bebbcc9e36be43d8d055c8d28cbb38ff21b37
2020-09-05Revert "sip: Specify invite contact tag"Alexander Couzens1-5/+0
This reverts commit 52b2afce2ca902bbae4a550d03d471be784efe28. The contact header is generated by the original sofia-sip library. By adding the contact header explicit as user header it violates the SIP RFC because sofia will add the Contact header to the BYE message as well. Let's fix the bugs in the freeswitch sofia-sip and make it compatible (not bug compatible) with the original sofia-sip. Change-Id: I712f17fecbc372d1e486e80673a548e281b37800
2020-08-13sip: Specify invite contact tagMatt Johnson1-0/+5
Version 1.12.12 of libsofia-sip-ua no longer automatically generates a contact header element from the local ip address and port. Specifying the contact tag does not break operation with the existing library (1.12.11), but allows for operation on a system with freeswitch 1.10.4 or later installed, which is built against this new version of libsofia-sip-ua. Change-Id: I5c35c5a4bad2fbe76c22ac6d7ee37c832e0ba246
2020-08-13debian/control: change maintainer to the Osmocom team / mailing listVadim Yanitskiy1-1/+1
Change-Id: Id7a258c52e72101920a1c0de5534a2ed9f488203
2020-08-13Bump version: → Welte1-0/+9
Change-Id: I66c64cae47e32a16ef605348d02884172ef04d70 EXTRA_DIST: debian, contrib/*.spec.inOliver Smith1-1/+7
Change-Id: Ifee945e89b8b3d1a9ef9cf57e36cad306c244657
2020-05-19contrib: integrate RPM specOliver Smith3-5/+9
Remove OpenSUSE bug report link, set version to @VERSION@, make it build with CentOS 8 etc. Related: OS#4550 Change-Id: I387b41b6c524cd3f6baad7e89b4b6b347d9998ac
2020-05-14contrib: import RPM specOliver Smith1-0/+78
Copy the RPM spec file from: Related: OS#4550 Change-Id: I00f13acd541ec492e4671cf88c92010f5cf61e9e
2020-01-02Bump version: 1.3.1 → Espin Pedrol1-0/+22
Change-Id: Ia6693372994791bac4ab86808729f5e568dd9176
2019-12-17logging from sofia: add missing newlineNeels Hofmeyr1-1/+13
Sometimes, logging from sofia lacks the final newline character, messing up log output. First snprintf() to a buffer, add '\n' if necessary and then log. Change-Id: Ia26c0b57a0166cf7de87c49471ce6f528a366dd5 switch to python 3osmith/fix-python3Oliver Smith1-1/+1
Make build and external tests work with python3, so we can drop the python2 dependency. This should be merged shortly after osmo-python-tests was migrated to python3, and the jenkins build slaves were (automatically) updated to have the new osmo-python-tests installed. Related: OS#2819 Depends: osmo-python-tests I3ffc3519bf6c22536a49dad7a966188ddad351a7 Change-Id: Ic913e336a5a962fe9515479b03eecdbef0917721
2019-11-28MNCC v6: add optional SDP to the socket protocolNeels Hofmeyr2-1/+10
Add the new SDP section to the MNCC socket protocol, but do not yet implement forwarding SDP from SIP. Implementing SDP forwarding follows in a subsequent patch. It is still possible to establish a call with empty SDP: the new osmo-msc on the MT side, receiving an MNCC_SETUP_REQ, will hit an error log: "Got no information of remote audio codecs: neither SDP nor Bearer Capability. Trying anyway." and then hold thumbs to hit a codec match, analogous to previous behavior. Note that osmo-sip-connector should actually always have encoded a Bearer Capability in the MNCC protocol in the MT MNCC_SETUP_REQ message, but never has. Now we are ready to leapfrog from zero codec info to full SDP. This patch must be merged at the same time as osmo-msc patch Ie16f0804c4d99760cd4a0c544d0889b6313eebb7, so that both sides have a matching MNCC protocol version number. Change-Id: Iaca9ed6611fc5ca8ca749bbbefc31f54bea5e925
2019-11-28mncc.c: fix gsm_mncc_rtp size checksOliver Smith1-2/+2
Verify is the parsed data is at least the size of the struct, not exactly the size. Make it accept messages with additional data, like the SDP information the TTCN-3 testsuite is sending since Ic9568c8927507e161aadfad1a4d20aa896d8ae30. This change makes the size checks consistent with the two other size checks in the file: if (rc < sizeof(*rtp)) { if (rc < sizeof(**mncc)) { Related: OS#4282 Change-Id: I522ce7f206932a816a64f03d916799c3215bb8c7
2019-11-23exit if the sip agent failed to startAlexander Couzens1-2/+4
When the sip agent start fails (i.e. port can not bind because IP doesn't exist) exit the sip-connector Relates: OS#4197 Change-Id: I22ed16c77391b4f270df498dda587ed657279390
2019-09-16.service: require to ran after network-online.targetAlexander Couzens1-0/+2
Relates: OS#4197 Change-Id: I09bf8139582ef198fdbe664be32b14d8c9c99f1a
2019-09-02mncc: check fd before closing a connectionPhilipp Maier1-0/+6
The function close_connection() closes the fd without marking it as closed. Lets set the fd to -1 and check at the beginning if it is greater than zero. This prevents us from closing an already closed fd again. Related: OS#4159 Change-Id: I9742f31a37296fed15d54cf44c1f65b93abb8c8e
2019-08-09coverity: Address issue found by coverityKeith1-1/+11
Add NULL checks on the return value of call_leg_other() in update_rtp() If the remote side has requested media change and we cannot find the other leg, then release call. This should not happen. Also, Add an assert to show that we cannot be here without call type of SIP or MNCC (not related to coverity) Fixes: CID#202863 Change-Id: I6f1f26533a25c93f243090bc02f1bc83b9108d42
2019-08-08Bump version: → Espin Pedrol1-0/+41
Change-Id: I3d3d048380753431c313cffa82de430dfbd3b93c
2019-08-08Require newer libosmocore 1.0.0Pau Espin Pedrol2-4/+4
Use of osmo_mncc_name() requires libosmocore 0.12.0 Use of gsm48_cc_cause_name() requires libosmocore 1.0.0 Change-Id: I466140a9c1e05c191fe1b079cf3615fd6ac5fb8c
2019-08-07In hold/retrieve/reinvite, add check that other_leg existsKeith2-0/+31
We should always check that the other leg did not somehow dissapear before accessing it. Change-Id: I947aab6c0cc5019929bde1c7012e1a8c3d3472a5
2019-08-07Logging: Make use of Levels, clarify some messagesKeith2-20/+20
Up to now most logging is on LDEBUG, lets make more use of Log Levels. reserve NOTICE for unusual events INFO: normal call setup/teardown DEBUG, well.. it's DEBUG * BYE is not an Error. * 4XX or 5XX response to INVITE is not an Error don't log as such. * 183 does not necessarily mean "ringing". Change those log messages for clarity. Change-Id: Ie0014043d93303a87cbb8bb351e439ff78651cbe
2019-08-07Handle case where SIP side hangsup while MNCC is on holdKeith1-0/+1
Change-Id: Ie32690e036180e6b80a1b59177c1a72a6fd78d15
2019-08-07Cosmetic: Logging and Comments, spelling and clarity changesKeith5-21/+21
Also removes a comment in sdp_create_file() about the IP address in o= and c= having to be the same. It is completely legal in SDP and often normal for the originator and the connection information IP to be different. Change-Id: I057573467c335fc27ead391c0bb4c775f2f6ba0a
2019-08-06Define hold/retrieve functions for MO callsKeith1-0/+2
My original patch that introduced this functionality, bd2d14bd4af592c2694217d84aaf81d759d2ca1 only did so for MT calls. Change-Id: Ifd42ed94053f6a38abfe6d6b18e2fe3582d037bb
2019-08-06Fix bug with MO calls not connecting.Keith1-3/+5
Fixes a bug I introduced in 5f73c2033b6b4e690f30292020d7361f48b5f2c2 where we would not call mncc_call_leg_connect() on receiving 200 from SIP side, and therefore never send MNCC_SETUP_RSP to the MS Fixes: 5f73c2033b6b4e690f30292020d7361f48b5f2c2 Change-Id: Ic7cc56c0d68a27eb1229c0c4aa1fa54d00b660b6
2019-08-06inet_ntoa() is deprecated, use inet_ntop() insteadKeith3-6/+17
Change-Id: If6a96ede7d5e73884c32fbfdb03052e2bda50a77
2019-08-06Following from previous commit, assume other->ip is network byte orderKeith1-1/+1
Change-Id: I3641a843a3b4a9b2686c1a07d48f52527dce46a2
2019-08-06IPs stored in the call struct are NETWORK byte orderKeith1-3/+3
As far as I can make out, the intention is to always store ip address in the call struct in network byte order, whereas the ip address sent on MNCC are in host byte order. Change-Id: I89ef26aa32a672f394699251cf560b53ae01a814
2019-08-05Remove undefined param passed to {logging,osmo_stats}_vty_add_cmdsPau Espin Pedrol1-2/+2
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However, definition in C file doesn't contain "(void)", which means number of parameters is undefined and thus compiler doesn't complain. Let's remove parameters from all callers before enforcing "(void)" on it. API osmo_stats_vty_add_cmds never had a param list but has seem problem (no "void"), so some users decided to pass a parameter to it. Change-Id: Ie519d4a4064a95803c33fd6969b53e1ef27045b7 Related: OS#4138
2019-08-05Only send update to MNCC if media info changed.Keith1-2/+2
Do not send an MNCC_RTP_CONNECT as a result of a SIP re-INVITE, unless the media connection information has changed. Change-Id: I7c48300092a309e50a8fe091b30e395e7c72de9d
2019-08-05Add support for MNCC HOLD/RETRIEVEKeith2-7/+55
Handle MO hold and retrieve and pass this to the SIP side. Handle the 200 from the SIP side in response to our HOLD-ing re-INVITE. With this commit we now handle MO hold and therefore also handle call-waiting and swapping. Change-Id: Ife7bdab20cde92b7ce550215bab28b36a0f302e9
2019-08-05Prepare to support MO Call HOLDKeith3-0/+55
Add function pointers to the call_leg struct for call hold and retrieve. Add function to send re-INVITE to SIP side when MNCC side puts call on HOLD/RETRIEVES. Add MNCC/SIP CC_HOLD to call states. Change-Id: I2595626dfa50eb2f8e29a02540b708c9c1dce88c
2019-08-05Handle SIP re-INVITEsKeith5-6/+158
SIP end points can send periodic re-INVITES. Previous to this commit, the osmo-sip-connector would send a new call SETUP to the MSC for each re-INVITE. Add a function to find if we already handle this call based on the nua handle. Use this function to detect and respond with an ACK to re-INVITES. Add a function to extract the media mode from the SDP. In the case the re-INVITE has a=sendonly (HOLD) respond with a=recvonly In the case that the re-INVITE changes the media connection ip/port, forward this to the MNCC side with an MNCC_RTP_CONNECT Change-Id: I4083ed50d0cf1b302b80354fe0c2b73fc6e14fed
2019-08-01Add media mode parameter to sdp_create_file()Keith3-6/+29
This enables call hold implemented by subsequent commits Prior to this commit, osmo-sip-connector would not send any media mode attribute in the sdp. After this commit we will by default always include a=sendrecv. Given that a media mode attribute of "sendrecv" is default and implicit it its absense, this does not represent any functional change. Change-Id: Ib4212d0174955042e7d80d3744ce632a4942ccb2
2019-07-10contrib/ run "make maintainer-clean"Oliver Smith1-0/+1
Related: OS#3047 Change-Id: Ie2e181a6e74053c407f7ed3db17631ae041c9754
2019-05-29debian: create -doc subpackage with pdf manualsOliver Smith4-2/+18
I have verified, that the resulting debian packages build in my own OBS namespace (see the -doc packages): Depends: Ib7251cca9116151e473798879375cd5eb48ff3ad (osmo-ci) Related: OS#3899 Change-Id: I30df67b1c31f07e85002da4c2c75afb67ba529d2
2019-05-22Cosmetic: debian: build-depends in multiple linesOliver Smith1-1/+8
Change-Id: I2d126341d8653408b0a6a371088aead58b61bb84
2019-04-29Properly indent config fileDaniel Willmann1-3/+3
osmo-config-merge expects only one space indentation for each level and the VTY also outputs the config formatted like that. Change-Id: I9c7a5bc6b3eae955288dada80abc856779ca9336
2019-04-21MNCC: Do not continue with B leg if A leg is cancelled.Harald Welte1-2/+13
In case we receive MNCC_RTP_CREATE after MNCC_DISC_IND, check if the call is already marked in_release and if so, send MNCC_REJ_REQ and do not proceed with the B leg. Related: OS#3518 Change-Id: I0eca9a741f7924c2fc32c503dd1a0fc083f94f37
2019-04-18Added daemonize feature to osmo-sip-connectorrafael2k/daemonizeRafael Diniz1-2/+16
Change-Id: I400fb5a2619f348cc60e8c9016154afa60424e66
2019-03-19Support Emergency CallingKeith1-5/+19
LCR supports emergency calling by sending the string 'emergency' as callee to the SIP side. This does the same Change-Id: I5d0adb61dfa82e7ded5f41d9bc773d546112c9f1
2019-02-14cosmetic: use OSMO_STRLCPY_ARRAY() instead of osmo_strlcpy()Harald Welte1-1/+1
This saves us the extra sizeof(). Change-Id: If329f122017c0c5b5222e46d55f39731c5bdf662
2019-02-14Support International Caller IDKeith1-2/+8
When the SIP call source contains + as first character, set the TON to International so that the MS displays caller ID correctly Change-Id: Idcfa31aff90e04dd0aa3583957f288889b1bbefe