Commit Graph

653 Commits

Author SHA1 Message Date
wolmi
7bbe78a5f2
Merge branch 'master' into prometheus 2020-04-28 12:56:33 +02:00
Mészáros Mihály
ded19f58c8 do not require to set cli password if no-cli 2020-04-28 11:14:08 +02:00
Mészáros Mihály
991a82e104
Merge branch 'master' into master 2020-04-28 09:47:20 +02:00
Mészáros Mihály
1e4456ea92
Merge pull request #506 from dbrgn/rename-prod
Rename "prod" config option to "no-software-attribute"
2020-04-28 09:18:51 +02:00
Mészáros Mihály
24346fbaba
Merge pull request #522 from weberhofer/master
Drop of supplementary group IDs
2020-04-28 09:06:57 +02:00
Mészáros Mihály
fb8dc8a736 Change DH key size default from 1066 to 2066 2020-04-15 22:07:26 +02:00
Johannes Weberhofer
acbf7e15c9
Drop of supplementary group IDs
Fix related to POS36-C and rpmlint error "missing-call-to-setgroups-before-setuid".
2020-04-11 10:33:55 +02:00
Miquel Ortega
fb3bd0d353 Added checks to make prometheus optional 2020-04-02 17:28:21 +02:00
Miquel Ortega
aeb0474344 Added some comments 2020-04-02 10:45:32 +02:00
Miquel Ortega
d485088409 Added metrics for total traffic 2020-04-02 10:35:50 +02:00
Miquel Ortega
3e22d7e199 Refactor to use only one function to set metrics 2020-04-02 10:26:01 +02:00
Miquel Ortega
9ed631c495 Prometheus server init and first metrics 2020-04-02 00:51:42 +02:00
Miquel Ortega
b9802690d1 First code to implement prometheus metrics 2020-04-02 00:49:28 +02:00
Danilo Bargen
520e172b22 Rename "prod" config option to "no-software-attribute"
As discussed in https://github.com/coturn/coturn/pull/478, if the
parameter only controls whether or not to send the software attribute
and not other production-relevant configurations, it should be named
accordingly.

The old --prod configuration option still works, but is now deprecated
and undocumented.
2020-03-13 11:03:05 +01:00
Mészáros Mihály
4722697645 Fix compiler warnings
* Changed type from int to size_t to avoid warning
  warning: comparison between signed and unsigned integer expressions
* Fixed string truncation warning
2020-03-03 15:26:01 +01:00
Mészáros Mihály
c6bca3cef7 Merge branch 'http-server-fixes' 2020-02-19 07:49:05 +01:00
Mészáros Mihály
c534eaef41 Merge branch 'input-validation'
Merge PR #472
2020-02-18 14:46:11 +01:00
Mészáros Mihály
79361c170f Merge branch 'fips' 2020-02-18 14:36:37 +01:00
Mészáros Mihály
e09bcd9f7a Fix: CVE-2020-6062 / TALOS-2020-0985 2020-02-18 12:32:36 +01:00
Mészáros Mihály
51a7c2b9bf Fix: CVE-2020-6061/TALOS-2020-0984 2020-02-17 10:34:56 +01:00
Bertold Van den Bergh
ace903fd07 Add support for loadbalanced TCP connections (haproxy protocol v2) 2020-02-13 01:56:43 +01:00
Mészáros Mihály
fbd79ed560
Merge pull request #466 from chanduthedev/null-check
added null check for second char
2020-02-12 08:02:15 +01:00
Mészáros Mihály
4badbbf018
Merge pull request #470 from FeralInteractive/compiler-fixes
Compiler warning fixes
2020-02-12 07:56:54 +01:00
Feral Interactive
efa7a47632 Silence shadow variable declaration warning.
'sar', 'value', and 'vlen' already exist in an outer scope and are safe to reuse since they're overwritten before being used again.
2019-11-20 00:03:46 +00:00
Feral Interactive
9b8baa8055 Validate the size of an attribute before returning it to the caller.
Previously this was being done in stun_attr_get_next_str() to check that the previous attribute didn't exceed the size of the underlying buffer, however by that point any maliciously crafted attributes would have already had their chance to attack the caller.
2019-11-19 23:48:41 +00:00
Feral Interactive
14cb1c94e7 Validate the size of the buffer in stun_get_command_message_len_str().
Without this the caller could read off the end of the underlying buffer if it receives a maliciously crafted packet with an invalid header size.
2019-11-19 23:48:34 +00:00
Feral Interactive
353e3b98e6 Add some casts to appease compiler warnings about narrowing. 2019-11-19 23:47:19 +00:00
Feral Interactive
b1990b6130 Liberally apply const where appropriate. 2019-11-19 23:47:11 +00:00
Feral Interactive
763d1f1b9c Fix a memory leak when an SHATYPE isn't supported.
Deallocating `str` happens at the end of the function, so don't skip it when encountering an unsupported SHATYPE.
2019-11-19 23:45:37 +00:00
chanduthedev
25338fa1c0 added null check for second char 2019-11-11 15:01:14 +08:00
Mészáros Mihály
8c8af9ec85
Merge pull request #442 from chanduthedev/ssh-length
Updated incorrect string length check for 'ssh'
2019-10-22 13:17:32 +02:00
Robert Scheck
cfdb99dc72 Append only to log files rather to override them (fixes #416) 2019-10-22 11:40:26 +02:00
chanduthedev
c317a19334 Some more typo's fixed 2019-10-16 13:56:32 +08:00
chanduthedev
9b0e53c18a
Updated incorrect string length check for 'ssh'
ssh length should be 3, but checking for 4. So updated memcmp method to 3 instead of 4.
2019-09-27 14:36:03 +08:00
Phillip Voyle
33b74fdc2a Fix spelling mistake 2019-05-30 14:23:44 +12:00
Byron Clark
0e03fa86df Remove OPENSSL_FIPS wrappers.
Because we're building with a FIPS enabled OpenSSL instead of the FIPS
canister, the resulting build should be usable on both FIPS and non-FIPS
enabled systems. Since we can't rely on building with a FIPS enabled
OpenSSL, defer the check to runtime.
2019-05-26 10:52:51 -06:00
Byron Clark
6b01b6f450 Allow MD5 in FIPS mode.
This is one of those special cases where a non approved cryptographic
algorithm is allowed when operating in FIPS mode. Inform OpenSSL that
this is the case.

In the STUN RFC the long-term credential mechanism requires that the key
used in the HMAC-SHA1 generation be the MD5 of specific values:
https://tools.ietf.org/html/rfc5389#section-15.4

Since this is obfuscating parameters to be used in an approved
cryptographic algorithm, this is allowed usage per the [FIPS 140-2 Implementation Guidance](https://csrc.nist.gov/csrc/media/projects/cryptographic-module-validation-program/documents/fips140-2/fips1402ig.pdf).
See page 81.

Without this change, coturn crashes when trying to set up any long-term
credential mechanism.
2019-05-24 00:16:36 +00:00
Byron Clark
68feff5ca3 Use EVP_MD_CTX instead of MD5_CTX.
Switch to EVP_MD_CTX APIs for MD5 to match how other digest types are
created in this function.
2019-05-24 00:01:52 +00:00
Zebadiah Long
8bf70a1199 added bandwidth usage reporting for bandwidth used by peers 2019-05-21 12:30:12 +02:00
Mészáros Mihály
a409588eda Fix: sqlite disconnect function 2019-05-21 12:23:59 +02:00
Mészáros Mihály
e4f688972d
Merge pull request #382 from islamoglus/feature/boringssl_compatibility
Using SSL_get_version method for BoringSSL compatibility
2019-05-20 14:20:36 +02:00
Mészáros Mihály
dfa95e6af5
Merge pull request #367 from shu-mutou/disconnect-db
Disconnect database gracefully
2019-05-20 11:10:30 +02:00
Mészáros Mihály
ed7121aa90
Merge pull request #392 from islamoglus/bugfix/wrong_fread_usage
Wrong fread usage
2019-05-20 10:58:13 +02:00
Mészáros Mihály
1081bb8239
Merge pull request #390 from ALE-Rainbow/fixMongoBadConnectionStringCrash
fix mongo driver crash when invalid connection string is used
2019-05-20 10:50:17 +02:00
islamoglus
9e16440552 check fread result is 0 or less than expected 2019-05-15 09:51:38 +03:00
islamoglus
59be080af5 wrong fread usage 2019-05-14 17:30:29 +03:00
Thibaut Ackermann
3df99009d3 fix mongo driver crash when invalid connection string is used 2019-05-14 15:25:58 +02:00
Thibaut Ackermann
cf938cd915 fix the webadmin ip permission add/delete sql injection 2019-05-07 11:23:29 +02:00
islamoglus
82fbde71bd using SSL_get_version method for BoringSSL compatibility 2019-04-22 16:00:57 +03:00
Shu Muto
dac67ea046 Disconnect database gracefully
Coturn does not disconnect database properly when shutdown.
This behavior causes accumulation of sockets for database with TIME_WAIT.
Especially, `turnadmin` is recommended to manage userdb,
but use of `turnadmin` from other application or scripts
can run out of socket resource due to above problem.

This patch adds database disconnection when shutdown
for both of `turnserver` and `turnadmin`.

Fixes #366
2019-03-18 15:33:21 +09:00