Commit Graph

298 Commits

Author SHA1 Message Date
ad5607380f swarmchat: clone distant conversation
Retrieving a conversation is done by cloning the distant repository

Change-Id: Ib68749d0cd37ff708b08187e987cc3fdeaa0fbe6
2021-03-30 13:49:07 -04:00
c4e912dd89 dependencies: add libgit2 as a dependency
Needed by the swarm chat in the future

Change-Id: Ic5802a0de8091c12b6f5ed666ee488c620723149
2021-03-30 13:49:07 -04:00
80e62ef2dd configure: remove obsolete macro
Change-Id: I7a2227aafe585bee1f4ed115f22e987e77fd49ff
2021-03-28 16:05:06 -04:00
286d5f15ec configure.ac: Harmonize indentation.
Bring consistency in the indentation rules used throughout the file.

GitLab: #487
Change-Id: I4d8e4050a0f21df9a380fc25e0d3de04f15fe941
2021-03-28 16:04:36 -04:00
bfe7a84454 configure.ac: Do not set user variables.
The CFLAGS, CXXFLAGS, LDFLAGS and other variables intended to be
overridden by the user should not directly be set by the package.
This change uses one of the approaches recommended by the Autoconf and
Automake manuals, which is to use custom variables to accumulate flags
in the configure script and add them to the make targets they apply
to.  This has the benefit of not cluttering the flags used during the
Autoconf tests, which has proved problematic (see the previous commit
for a demonstration).

* configure.ac: Replace CFLAGS, CXXFLAGS, CPPFLAGS and LDFLAGS by
DAEMONCFLAGS, DAEMONCXXFLAGS, DAEMONCPPFLAGS and DAEMONLDFLAGS,
respectively.
Use these custom variables as the default values of AM_CFLAGS,
AM_CXXFLAGS, AM_CPPFLAGS and AM_LDFLAGS, respectively.  Remove an
extraneous check on jsoncpp.
* bin/Makefile.am (ringcli_CXXFLAGS): Honor the the AM_CXXFLAGS variable.
globals.mk: Extend rather than override the AM_CPPFLAGS variable.
* src/Makefile.am (libring_la_LDFLAGS): Honor AM_LDFLAGS.
(libring_la_CFLAGS): Honor AM_CFLAGS.
(libring_la_CXXFLAGS): Honor AM_CXXFLAGS.
* src/client/Makefile.am (libclient_la_CXXFLAGS): Honor AM_CXXFLAGS.
* src/im/Makefile.am (libim_la_CXXFLAGS): Remove variable.
* src/jamidht/Makefile.am (libringacc_la_CXXFLAGS): Likewise.
* src/media/audio/Makefile.am (libaudio_la_CXXFLAGS): Honor
AM_CXXFLAGS.
(libaudio_la_LDFLAGS): Honor the AM_CXXFLAGS variable.
* src/media/audio/coreaudio/Makefile.am (libcoreaudiolayer_la_CXXFLAGS):
Likewise.
* src/media/video/Makefile.am (libvideo_la_CFLAGS): Honor the
AM_CFLAGS variable.
(libvideo_la_CXXFLAGS): Honor the AM_CXXFLAGS variable.
* src/media/video/v4l2/Makefile.am (AM_CXXFLAGS): Extend rather than
override.
* src/plugin/Makefile.am (libplugin_la_CXXFLAGS): Honor the
AM_CXXFLAGS variable.
* src/security/Makefile.am (libsecurity_la_CXXFLAGS): Likewise.
* src/sip/Makefile.am (libsiplink_la_CXXFLAGS): Likewise.
* src/upnp/Makefile.am (libupnpcontrol_la_CXXFLAGS): Remove variable.
* src/upnp/protocol/Makefile.am (libupnpprotocol_la_CXXFLAGS): Likewise.
* src/upnp/protocol/natpmp/Makefile.am (libnat_pmp_la_CXXFLAGS): Likewise.
* src/upnp/protocol/pupnp/Makefile.am (libpupnp_la_CXXFLAGS): Likewise.
* test/sip/Makefile.am (AM_CXXFLAGS, AM_LDFLAGS): Extend rather than override.
* test/unitTest/Makefile.am (AM_CXXFLAGS, AM_LDFLAGS): Likewise.

GitLab: #487
Change-Id: I18be9d812159f8156efb9f7849e7eac6d4c6b3ca

squash! configure.ac: Do not set user variables.

Change-Id: I1146ea15d6fb75fe53d3cbdd782e981c933e82a6
2021-03-28 16:04:36 -04:00
5cca262551 configure.ac: Resolve libnatpmp conftest issue.
Do not unnecessarily clutter CPPFLAGS; the variable is honored by
Autoconf while running its conftests and can cause issues such as
symbol clashes between the libnatpmp and webrtc-audio-processing
library observed below:

configure:20851: checking for initnatpmp in -lnatpmp
configure:20873: g++ -std=gnu++17 -o conftest  -DNDEBUG=1 -O3 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPJ_AUTOCONF=1  -I/home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/include  -fvisibility=hidden -DDRING_BUILD  -Ddring_EXPORTS  -DASIO_STANDALONE -I/home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/include -I/gnu/store/zimpk6gqmjrwxc7fnam212kv3a6dwpzz-jsoncpp-1.9.2/include -DWEBRTC_AUDIO_PROCESSING_ONLY_BUILD -DWEBRTC_POSIX -I/home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/include/webrtc_audio_processing  -Wl,-Bsymbolic -ldl -L/home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/lib -L/gnu/store/zimpk6gqmjrwxc7fnam212kv3a6dwpzz-jsoncpp-1.9.2/lib -ljsoncpp -L/home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/lib -lwebrtc_audio_processing conftest.cpp -lnatpmp -lpthread  -lssl -lcrypto >&5
ld: /tmp/cc5prP4w.o: in function `main':
conftest.cpp:(.text.startup+0x0): multiple definition of `main'; /home/maxim/src/ring-project/daemon/contrib/x86_64-unknown-linux-gnu/lib/libwebrtc_audio_processing.a(libwebrtc_audio_processing_la-click_annotate.o):click_annotate.cc:(.text.startup+0x0): first defined here
collect2: error: ld returned 1 exit status
configure:20873: $? = 1

This was causing the link test of the libnatpmp library to fail,
which in turned caused the natpmp support to be disabled entirely.

* src/Makefile.am (libring_la_LDFLAGS): Add @WEBRTC_LIBS@.
(libring_la_CFLAGS): Add @WEBRTC_CFLAGS@.
* src/media/audio/Makefile.am (libaudio_la_CXXFLAGS)
[HAVE_WEBRTC_AP]: Add @WEBRTC_CFLAGS@.
* src/media/audio/echo-cancel/Makefile.am
(libecho_cancel_la_CXXFLAGS): Add @WEBRTC_CFLAGS@ and honor AM_CXXFLAGS.

GitLab: #487
Change-Id: I064d6a563318b34b2f3f516ca2aa8c2831205b09
2021-03-28 16:04:36 -04:00
cc6024ccba configure.ac: Remove uses of obsolete macros.
* configure.ac: Bump required autoconf version to 2.69 and remove the
uses of the obsoleted AC_HEADER_STDC and AC_HEADER_TIME macros.

GitLab: #487
Change-Id: Idb210870c298b83ddabe189e341d0846f04a1bb9
2021-03-26 14:48:19 -05:00
ad8909f0cb build: Enable the use of the dbusxx-xml2cpp tool built from contrib.
Previously, the build machine would need to provide dbusxx-xml2cpp
itself, while the library would be used from the contribs (always
forced, as dbusxx-xml2cpp is unmaintained and slightly broken on newer
GCCs).  This change removes the requirement to have the dbus-c++
package installed on the build machine.

Change-Id: I25ad2ee3e80afc33b320de9256b724a3c254f4fb
2021-03-26 14:27:03 -04:00
e787de4ea5 aec: move aec implementations into EchoCanceller
Hide speexdsp's echo cancellation implementation details behind an
EchoCanceller derived class. An AudioLayer may now instantiate
implementations of the EchoCanceller. This may be platform specific
compile-time or swapped out at runtime.

Introduces a null echo canceller for testing. As the speexdsp aec
is not currently functional, the null echo canceller is replaced
as the default implementation.

GitLab: #454
Change-Id: I169f1e9758afbed884fc42d9d78a69ce28d12fe2
2021-03-15 16:58:58 -04:00
5d0247d275 contrib: add webrtc-audio-processing @ v0.3.1
Change-Id: Ib7396b12f98947b25bc96605381cbc29594aa1b7
2021-03-15 16:58:37 -04:00
924cd61091 conference: add account preference to enable moderation for all
Gitlab: #453

Change-Id: I9a870b2f930c69fe26432f1f15169d13365e702d
2021-03-09 16:16:59 -05:00
67d85f86cc account: add default moderator preference
Change-Id: I4c30fe6c8c99bdc518c0e81a89eaf5eb3ce2b726
2021-01-15 13:39:06 -05:00
6927411cf4 conference: add kick participant for moderator
Change-Id: Ieb4be786a286ce52501b270e473308ad1fd5ba23
2020-12-10 19:44:50 -05:00
4e5c4c7908 conference: add mute participant for moderator
Change-Id: I371809b140fb1587635131d3a1e6c75ad67d2966
2020-12-10 19:44:50 -05:00
75ec461623 conference: host can add or remove moderator
Change-Id: Idc4c6db249de7247d02c7cabb897d638c69674f3
2020-11-12 09:51:22 -05:00
de7a0a6726 cleanup: remove turn transport
Change-Id: I13245dc4c38090e75450d6cb0f47956e6444ce93
2020-10-27 11:08:47 -04:00
569d44b5f6 src: hooks: remove urlhook feature
This feature is mostly a relicate from SFLPhone and introduced a remote
attack vector abusing the system() function weaknesses.

Provided that "sipEnabled" parameter is on in the remote target's
configuration, a malicious peer calling that remote target could
send SIP messages with a crafted "X-ring-url" string in order to
execute arbitrary shell commands on the target.

Header entry "X-ring-url" content is actually consumed by UrlHook
as arguments for the "x-www-browser" command executed using system().

By adding a shell escape sequence to circumvent existing arguments
sanitizing attempts, the malicious peer could execute any shell command
under remote peer user's identity and access sensitive information
available using its privileges.

Remove that feature altogether and enforce users that are relying on
that feature to migrate to Jami "plugins", which are more suitable
for introducing custom Jami behaviors.

Change-Id: I1d6d07771e2b5a7c7f2cb8fc838821106c0a6708
2020-10-13 12:13:23 -04:00
69d60a4940 Revert "plugin: add editable preference"
This reverts commit 7f21500866.

Reason for revert: API design issue

Change-Id: I89b4bd9f59b95637acb7fd2199a4ccc43b1bda64
2020-09-01 13:20:26 -04:00
7f21500866 plugin: add editable preference
Change-Id: I61c074464e21344b2d7a1d64023f23bd96139c3b
2020-08-31 17:20:53 -04:00
b424a5d0bd recorder: add remote recording indicator
Change-Id: I711a0b2f446f1620d7dff66945bf9295fd8372ac
2020-08-31 16:10:50 -04:00
365a1169fb conference: add informations about rendered video and share with all peers
These informations contains the participants in a conference and their
position in the rendered frame. The description of the conference is
sent via a SIP message with "application/confInfo+json" for mimetype.

Gitlab: #241
Change-Id: I5a3ad81d1d1b8ba9c9ce84e57745a59a747b8e6c
2020-07-31 16:52:53 -04:00
8d40c627e3 video_mixer: support multiple video layouts in conference
This patch aims to improve the conference management for the host.
Now, the host is able to switch between 3 conferences layout:
1. The grid view (actual one) where all participants are shown
at the same height/width
2. The One big/Other in small which show one participant bigger than
the others
3. One participant in big

The daemon's API got two new methods:
+ setConferenceLayout() to switch between these layouts
+ setActiveParticipant() used in the 2 last layouts.

Change-Id: I3c16569e24d1b63331ffe9d79e35790a6ac47a0c
2020-07-14 11:27:04 -04:00
6b0311f38c build: use C++17
Change-Id: I94c88a504ae2a98043be8fd201f95227002d99c4
2020-07-13 07:42:49 -04:00
0b7a978737 plugin: exposing plugins to linux ui
Change-Id: I0919a3a78f4066122773a2ee9ab85d8e406e7e8f
2020-07-07 10:23:57 -04:00
03ed99103d plugin: libarchive and plugins as default for linux
fix preferences set in first plugin loading
small logic changes in libraries loading
related to: https://review.jami.net/c/ring-project/+/14433

Change-Id: I4730f279ee38d337e3ef94dd9562a5dfc1a63c32
2020-06-05 10:17:10 -04:00
b7d4ab38d0 plugin: add plugin to dbus interface
Change-Id: I0bdffd53e9ba9463e3daacbc0641ab82e1ba89dd
2020-06-05 10:17:10 -04:00
f1ff4c3e11 archiver: add libarchive
Change-Id: I2ff7d879de55e18bedcbddce74f743ffe8755ca6
2020-05-26 11:04:10 -04:00
442b6b44c1 accounts: emit signal when an avatar is received in JAMS response
- adds signal <AccountAvatarReceived> for <account_id> with base64
  <photo>
- handles incoming avatar during account authorization response in
  on success callback by emitting <AccountAvatarReceived>

Change-Id: I8b6b9685691e1335b895a12c35ea14b53ec6260c
2020-03-12 15:53:46 -04:00
e40f5facdb dring: add message id in IncomingAccountMessage
Change-Id: I5622a466d0baccf906e6934b748719b2aa3ec37b
2020-03-04 14:13:35 -05:00
623f8082ce media player: initial implementation
This patch adds API for manage video player.
During player initialization it opens file, initialize video
and audio input, starts audio stream if needed.
Initial player state is paused.
It is up to client unpause player, get first frame and pause again
to get image for preview.
Current player functionality is
- play/pause
- seeking
- mute audio

Change-Id: I8cba50e1ab424d5acde9c38214af2cfe51064607
2020-03-02 10:57:17 -05:00
4ec9e1a2bc messages: add isComposing indicator
Change-Id: Ie7d90b5e77d320b53a91a16047a8fe3406591586
2020-02-28 16:07:13 -05:00
c3c15164dd build: link/include with ffmpeg
Gitlab: #54
Change-Id: Ieedfde12a0c9602f8ce664ef99b7205e9899751a
2019-12-20 11:59:17 -05:00
75b134cf17 jamiaccount: split account management
Change-Id: I669bfcc6f0e3f7bd60c56f0046f8701ad14541ce
2019-09-10 17:35:34 -04:00
b16a85a206 manager: add shared asio::io_context
Change-Id: Id3c5b959811b678df850a7025a7008e1591aaf0e
2019-09-10 12:50:56 -04:00
2100815f51 namedirectory: replace restbed by restinio
Depends-On: If43bab09e0d209aef1e92217d145a22f0cdab466
Change-Id: Ic8f55919f82c2e2ab088d4bc38814c99e1006062
2019-09-10 11:16:07 -04:00
fd970d5e2f Revert "manager: add shared asio::io_context"
This reverts commit 36dfd11f52.

Reason for revert: temporary win32 incompatibility

Change-Id: Ib6718b2427cf4e0f3d2f456c4722830232b850cd
2019-09-06 16:27:03 -04:00
36dfd11f52 manager: add shared asio::io_context
Change-Id: Iebd54e75d9f7baaa61547dd1e18100a7d88cc807
2019-09-05 17:20:37 -04:00
431cee5d12 recorder: add preferences
Adds whether or not the local video feed should be overlaid on the
remote video feed. Adds a quality setting for the recorder.

Change-Id: I60bd80c6441c7d516120680bebb1acdeb3824c49
2019-08-07 15:05:27 -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
486709d4fd gnutls: use version 3.6.7
Change-Id: I4d6c06d8bda6a2bba817108b1f323afaf27766ba
2019-07-23 16:59:48 -04:00
780a9d5762 build: cleanup
Remove unused build options, flags and defines

Change-Id: I0c25511ade66025427ca0411cf34cfdd73a4bd1f
2019-07-19 14:12:20 -04:00
093537a6ff peerdiscovery: add getNearbyPeers() function
Change-Id: Ifcf2c2b3676a1903f16818e889dac6ca85a5aa0a
Reviewed-by: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
2019-06-11 16:21:45 -04:00
6af72289f8 rename ringdht to jamidht
Change-Id: Id5673ba9f2ec519070cc112685dea5ced94c3b38
2019-04-17 10:15:15 -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
a89cf39255 dring: add cancelMessage API
Change-Id: Id99a8d8a3af3ef59d52a3267e0f44262c6df17f3
2019-04-02 13:33:18 -04:00
3d4724cdc1 project: rename package to "jami", migrate config files
Change-Id: I5c7d429bd32aa22bd4c7ad0914a7581176c2ccdd
2019-03-25 01:22:54 -04:00
36bee9bb72 build, contrib: remove pcre
Change-Id: Ifc2c224afe9d3de9d52ecc1d66d7d81ccec524ac
2019-03-11 13:08:00 -04:00
dda1f61d22 video: add rotation
Change-Id: I0b760e4ae32ab372cef49ef9c2120e722e041ef1
2019-03-07 16:27:29 -05:00
c52e332b0b audio: add audio meter
Adds a signal that sends the linear RMS level for a given ring buffer.
The signal must be turned on via the API and can be turned off when
needed.

Adds an audio preview so the mic can be read. Call startAudioDevice and
stopAudioDevice to initialize and stop the audio layer.

Change-Id: I6a71ef87ee805a6d4bfa824fa901dd638e8cbd65
2019-02-01 10:10:02 -05:00
94c8f4b616 accel: add signals when toggled
Preemptively adds signal for hardware encoding so version won't have to
be bumped again.

Change-Id: Ie3b828671fab3628853b85a2a8259200e9a809c0
Gitlab: #55
2019-01-16 13:26:09 -05:00