Commit Graph

41 Commits

Author SHA1 Message Date
Edoardo Spadolini
507f9b3392 Follow SSL Cipher Server Preference 2015-01-02 23:40:15 +01:00
Falk Seidel
2e29d49a53 Welcome to 2015 2014-12-31 11:28:38 +01:00
Alexey Sokolov
d56621f9f6 Fix modperl startup 2014-12-25 16:36:55 +00:00
Alexey Sokolov
72ca970731 Make default ciphers a bit better 2014-12-23 00:57:59 +00:00
Alexey Sokolov
8930fc4d7a Don't break IRC control characters in some encodings
Fix #577
2014-12-21 17:09:59 +00:00
Alexey Sokolov
4a5fddce7e Fix typo in comment 2014-12-15 15:52:51 +00:00
Alexey Sokolov
04148b970b Use random DNS result instead of choosing the same every time.
Fix #133
2014-12-15 14:25:03 +00:00
Alexey Sokolov
60ec923d1f Fix calculation of SSL fingerprints 2014-12-14 09:58:00 +00:00
Alexey Sokolov
e535e62390 Fix connection of SSL clients to ZNC 2014-12-02 21:42:28 +00:00
Alexey Sokolov
4442af724f Validate TLS certificate of IRC server.
Fix #156
2014-11-29 14:25:15 +00:00
Alexey Sokolov
28bee5aff3 Honor SSL ciphers in ZNC->Server connections 2014-11-26 22:31:12 +00:00
J-P Nurmi
b759c68847 Config option for SSL protocols (resolves #720)
ZNC currently disables SSLv2 and SSLv3 by default. To keep the ZNC
defaults (recommended, may change in the future versions) and for
example disable TLSv1 in addition, specify in the global config
section:

    SSLProtocols = -TLSv1

Available (case-insentive) values are:

    All, SSLv2, SSLv3, TLSv1, TLSv1.1, TLSv1.2

A non-prefixed "absolute" value overrides the ZNC defaults:

    SSLProtocols = TLSV1 +TLSv1.1 +TLSv1.2
2014-11-06 23:49:49 +01:00
J-P Nurmi
54e8b62b87 Fix #719: Disable SSL compression 2014-11-06 20:41:49 +01:00
J-P Nurmi
6ae9a439b2 Fix non-SSL build 2014-11-06 20:41:49 +01:00
J-P Nurmi
3d57ccb738 Resolve #621: Config option for allowed SSL ciphers
In the global section, for example:

    SSLCiphers = ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!aNULL:!MD5:!DSS

https://www.openssl.org/docs/apps/ciphers.html
https://hynek.me/articles/hardening-your-web-servers-ssl-ciphers
2014-10-26 14:59:36 +01:00
J-P Nurmi
954f22ccc0 Disable insecure SSLv2 & SSLv3 protocols (ref #621) 2014-10-26 11:58:33 +01:00
J-P Nurmi
d98094f564 Update Csocket to 71dac61
Csocket has received a bunch of const correctness fixes. Notice that
the signature of one virtual method, Csock::ConvertAddress(), has
changed => CZNCSock has been updated accordingly.
2014-10-02 19:51:41 +02:00
Falk Seidel
f19b4caa43 Welcome to 2014 - year 10 with ZNC 2013-12-31 10:10:55 +01:00
Alexey Sokolov
b2dcad5fd4 Change ZNC license to Apache 2.0
The following people agreed with the change, in alphabetical order:
(people who approved in several ways are listed only once)
By email:
- Adam (from Anope)
- Austin Morton
- Brian Campbell
- Christian Walde
- Daniel Holbert
- Daniel Wallace
- Falk Seidel
- Heiko Hund
- Ingmar Runge
- Jim Hull
- Kyle Fuller
- Lee Aylward
- Martin Martimeo
- Matt Harper
- Michael J Edgar
- Michael Ziegler
- Nick Bebout
- Paul Driver
- Perry Nguyen
- Philippe (cycomate)
- Reuben Morais
- Roland Hieber
- Sebastian Ramacher
- Stefan Rado
- Stéphan Kochen
- Thomas Ward
- Toon Schoenmakers
- Veit Wahlich
- Wulf C. Krueger

By IRC:
- CNU
- Jonas Gorski
- Joshua M. Clulow
- Prozac/SHiZNO
- SilverLeo
- Uli Schlachter

At https://github.com/znc/znc/issues/311 :
- Alexey Sokolov
- Elizabeth Myers
- flakes
- Jens-Andre Koch
- Jyzee
- KindOne/ineedalifetoday
- Lee Williams
- Mantas Mikulėnas
- md-5
- Reed Loden

At the last few pull requests' comments:
- Allan Odgaard
- Jacob Baines
- Lluís Batlle i Rossell
- ravomavain
- protomouse

The following commits' authors didn't respond:
Trivial changes:
- f70f1086fd
- 4ca8b50e45

The changes which are not presented in master anymore:
- 5512ed2ea0
- 960a4498f7
- 0f739de2c0
- 7f53cc810b

Fix #311
Fix #218
2013-06-14 00:43:34 +04:00
Uli Schlachter
53c579b296 CJob: Add a way to do stuff on the main thread
This just moves the pipe from the socket code to the thread pool. However, now
all CJobs can use this and there is a single place for them to get deleted.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2013-03-15 11:58:27 +01:00
Uli Schlachter
75f2e3fa41 Add a generic threads abstraction
This should make it easier to work with threads. It provides classes for mutexes
and condition variables. Additionally, there is a special CMutexGuard that
automatically unlocks the mutex on destruction and a CThreadPool class.

This thread pool is used to replace the thread pool in the sockets code.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2013-03-15 11:58:22 +01:00
KindOne
2db7307ac3 Remove unneeded headers. 2013-03-08 01:47:57 +07:00
Un1matr1x
3a34593359 The same procedure as last year, Miss sophie?
Same procedure as every year, James.
2012-12-31 12:44:31 +01:00
Kyle Fuller
67299ebfa8 Fix a bunch of conversion warnings #197 2012-08-14 19:31:14 +07:00
Alexey Sokolov
cebc093254 Per-network bind hosts.
Fix #147
2012-07-19 00:59:41 +07:00
Alexey Sokolov
6bf774d853 Use INET6_ADDRSTRLEN instead of magic number 40.
Also 40 is too small, the string can be longer.
2012-04-18 21:34:23 +07:00
Alexey Sokolov
2f853bee61 A bit more debug output for tdns 2012-03-24 00:36:13 +07:00
Uli Schlachter
1dd8d9bf3e Block all signals in DNS threads
A DNS thread should never handle any kind of signal. The main thread is
responsible for handling signals and it does so without any kind of locking.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-02-19 12:26:19 +01:00
Uli Schlachter
252e6d7151 Threaded DNS: Handle spurious wakeups
As DarthGandalf noticed, POSIX allows spurious wakeups from pthread_cond_wait.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-02-19 12:13:25 +01:00
Uli Schlachter
0bdb18a427 Threaded DNS: Use a thread pool
When a DNS thread is done with its lookup, instead of existing immediately, it
now waits for another DNS lookup to do instead. This avoids the cost of
starting/stopping threads all the time.

To make sure that (for whatever reason) the number of waiting threads doesn't
get too high, threads exit if there are more than two DNS threads idling around
with nothing to do.

Fixes #132.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-02-14 20:28:28 +01:00
Uli Schlachter
233897b3a8 threaded DNS: Remove an unneeded function
This inlines the function into its only caller.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-02-04 14:15:52 +01:00
Uli Schlachter
94c7b04245 Threaded DNS: Remove TDNS mutex
POSIX actually guarantees for us that this white is atomic and thus a partial
write is not allowed.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-02-04 14:15:52 +01:00
Uli Schlachter
beacc0180c TDNS: Fix a use-after-free-race-with-threads
Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-01-19 19:41:21 +01:00
Alexey Sokolov
937998d4a5 Merge branch 'master' into tdns 2012-01-15 13:12:28 +07:00
Alexey Sokolov
ff8065ed32 TDNS: Fix few incompabilities with last Csocket. 2012-01-15 13:11:56 +07:00
Uli Schlachter
c87e7cf5ba Update Csocket to e00323f9f18
This breaks API for Csock::SockError()!

Signed-off-by: Uli Schlachter <psychon@znc.in>
2012-01-14 11:33:38 +01:00
Un1matr1x
73270ff023 Welcome in 2012 2012-01-01 09:30:19 +01:00
Alexey Sokolov
717d0596e3 Use threads for resolving DNS.
Drop support for c-ares. Though Csocket still supports it, ZNC's
configure script doesn't enable it anymore.

This should fix big brokenness of c-ares library, which tried to
connect via IPv6 even when IPv6 is disabled on the system.

Also should fix github issue #37
2011-12-27 00:29:51 +07:00
Kyle Fuller
200940756b Update Csocket to d7206c6aa88bd7988f 2011-10-21 01:40:36 +00:00
Alexey Sokolov
2c1ca45353 Merge branch 'headers' 2011-09-28 20:15:20 +07:00
Alexey Sokolov
afeab4a9e6 Move core .cpp files to src/ 2011-09-23 03:33:13 +07:00