]>
git.proxmox.com Git - mirror_kronosnet.git/log
Fabio M. Di Nitto [Thu, 16 Nov 2017 16:04:36 +0000 (17:04 +0100)]
[nozzle] cleanup and document nozzle_del_ip
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 15:52:35 +0000 (16:52 +0100)]
[nozzle] cleanup and document nozzle_add_ip
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 15:28:52 +0000 (16:28 +0100)]
[nozzle] re-order functions in order of importance
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 15:23:09 +0000 (16:23 +0100)]
[nozzle] cleanup and document nozzle_set_down
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 15:18:08 +0000 (16:18 +0100)]
[nozzle] cleanup and document nozzle_set_up
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 14:51:18 +0000 (15:51 +0100)]
[nozzle] start to cleanup nozzle_close to be more informative and effective
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 14:21:07 +0000 (15:21 +0100)]
[nozzle] cleanup nozzle_open coding style and return codes
also update the header file for Doxygen man pages
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 13:03:56 +0000 (14:03 +0100)]
[nozzle] rename last tap bits to nozzle
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:52:08 +0000 (13:52 +0100)]
[nozzle] rename API from tap_ to nozzle_
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:51:43 +0000 (13:51 +0100)]
[nozzle] fix pkg-config to point to nozzle
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:48:38 +0000 (13:48 +0100)]
[nozzle] rename struct _iface to nozzle_iface (looks better on public headers)
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:46:19 +0000 (13:46 +0100)]
[nozzle] rename tap_t to nozzle_t
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:44:19 +0000 (13:44 +0100)]
[nozzle] include net/if.h to define IFNAMSIZ instead of redefine
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 12:43:53 +0000 (13:43 +0100)]
[nozzle] add Doxygen header
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 05:41:25 +0000 (06:41 +0100)]
[libnozzle] rename libtap to libnozzle (part 1)
Our fearless Debian maintainer wferi made us aware that TAP is an overloaded
term already and it would be very confusing to add yet another one.
nozzle is a good pick from http://www.thesaurus.com/browse/tap
I am sure lib*cock* would have cause havoc :-)
This commit only rename files and allow builds. The API needs to be renamed too,
but that will come over time with major code cleanup as documented here:
https://trello.com/c/pyEKd4UH/396-libnozzle-make-it-production-ga-ready
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Nov 2017 05:18:57 +0000 (06:18 +0100)]
[libtap] BSD: switch to ioctl to destroy tap devices
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Fri, 10 Nov 2017 15:55:23 +0000 (16:55 +0100)]
[libtap] define IFNAMSIZ for applications that don't need/want to include net/if.h
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 9 Nov 2017 13:24:56 +0000 (14:24 +0100)]
[libtap] update README for BSD
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 9 Nov 2017 07:29:26 +0000 (08:29 +0100)]
[libtap] port to freebsd and fix a bunch of small bugs
- tap_open: do mutex lock only after malloc to avoid deadlock
- fix test suite to increase randomness when testing named tap devices
- remove hardcoded paths to /bin/true /bin/false and /bin/grep
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 7 Nov 2017 10:08:32 +0000 (11:08 +0100)]
[libtap] tests: add better IPv6 private address space randomization
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 7 Nov 2017 08:33:07 +0000 (09:33 +0100)]
[libtap] tests: allow random localhost IPs for testing
- avoids clashing with machine routing
- allows parallel testing
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Christine Caulfield [Thu, 13 Dec 2018 09:59:30 +0000 (09:59 +0000)]
UDP: Cope with EPERM returned from sendmsg/sendto
IPtables can cause -EPERM to be returned from socket sends, so
we need to be able to handle it without going into a spin.
SCTP seems to be unaffected.
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Jan Pokorný [Mon, 3 Dec 2018 10:36:55 +0000 (11:36 +0100)]
[misc] fix a few typos/stylistics
Signed-off-by: Jan Pokorný <jpokorny@redhat.com>
Chen Jingpiao [Thu, 22 Nov 2018 05:23:42 +0000 (13:23 +0800)]
[tests] update error message in api_knet_{addrtostr,strtoaddr}.c
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Thu, 22 Nov 2018 05:20:07 +0000 (13:20 +0800)]
[tests] fix check condition in api_knet_{addrtostr,strtoaddr}.c
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Tue, 27 Nov 2018 02:46:49 +0000 (10:46 +0800)]
clear the errno in each exported API when the call success
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Fabio M. Di Nitto [Tue, 20 Nov 2018 04:31:58 +0000 (05:31 +0100)]
[openssl] fix return type for pthread_self
spotted on freebsd-devel
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Chen Jingpiao [Sun, 11 Nov 2018 06:49:09 +0000 (14:49 +0800)]
[tx] fix tx_uncompressed_packets stats collect in _parse_recv_from_sock
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Tue, 13 Nov 2018 02:24:53 +0000 (10:24 +0800)]
[rx] fix incorrect packet length in _parse_recv_from_links
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Fri, 9 Nov 2018 09:47:17 +0000 (17:47 +0800)]
[tx] remove goto statement to improve readability
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Mon, 12 Nov 2018 02:50:54 +0000 (10:50 +0800)]
Add static qualifier to {compress, crypto, transport}_modules_cmds
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Chen Jingpiao [Mon, 12 Nov 2018 02:30:18 +0000 (10:30 +0800)]
[transports] fix transport_modules_cmd array out of range
Fixes: 18ab4888
Signed-off-by: Chen Jingpiao <jchen@suse.com>
Fabio M. Di Nitto [Wed, 7 Nov 2018 13:27:16 +0000 (14:27 +0100)]
[build] fix supported compiler warning detection
move from AC_PREPROC_IFELSE (strongly discouraged) to AC_COMPILE_IFELSE
our detection system was very weak and recent versions of clang did
show that PREPROC_IFELFE (cpp) would enable warning options that
the compiler does not support (clang).
use a full compilation test to detect what works and what doesn't.
Also expand the warning list to include new / renamed clang options
of equivalents already enabled for older versions of clang and gcc.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Chen Jingpiao [Wed, 31 Oct 2018 08:09:44 +0000 (16:09 +0800)]
tests: fix output message
Fixes: 04537c57 ("[transports] cleanup API calls")
Signed-off-by: Chen Jingpiao <chenjingpiao@gmail.com>
Chen Jingpiao [Mon, 5 Nov 2018 02:22:45 +0000 (10:22 +0800)]
fix typo
Signed-off-by: Chen Jingpiao <chenjingpiao@gmail.com>
Chen Jingpiao [Mon, 5 Nov 2018 02:10:44 +0000 (10:10 +0800)]
man: update XML directory in doxyxml.c
Fixes: 31945b18 ("[man] move libknet man pages and man pages build tools to top level dir")
Signed-off-by: Chen Jingpiao <chenjingpiao@gmail.com>
Christine Caulfield [Mon, 22 Oct 2018 15:10:08 +0000 (16:10 +0100)]
misc: keep covscan happy
covscan complains about is ignoring returns from pthread_mutex_lock()
but in those 2 circumstances we don't have much choice.
This patch just keeps coverity quiet so we don't miss any real bugs it
might find.
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Fabio M. Di Nitto [Mon, 22 Oct 2018 08:40:16 +0000 (10:40 +0200)]
Merge pull request #155 from kronosnet/stable1-proposed
Stable1 proposed
Christine Caulfield [Fri, 19 Oct 2018 12:13:47 +0000 (13:13 +0100)]
links: Don't close loopback link
knet_link_clear_config would incorrectly clear the local
loopback link if the last 'real' link to an external node
was closed. We didn't check the nodeid in the code, just
the link number when clearing the loopback flag.
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Jan Friesse [Mon, 1 Oct 2018 09:39:09 +0000 (11:39 +0200)]
Import key with length not dividable by wrap key block size
Wrapping of the key is standard crypto operation which needs data
aligned to cipher block size, otherwise it fails.
Possible solution is to use a zero filled buffer with size aligned to
required wrap key block size. Private key is copied to the beginning of
the buffer and unwrap operation keeps using only required private key
size.
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Fabio M. Di Nitto [Tue, 11 Sep 2018 14:09:09 +0000 (16:09 +0200)]
[tests] clear errno to avoid incorrect propagation from void fn call
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 11 Sep 2018 14:07:41 +0000 (16:07 +0200)]
[tests] fix select(2) handling (mostly affects slow machines)
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 6 Sep 2018 11:32:06 +0000 (13:32 +0200)]
[threads] make it easier to debug thread startup / stop operations with pretty names
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Jan Friesse [Tue, 4 Sep 2018 16:02:19 +0000 (18:02 +0200)]
Use gitarchive-version for spec file
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Jan Friesse [Mon, 3 Sep 2018 15:43:03 +0000 (17:43 +0200)]
git-version-gen fail on UNKNOWN version
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Jan Friesse [Tue, 4 Sep 2018 15:52:11 +0000 (17:52 +0200)]
Do not match lightweight tags in git-version-gen
Fix leftover from
175b517fd71d999150aa701ec847510490a18a6e which added
matching of lightweight git tags.
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Jan Friesse [Tue, 4 Sep 2018 15:51:21 +0000 (17:51 +0200)]
Support for git archive stored tags
Attempt to solve problem with git archive generated tarballs
(used for example by github when release is downloaded) which are no
longer git tree and (in contrast to officially released tarballs) also
doesn't contain .tarball-version file so git-version-gen script simply
cannot obtain valid version info.
Solution is based on using gitattributes which is instructs git to
replace string in the .gitarchivever file by known ref names.
git-version-gen is enhanced to support this file and tries to parse
any string which looks like "tag: v[0-9][^,)]*". If such string
is found it's used as a version. This file is used as a last attempt and
other methods (.tarball-version, git abbrev) have precedence.
Based on idea stated by Jan Pokorný <jpokorny@redhat.com>.
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Fabio M. Di Nitto [Thu, 16 Aug 2018 06:01:53 +0000 (08:01 +0200)]
[tests] drop arm exceptions as they have been fixed in glibc
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 16 Aug 2018 05:01:29 +0000 (07:01 +0200)]
[tests] cleanup nss memcheck supports
add one more exception for newer nss (spotted on fedora rawhide)
drop FreeBSD excetions as we don't support running under valgrind on BSD
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 7 Aug 2018 09:21:23 +0000 (11:21 +0200)]
Merge pull request #150 from kronosnet/stable1-proposed
stable1-proposed
Fabio M. Di Nitto [Wed, 1 Aug 2018 12:21:38 +0000 (14:21 +0200)]
[threads] use internal array to track status of threads (running/stopped) vs a random sleep()
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Wed, 1 Aug 2018 05:56:21 +0000 (07:56 +0200)]
[tests] don't redefine symbols from the main library
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Mon, 30 Jul 2018 16:15:24 +0000 (18:15 +0200)]
[tests] adds more overrides for fedora28/arm/glibc
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Mon, 30 Jul 2018 14:12:18 +0000 (16:12 +0200)]
[handle] reduce usage of handle_config_mutex to wrap only global lib init
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Mon, 30 Jul 2018 04:19:56 +0000 (06:19 +0200)]
[logging] report error in case logging buffer is bigger than PIPE_BUF
See https://github.com/kronosnet/kronosnet/pull/148
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 29 Jul 2018 04:31:45 +0000 (06:31 +0200)]
[handle] drop init_lock_done as it was used only by locked version of log_msg
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 29 Jul 2018 04:28:11 +0000 (06:28 +0200)]
[logging] drop locking inside log_msg (part 1)
looking at the code, there are only few calls to log_msg happening outside
of locking context (error reports when failing to grab the lock).
Everything else appears to be safe.
drop the attempt to lock inside log_msg for now, part 2 will address those
few calls that can happen outside of locking context.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 29 Jul 2018 03:59:20 +0000 (05:59 +0200)]
[handle] drop call to log_msg that would have no effect
logging is not setup yet at this stage and we can't log just yet.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 17 Jul 2018 11:02:08 +0000 (13:02 +0200)]
[tests] ignore nss internal memory leak (3.38+) non recurring
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Tue, 17 Jul 2018 04:42:00 +0000 (06:42 +0200)]
[tests] reference correct library in memcheck comments
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Fri, 8 Jun 2018 04:59:54 +0000 (06:59 +0200)]
[tests] add another lzma exception
spotted on Debian Experimental, the latest toolchain appears to add
full path to objects and valgrind would generate an error.
add a generic catch-all path exception.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Ferenc Wágner [Tue, 24 Apr 2018 18:10:49 +0000 (20:10 +0200)]
coding style: add parentheses after the sizeof operator
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 16:56:34 +0000 (18:56 +0200)]
log_msg: no point in putting NL after the final NUL
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 16:18:20 +0000 (18:18 +0200)]
knet_log_msg: fix documentation: the closing newline is added by flush_logs
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 16:11:25 +0000 (18:11 +0200)]
_logthread: while loop instead of goto
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 16:03:21 +0000 (18:03 +0200)]
_logthread: select() returns the number of set bits, as an int
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 14:17:59 +0000 (16:17 +0200)]
flush_logs: don't ever print past the message buffer
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 14:14:14 +0000 (16:14 +0200)]
flush_logs: while loop instead of goto
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 14:02:58 +0000 (16:02 +0200)]
flush_logs: a for loop is more straightforward here
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 13:59:22 +0000 (15:59 +0200)]
flush_logs: don't repeat the type of msg
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 13:56:34 +0000 (15:56 +0200)]
flush_logs: the reads will overwrite the entire msg structure
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 23 Apr 2018 13:53:33 +0000 (15:53 +0200)]
flush_logs: remove redundant condition
The read loop is always entered, resetting len and returning from the
function if it isn't greater than 0.
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Fabio M. Di Nitto [Mon, 23 Apr 2018 05:30:43 +0000 (07:30 +0200)]
Merge pull request #145 from kronosnet/stable1-proposed
stable1-proposed
Fabio M. Di Nitto [Fri, 20 Apr 2018 12:36:12 +0000 (14:36 +0200)]
[crypto] NSS_NoDB_Init: the parameter is reserved, must be NULL
Thanks to Feri for spotting it in corosync
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Fri, 20 Apr 2018 04:19:13 +0000 (06:19 +0200)]
[crypto] improve checks around RX packet size
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Thu, 19 Apr 2018 03:04:16 +0000 (05:04 +0200)]
Merge pull request #140 from kronosnet/stable1-proposed
stable1-proposed
Ferenc Wágner [Mon, 26 Mar 2018 08:56:36 +0000 (10:56 +0200)]
build: look for source_epoch in srcdir
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Sun, 25 Mar 2018 20:07:25 +0000 (22:07 +0200)]
build: check for SOURCE_DATE_EPOCH before turning to Git for an epoch
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Fabio M. Di Nitto [Tue, 13 Mar 2018 14:44:11 +0000 (15:44 +0100)]
[build] fail and provide proper error if source tree version is unknown
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Fri, 23 Mar 2018 14:46:16 +0000 (15:46 +0100)]
build: git -C is a relatively new option, avoid it
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Fri, 23 Mar 2018 14:33:53 +0000 (15:33 +0100)]
build: accomodate to the actual date utility
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Thu, 22 Mar 2018 13:26:20 +0000 (14:26 +0100)]
spec: use the source epoch here as well
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Thu, 22 Mar 2018 13:18:18 +0000 (14:18 +0100)]
man: use new doxyxml date options to build man pages
Based on Fabio's original patch.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Christine Caulfield [Thu, 15 Mar 2018 14:08:20 +0000 (14:08 +0000)]
man: Add date & year options to doxyxml
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Ferenc Wágner [Thu, 22 Mar 2018 11:12:33 +0000 (12:12 +0100)]
build: distribute the source_epoch file
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Thu, 22 Mar 2018 09:29:07 +0000 (10:29 +0100)]
build: determine SOURCE_EPOCH during configuration
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Fabio M. Di Nitto [Mon, 26 Feb 2018 03:44:07 +0000 (04:44 +0100)]
[compress] extend check to compare end buffer data
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 25 Feb 2018 08:24:49 +0000 (09:24 +0100)]
[compress] update valgrind exception file to match new lzma entry points
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 25 Feb 2018 07:23:49 +0000 (08:23 +0100)]
[compress] delegate compress_level validation to compress libraries
- make val_level internal api call optional
- keep lzo2 val_level around due to the specific nature of compress_level values
- add internal compress_lib_test to do a round-robin (compress/decompress) check with provided values
- drop unnecessary val_level checks around
- update internal compress API include file
- adjust api_knet_handle_compress test to use a known bad value for zlib validation
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 25 Feb 2018 05:02:49 +0000 (06:02 +0100)]
[tx/rx] improve error checking when running external code
libknet cannot guarantee that the dst_host_filter is sane nor that it cannot
be exploited to return garbage to knet.
there is an infinitesimal possibility that, if the plugin returns total crap,
knet could crash by trying to access out-of-bound memory.
Prevent that by adding specific checks both in TX/RX.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Sun, 25 Feb 2018 04:31:46 +0000 (05:31 +0100)]
Merge pull request #116 from kronosnet/stable1-proposed
stable1-proposed fixes
Fabio M. Di Nitto [Fri, 23 Feb 2018 15:41:08 +0000 (16:41 +0100)]
[build] fix ChangeLog generation in release tarball
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Ferenc Wágner [Mon, 19 Feb 2018 08:41:45 +0000 (09:41 +0100)]
Indicate new API call in libtool version info
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Mon, 19 Feb 2018 08:53:53 +0000 (09:53 +0100)]
build: provide -version-info directly instead of -version-number
The info components carry the real OS-independent library version
information, from which the version number is computed differently
on different systems. According to the libtool manual "new projects
should use the -version-info flag instead".
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Ferenc Wágner [Sun, 18 Feb 2018 17:19:39 +0000 (18:19 +0100)]
New API function: knet_handle_new_ex() taking handle flags
For now, the only supported flag is KNET_HANDLE_FLAG_PRIVILEGED,
which is also the default in knet_handle_new().
The tests are adapted to switch this flag off, which makes them pass
in default environments without privileges.
Signed-off-by: Ferenc Wágner <wferi@debian.org>
Christine Caulfield [Mon, 19 Feb 2018 14:13:41 +0000 (14:13 +0000)]
UDP: Don't keep retrying send if we get EINVAL
UDP can return EINVAL if the route is down or not configured, this can
cause knet to 'spin' (well, ish, there is a usleep in there).
With this patch in place knet doesn't hog the CPU anywhere near so much
(and it does recover if the link returns).
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Christine Caulfield [Mon, 19 Feb 2018 11:30:25 +0000 (11:30 +0000)]
doxyxml: Use overridden XML_DIR for reading structures
Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
Fabio M. Di Nitto [Mon, 19 Feb 2018 05:07:54 +0000 (06:07 +0100)]
[man] fix path to stamp file
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Mon, 19 Feb 2018 05:05:16 +0000 (06:05 +0100)]
[man] move kronosnetd man pages
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
Fabio M. Di Nitto [Mon, 19 Feb 2018 04:59:48 +0000 (05:59 +0100)]
[man] move libknet man pages and man pages build tools to top level dir
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>