Commit Graph

86 Commits

Author SHA1 Message Date
Alan Jowett
ce66485ee6 Uses fork/exec to limit memory footprint of ocserv-worker processes
Capture all the required worker process state in a protobuf and
pass to worker via env. Snapshot all config files to ensure ocserv-sm
and ocserv-worker remain in sync. Split ocserv-worker functionality
into it's own executable with minimal dependencies.

Resolves: #285

Signed-off-by: Alan Jowett alanjo@microsoft.com
2020-05-25 08:33:16 +02:00
Nikos Mavrogiannopoulos
7f7bb95f81 .gitlab-ci.yml: fix rpm generation testing when version matches
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-05-16 11:53:35 +02:00
Nikos Mavrogiannopoulos
03b05526c3 tests: check whether ipv6 interface is up
Relates: #301

Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-05-13 06:16:27 +02:00
Nikos Mavrogiannopoulos
350250ea82 worker: allow filtered calls to fail with a trap
This adds a fedora CI run to with filtered calls failing
with a signal in order to detect missing syscalls from our filters.

Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-05-10 21:45:05 +02:00
Nikos Mavrogiannopoulos
4e00087b57 .gitlab-ci.yml: the freebsd system became unavailable
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-05-02 06:10:08 +02:00
Alan Jowett
7e5052782e Remove unused code when --disable-compression is set.
Resolves: #291

Singed-off-by: Alan Jowett <alanjo@microsoft.com>
2020-04-27 09:18:09 -06:00
Alan Jowett
8cac05dac2 Remove unused code when --disable-anyconnect-compat is set.
Resolves: #290

Signed-off-by: Alan Jowett alanjo@microsoft.com
2020-04-26 13:10:10 -06:00
Nikos Mavrogiannopoulos
fd2bd42cb2 .gitlab-ci.yml: corrected kerberos tests
This also corrects the kerberos test script environment
to enable running the test.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2020-04-10 23:06:07 +02:00
Nikos Mavrogiannopoulos
aa9c401cac Prevent clients with a broken GnuTLS version from connecting using DTLS
That prevents clients that send an all-zero DTLS client hello from being
able to establish a connection.

That also introduces the OCSERV_ALLOW_BROKEN_CLIENTS environment variable
which when set to 1 it allows broken clients to connect. This is used
mainly to allow test cases to pass to existing vulnerable systems in our
CI.

Resolves: #277

Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-04-03 12:51:22 +02:00
Nikos Mavrogiannopoulos
88059e43ac .gitlab-ci.yml: no longer test on Centos6
This is a very old platform with old openconnect available in EPEL.
We do not need to keep compatibility with it.

Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-03-16 22:56:18 +01:00
Nikos Mavrogiannopoulos
3544e3ee2b tests: verify environment under Apple clients
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-03-16 22:21:37 +01:00
Nikos Mavrogiannopoulos
c4759fd334 .gitlab-ci.yml: introduce run with -Werror
This allows catching warnings that could have slipped in.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2020-03-12 19:47:50 +01:00
Alan Jowett
b43e782b12 Add support for RFC6750 bearer tokens to ocserv
This permits the validation of OpenID Connect auth tokens OpenID
Connect is an OAuth 2.0 protocol used to identify a resource owner
(VPN client end-user) to a resource server (VPN server) intermediated
by an Authorization server.

Resolves: #240

Signed-off-by: Alan TG Jowett <alan.jowett@microsoft.com>
2020-03-09 21:48:04 +01:00
Nikos Mavrogiannopoulos
6558653c4b .gitlab-ci.yml: include the right build in schedules [ci skip]
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2020-02-26 12:48:10 +01:00
Nikos Mavrogiannopoulos
85108c7598 .gitlab-ci.yml: corrected 'only' use in coverity build
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2020-02-26 12:43:34 +01:00
Nikos Mavrogiannopoulos
91de6c889e Merge branch 'tmp-coverity' into 'master'
.gitlab-ci.yml: coverity jobs only run on schedules

See merge request openconnect/ocserv!138
2020-02-22 23:21:16 +00:00
Nikos Mavrogiannopoulos
bc092793f0 .gitlab-ci.yml: coverity jobs only run on schedules
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-22 23:43:48 +01:00
Nikos Mavrogiannopoulos
c3ff69e7c4 added ubuntu18 build and minor cleanup
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-22 22:43:55 +01:00
Nikos Mavrogiannopoulos
a6994ef1e7 .gitlab-ci.yml: specify the master branch coverity and web pages generation runs
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 23:04:38 +01:00
Nikos Mavrogiannopoulos
613242f343 .gitlab-ci.yml: added epel8 rpm build
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 23:02:55 +01:00
Nikos Mavrogiannopoulos
476638a52a .gitlab-ci.yml: avoid the use of '&&'
gitlab CI will often mask a failure when multiple '&&' are
present.

Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 22:50:00 +01:00
Nikos Mavrogiannopoulos
f4126fa095 .gitlab-ci.yml: change raddb permissions
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 22:45:42 +01:00
Nikos Mavrogiannopoulos
a8d34a80b9 tests: radius: save log on CI failure
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 22:25:13 +01:00
Nikos Mavrogiannopoulos
fc901e03c4 .gitlab-ci.yml: use parallel builds
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-02-13 22:06:22 +01:00
Nikos Mavrogiannopoulos
243c5e9fa2 .gitlab-ci.yml: added centos8 build
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2020-02-11 12:33:39 +01:00
Nikos Mavrogiannopoulos
9bd3c136e1 .gitlab-ci.yml: run jobs on linux only
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
2020-01-26 09:25:44 +01:00
Nikos Mavrogiannopoulos
c9e907c841 tests: replaced docker-based kerberos test case with one that runs in CI
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2019-11-17 14:51:21 +01:00
Nikos Mavrogiannopoulos
a5a1b2d62f .gitlab-ci.yml: added coverity build
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2019-10-23 10:37:46 +02:00
Nikos Mavrogiannopoulos
5247833d91 .gitlab-ci.yml: build rpm as part of the CI process
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-07-01 21:56:03 +02:00
Nikos Mavrogiannopoulos
15380220ac tests: rewrite the radius tests using namespaces
This simplifies the test and makes it runnable in our CI.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-06-03 22:47:23 +02:00
Nikos Mavrogiannopoulos
6cac225203 tests: make ping cmd functional in centos7,6
It requires the '-6' option to be able to function with
IPv6 addresses.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2019-03-12 17:21:17 +01:00
Nikos Mavrogiannopoulos
383c25e239 .gitlab-ci.yml: run code coverage with -O0
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-01-30 19:23:05 +01:00
Nikos Mavrogiannopoulos
385af4e831 .gitlab-ci.yml: ensure gcov scripts are writeable
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-01-20 06:44:29 +01:00
Nikos Mavrogiannopoulos
27c83dcf42 tests: consistently disable isolate-workers in tests
That is to prevent coverage reporting in tests.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-01-20 06:43:47 +01:00
Nikos Mavrogiannopoulos
a67c45099f .gitlab-ci.yml: removed XFAIL from centos6; previous changes seem to fix it
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-01-10 19:30:36 +01:00
Nikos Mavrogiannopoulos
a5502022c2 .gitlab-ci.yml: skip Centos6 tests that fail
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2019-01-06 20:07:53 +01:00
Nikos Mavrogiannopoulos
c9c50909b9 .gitlab-ci.yml: disabled asan job as it conflicts with cwrap tools in F28
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-07-23 21:18:44 +02:00
Nikos Mavrogiannopoulos
4f79db43b6 .gitlab-ci.yml: parallelize make check in fedora build
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-07-20 22:15:42 +02:00
Nikos Mavrogiannopoulos
5a2bed6a58 .gitlab-ci.yml: updated for new debian build name
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-06-26 03:26:13 +02:00
Nikos Mavrogiannopoulos
6bc5da342f .gitlab-ci.yml: updated for new project
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-06-26 03:13:35 +02:00
Nikos Mavrogiannopoulos
ece70b0d6c configure: always work-around brokenness of gnutls_certificate_set_key
That is, instead of requiring the user to explicitly pass --with-broken-gnutls
warn at the end of the configure script.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-05-12 05:20:02 +00:00
Nikos Mavrogiannopoulos
094145bf54 configure: refuse to compile with known dependency issues
In particular require gnutls 3.5.5 which fixes cleanups in
gnutls_certificate_set_key(), or a recent version of
the 3.3.x branch. When forced to use a broken version work-around
issues (at the cost of a memory leak).

Resolves #152

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-05-04 23:21:37 +02:00
Nikos Mavrogiannopoulos
b4bb6c2049 .gitlab-ci.yml: do not use PAM under asan
PAM tests would fail due to address sanitizer not detecting
the stack switches.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-04-14 18:55:10 +02:00
Nikos Mavrogiannopoulos
eb41aa8f45 .gitlab-ci.yml: corrected run of ubsan/asan
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-04-14 14:23:21 +02:00
Nikos Mavrogiannopoulos
017bd414f9 .gitlab-ci.yml: update code coverage
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-04-05 20:09:36 +02:00
Nikos Mavrogiannopoulos
265e30dab7 tests: full-test was moved into traffic test
The new traffic test only requires namespaces and no docker.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-04-05 20:06:27 +02:00
Nikos Mavrogiannopoulos
7b4c1bae5a .gitlab-ci.yml: added ubsan build
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-03-12 21:56:03 +01:00
Nikos Mavrogiannopoulos
dfab7f6e30 Create coverage report and depend on pre-built CI images
It will be made available at:
https://ocserv.gitlab.io/ocserv/coverage/

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-03-12 21:54:44 +01:00
Nikos Mavrogiannopoulos
26bc265652 .gitlab-ci.yml: disabled rawhide build
The fedora image is broken since long time.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
2018-03-02 19:36:18 +01:00
Nikos Mavrogiannopoulos
83d37ace16 .gitlab-ci.yml: rawhide: do not rely on tcp wrappers
They are no longer part of Fedora28.

Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
2018-02-19 16:07:43 +01:00