Commit Graph

60 Commits

Author SHA1 Message Date
238ee9195c update copyright year for 2020
Change-Id: I28f193813ad72ee5936ef0be7f252c40c3b748ee
2020-01-03 15:04:47 -05:00
7d2e5506cf project: use cmake to generate ring-daemon vcxproj
Change-Id: Ib1d736c241849415eaef957c9e6565e78cda45f1
2019-12-31 15:36:16 -05:00
8599bcdd23 build: ignore python utf-8 parsing errors when finding vs lastest dir
Change-Id: Ia03ace8826ac44820c621c9ff2ee1a99b26bbf1b
2019-12-12 12:30:23 -05:00
31b8adf195 project: fix the bug of identifying env_set logic
Change-Id: Idb13d1e98d9ddf3ae4f68aec27c08e4e25dc1d36
2019-12-05 13:56:07 -05:00
b49029a687 build: ignore python utf-8 parsing errors when decoding env vars
Change-Id: I362550773790643a663b6e8da70b48cb1064b391
2019-12-04 14:22:04 -05:00
12742b8cb1 win32: add python build script
Change-Id: I464d2f29173d2bcfdf6ddea5e26ed9e0192e98ae
2019-11-29 13:31:05 -05:00
fd08346ffa build-scripts: default to win32/x64
Change-Id: I01a703da1d29fe592686e2807438168f91da63be
2019-11-11 18:00:24 -05:00
db5d66d408 vcxproj: add media/congestion_control
Change-Id: Ia30b4908e115432b9138173813f2236cdb87408d
2019-11-11 16:35:50 -05:00
2d90977034 upnp: asynchronous open/close ports
The UPnP stack now opens and closes ports with an
asynchronous mechanic and with callbacks.

Every time a mapping request (open or close) is sent,
a callback is registered and managed by the context.
When the corresponding protocol executes the request and
gets an answer, the right callback is found and dispatched
to its controller. A timeout of 1 second is implemented
on each request.

Controllers can now be tracked with a unique Id (a string
that represents its location in memory).

The IGD class now tracks its current active ports and
manages the number of users for each port.

The PMPIGD class now operates using a queue of mapping
requests. Whenever a request is made to the natpmp protocol,
it saves the request to its corresponding list (mapToAdd,
mapToRemove or mapToRenew in the PMPIGD class) and notifies
the main natpmp thread. The thread then checks if there
is any pending map requests in the PMPIGD queue and treats
them accordingly.

Add Nat-Pmp support for windows.

Fixed bug where nat-pmp wouldn't find an IGD on a new interface
after a connectivity change. The problem stems from the fact
that, for one, the nat-pmp handle didn't get cleared internally
once a connectivity change occured. This would cause the nat-
pmp library to try and send searches on a socket that was
bound on the old gateway. Secondly, if you don't wait for a
little period of time, the natpmp library would discover the
old IGD on the old interface before the connectivity change
modifications were completed. Now we restart the nat-pmp
process one second after the connectivity change triggers.

Change-Id: I39a9b57e237deaa65eef4464a1838eaa3c5bbb03
2019-11-08 17:15:19 -05:00
4c899b1e15 jamiaccount: add manager configuration property
Change-Id: I32136e7381b2f3f73f206a83d573822c6b291291
2019-09-10 17:35:56 -04:00
75b134cf17 jamiaccount: split account management
Change-Id: I669bfcc6f0e3f7bd60c56f0046f8701ad14541ce
2019-09-10 17:35:34 -04:00
a945fd54bc contrib: add asio/openssl/fmt/http_parser/restinio
- removes restbed
- bumps opendht

Change-Id: Ia5586e2871ecb6df9d676d59c29314984ab9bab5
2019-09-10 11:37:50 -04:00
36639d8cdf win32: move dlfcn src into msvc subdirectory
Change-Id: I4079cc8c9075117f3135065e945752d9b9e5bdad
2019-09-06 15:24:03 -04:00
25068e2e4f win32: convert utf-8/utf-16 when accessing win32 apis
- any functions that get strings from windows apis, are converted
  and stored as utf8 strings internally
- anytime an internal utf8 string is passed as a parameter to a
  windows api function, it is converted to a wstring
- all of these translations apply currently to file paths
- a windows client should make sure to setlocale to utf8 because
  we use some dependencies that call mbstowcs and wcstombs instead
  of WideCharToMultiByte/MultiByteToWideChar

Change-Id: Ic13f55ace491e1088c0a3d436d3a0d02df7216c3
Reviewed-by: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
2019-09-04 11:34:59 -04:00
60515d893a upnp: support libupnp and libnatnatpmp simultaneously
Update libupnp to version 1.8.4.

For windows, the IPV6 preprocessor must be undefined. Or else
libupnp won't initialize. Added visual studio 2017 support
via one patch for windows that also combines previous windows
patches.

UPnPController: Class that the jami classes use to control the
opening and closing of ports. Every  service has it's own upnp
controller. The controller does it's actions by using the upnp
context class. Also refactored the functions used to add
mappings. Instead of using two different functions with
different types of parameters, we now use one function with
parameters that have default values. The logic stays the same
but the function call is more clear.

UPnPContext: Class that holds a (linked) list of discovered IGDs
and their corresponding protocols (which discovered them).
Whenever the controller wants to add or remove a mapping, the
context picks a valid IGD in it's list and uses the correct
protocol to complete the required action. This class also has
the ability to swap protocols for an IGD that was discovered
by more then one protocol.

UPnPProtocol: Virtual base class that defines the functions
needed by the context to use the corresponding protocol.

PUPnP: UPnPProtocol derived class that represents a upnp client
that uses the portable upnp library (libupnp). Every time the
client discovers a new IGD it uses a callback to add it to the
context's main IGD linked list. It also has an internal list of
IGDs that it discovered. Added features to this class include:
	- IGD event subscription.
	- Use UpnpInit2 function instead of deprecated UpnpInit
	  function. It's also supposed to support IPv6.

NatPmp: UPnPProtocol derived class that represents a upnp client
that uses the NAT-PMP library (libnatpmp). Unlike libupnp,
libnatpmp only supports discovering one IGD. Also uses callbacks
to add the IGD it finds to the context's main IGD class.

Also inclided debug warning prints whenever a controller opens
and closes the ports. That way we can keep track of whenever
the application opens and closes ports on the internet
gateway device.

Gitlab: #96

Change-Id: I199271edac2c6d93dc60c24e2e2aefe36de7950c
2019-08-02 17:29:10 -04:00
7f14365d76 update config: migrate to jami
Change-Id: Ie07b8ee33ee2e775733d5c2119a263181d31fb38
2019-07-15 15:33:54 -04:00
cabf934909 ffnvcodec: Add nvcodec windows support
Add fetch_and_patch script for ffnvcodec.

fetch_and_patch script copies needed headers to contrib include
directory.

Patch file to adapt ffmpeg configure script for ffnvcodec package
inclusion. On linux pkg_config is used. On windows the files
need to be included manually.

config script includes path for ffnvcodec files and corresponding
flags are set.

Change-Id: Ia9daca2a49316a4373652acb718930d02f85e3f6
Reviewed-by: Philippe Gorley <philippe.gorley@savoirfairelinux.com>
2019-07-13 20:53:09 -04:00
25844a8f3d use OpenDHT thread pool
Change-Id: Id6dbc59b48a61f9d27f01dff22ca93ad3eebc4f2
2019-04-29 18:45:03 -04:00
6af72289f8 rename ringdht to jamidht
Change-Id: Id5673ba9f2ec519070cc112685dea5ced94c3b38
2019-04-17 10:15:15 -04:00
f8c5037e1b rename RingAccount to JamiAccount
Change-Id: I67e03e6711a46e6d241ee249bfa480ac76abfa93
2019-04-17 10:15:15 -04:00
adafd963c0 win32: fix filter_transpose for native windows build
Change-Id: I859348239f76c2830389ae625a8bc7bb5d3d4dfa
2019-04-04 12:43:01 -04:00
2130f067b6 sources: rename to jami
* rename namespace from ring to jami
* rename logs methods from RING_* to JAMI_*
* rename RING_VIDEO to ENABLE_VIDEO

Change-Id: Ic98498652d7059fafe58a96220d565bcdfa53658
2019-04-02 17:11:40 -04:00
36bee9bb72 build, contrib: remove pcre
Change-Id: Ifc2c224afe9d3de9d52ecc1d66d7d81ccec524ac
2019-03-11 13:08:00 -04:00
f0506e1622 regex: use std::regex instead of pcre, remove pattern
Sdes_negotiator: Omit pattern.h,unique_ptr Using regex
pluselayer: Remove support for pcre

Change-Id: Iab71f482df0dd89de72e28befa25abc0dadab79f
2019-03-11 12:05:20 -04:00
d3e9462231 build: build specific contribs on windows
Change-Id: I2b5b0d4892d44ff861a45a2a4d7cff937b1e280f
2019-02-19 11:24:42 -05:00
2a806fa26d misc: update copyright date
Change-Id: Ia4ed75d04a284efa0763c917aeaa2f08863a87cb
2019-01-02 17:49:21 -05:00
123703b42a win32 build: update vcxproj
Change-Id: I568c616fab0cd019150eb58262edd470759c4e11
2018-12-27 15:47:16 -05:00
8d33ef2d84 msvc: update project files
Change-Id: I2fe5d28baa0cfece429b259dc0c5c026d7932db6
2018-12-05 13:23:06 -05:00
cbe86525fb vs project: add localrecorder and audio_input files to vcxproj
Change-Id: Id92fc7e89896a76b4288a9f6fcbd9a91c85da724
2018-09-13 16:35:39 -04:00
d078df0aa3 vs project: fix native windows build
- remove audiorecorder source files from project
- add scheduled_executor source files to project

Change-Id: Iab499e7f9ff6ba4636b5e042629b4b685c646af3
2018-09-05 11:09:31 -04:00
47586cba7e build: add default PDB for ReleaseLib vcxproj configuration
- the default setting is /Zi(ProgramDatabase), so this patch
  specifies that so the line can be removed with a sed in our CI

Change-Id: I2ac60d755569f8aec3ca94f4b73b9cae4993e8b1
2018-08-09 09:55:32 -04:00
ea8197713a build: remove libsamperate for native windows builds
Change-Id: I13a43623c1e23b09557782f865d64a421d5c0cac
Reviewed-by: Philippe Gorley <philippe.gorley@savoirfairelinux.com>
2018-08-03 17:02:36 -04:00
834e835dee audio: remove sndfile dependency
Removes unused/deprecated audiorecord/audiorecorder
Allows any file to be used as a ringtone (mp3, ogg, etc)

Change-Id: I9ce33ec3d5f083caf098266befa597e78a95d7d6
2018-08-02 17:20:50 -04:00
b106642f5d build: alterations for win32/uwp msc compliance
Change-Id: I02061e1319499e694817000e6184d1735c67261f
2018-07-30 18:15:14 -04:00
2cbbaf7983 configure: remove ilbc and gsm
FFmpeg's RTP muxer does not support GSM, while Ubuntu does not package
iLBC. Removes the old configure switches.

Removes package detection from contrib. Keeps contrib rules in case GSM
is later readded.

Change-Id: I705a521e2baf34c757c22a72e04cdf27233b5a7b
2018-07-30 13:15:51 -04:00
55f48f133c fix spelling errors
Change-Id: Ifbc5f3792a7019dcfa8249eb30afe2a64cbeb57c
Reviewed-by: Sebastien Blin <sebastien.blin@savoirfairelinux.com>
2018-07-26 14:05:58 -04:00
009ddf3646 project: migrate to vs2017
Change-Id: If991ec828c34a6b51c1aa12e0f316abf76a5c781
2018-06-20 00:58:18 -04:00
e9737c9c3d vs project: change to "old style" PDB for release build
- https://bugs.eclipse.org/bugs/show_bug.cgi?id=518765#c2
  describes a bug that seems to occur during concurrent Jenkins
  builds when /Zi (complete debug information) flag is enabled.
  This patch changes the flag to "C7 Compatible (/Z7)" in an
  attempt to prevent these failed concurrent builds.

Change-Id: I0a777c66651463488352d3e3797b89d5ed1b1791
Reviewed-by: Philippe Gorley <philippe.gorley@savoirfairelinux.com>
2018-05-15 09:07:15 -04:00
0eae0449fd namedirectory: use https instead of plain http requests
Add libressl dependency to compile restbed with ssl support. Also,
this patch removes a unused file.
Bump asio to works with libressl instead of openssl.

Change-Id: I5a90dba97693ccda58899f69080e545bdea926d9
Signed-off-by: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
2018-03-29 10:54:00 -04:00
616d478564 build: update visual studio project and fix some build issues
- adds rfc6062 patch for pjsip 2.5.5 for uwp
- updates files built by the vs project (adds some related to file
  transfer, removes those that are deprecated)
- corrects native build problems
- simplifies project layout
- links the minimal client with libdl(temp fix)

Change-Id: Ib82b0470f568cb79dc1f4353cb5a5ef20de93033
2018-02-09 17:03:28 -05:00
c5e74abe53 Ringaccount: add support for DHT proxy and push notifications
* Bump restbed for OpenDHT, update patch and add patch to react
  to timeout and socket closed in restbed.
* Bump OpenDHT to support push notifications
* Add DRing APIs to support setting a client push notification token
  and to retransmit push notifications to dring
* Implement proxy support in RingAccount

Change-Id: I8d3a02cf54a9666a94ab992ee3fa2958e82aa7ad
2018-01-31 11:20:53 -05:00
1aa7759f8f 2018 copyright date update
Change-Id: I1ef88bc640f79790aad2b5285ea2c776aa8cd366
2018-01-23 17:26:34 -05:00
0d7545cb03 build(UWP): add diffie-helman files to project
- Updates the vs2015 project files
- Adds ciso646 header to diffie-hellman.cpp for logical operator
  compatibility with the Microsoft compiler

Change-Id: Ie858e054bf26cf839bef6eace79fa546894a7963
Reviewed-by: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>
2017-12-07 15:29:21 -04:00
212b50e973 contrib(UWP): (fix)bumps pthreads to avoid deadlock during upnp init
After removing the boost dependency, the Ring UWP was unable to load
accounts with upnp enabled, as a deadlock would occur within the
threadpool initialization rountine of libupnp. I think the windows store
build of pthreads was preventing win32 thread management api symbols
from being defined. Something which loading boost must have been doing.

- Bumps pthreads-win32 from 2.9.1-release to 2.10.0-rc
- Builds a win32 static lib without windows store flags and uwp libs
- Modifies the libupnp and threadutils vs project patching

Change-Id: I3f43a066d86d284c614521fdb016810148590e70
2017-10-08 06:33:58 -04:00
37507752fb contrib: remove boost
Change-Id: I278ff88143330e826629268bc47e810ef1da6de2
Reviewed-by: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
2017-10-04 15:09:13 -04:00
e3918801a3 contrib: remove cryptopp
Change-Id: I2ce2bdbc87d8c0de4cebbb3cc00e4a76286aee82
Reviewed-by: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
2017-10-04 10:36:13 -04:00
44c61afc72 eth: bump sources, remove dependency to boost, cryptopp
Update "eth" to latest version from
https://github.com/ethereum/cpp-ethereum

This new version makes use of secp256k1 instead of custom
code and cryptopp to handle EC generation, and reduces its dependency
to boost to use more of the C++11 STL.

This allows to trim the code to completely remove the boost and
cryptopp dependencies.

Change-Id: I19118d3b833a9425cddbeabf6d0b6e07d5a4b15e
2017-10-03 02:14:01 -04:00
af01ff90b9 build(UWP): add accountarchive files to project
- Adds accountarchive files to visual studio project and includes
  ciso646 to ringcontact.h for alternate logical operator defs.

Change-Id: I712809bb7f25a3f9ed9ecb7e3b2abbab93892825
2017-09-18 13:45:39 -04:00
8ebb0c8f14 build(UWP): add security/memory to project file
Change-Id: I16cd669567e564926a609bc6b3e4ddd32110b260
Reviewed-by: Philippe Gorley <philippe.gorley@savoirfairelinux.com>
2017-07-20 11:46:25 -04:00
4ff5367c23 sip: remove SipIceTransport
SipIceTransport was a first implementation of a SIP
transport working over an ICE transport.
It was insecure and is now unused and unmaintained
(last actual change is from February 2015),
and deprecated by SipsIceTransport.

Remove it from the code base to speed up compilation
and avoid accidental usage by confusion with SipsIceTransport.

Also fix minor warnings in SipsIceTransport
(std::move of an rvalue).

Change-Id: I7a8ce2c0570d92bfe8bd191f2f6c8c6f2b191980
Reviewed-by: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>
2017-05-26 10:33:34 -04:00