Run reason: Pull request #486 updated
Total runtime: 4 min 41 sec
Split logs: https://ci.kronosnet.org/job/kronosnet/job/kronosnet-pipeline/job/PR-486/10…
Full log: https://ci.kronosnet.org/job/kronosnet/job/kronosnet-pipeline/job/PR-486/10…
Duplicate job killed: kronosnet/kronosnet-pipeline/PR-486 (9)
Please report the following errors to your friendly local Jenkins admin (though they have probably already seen them and are already panicking).
Exception caught on centos-9-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-12-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-13-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-testing-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-42-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-power9-ppc64le during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-13-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-14-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-15-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-coverity-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-power9-ppc64le during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-coverity-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-coverity-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-power9-ppc64le during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-s390x during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-22-04-lts-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-24-04-lts-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-25-10-x86-64 during voting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on alpine-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-experimental-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-unstable-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-power9-ppc64le during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-s390x during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-devel-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on openindiana-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-devel-x86-64 during nonvoting_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on alpine-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on alpine-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-12-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-12-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-13-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-13-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-experimental-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-experimental-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-testing-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-testing-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-unstable-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on debian-unstable-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-42-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-42-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-power9-ppc64le during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-power9-ppc64le during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-power9-ppc64le during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-power9-ppc64le during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-13-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-13-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-14-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-14-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-15-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-15-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-devel-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on freebsd-devel-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on openindiana-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on openindiana-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-power9-ppc64le during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-power9-ppc64le during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-power9-ppc64le during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-power9-ppc64le during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-s390x during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-s390x during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-22-04-lts-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-22-04-lts-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-24-04-lts-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-24-04-lts-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-25-10-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-25-10-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-devel-x86-64 during nonvoting-clang: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on ubuntu-devel-x86-64 during nonvoting-clang_debug: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-9-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on centos-10-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-42-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-power9-ppc64le during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-43-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-power9-ppc64le during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on fedora-rawhide-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-power9-ppc64le during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-power9-ppc64le during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-s390x during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-x86-64 during buildrpms: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-8-coverity-x86-64 during covscan: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-9-coverity-x86-64 during covscan: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Exception caught on rhel-10-coverity-x86-64 during covscan: org.jenkinsci.plugins.workflow.steps.FlowInterruptedException:
Branch: refs/heads/misc-bugfixes
Home: https://github.com/kronosnet/kronosnet
Commit: 2c59a8853e2bafd38a122e7ac5037672dc8633af
https://github.com/kronosnet/kronosnet/commit/2c59a8853e2bafd38a122e7ac5037…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-27 (Wed, 27 May 2026)
Changed paths:
M libknet/tests/Makefile.am
A libknet/tests/int_defrag_edge_cases.c
Log Message:
-----------
[tests] add defragmentation edge cases test suite
Add new int_defrag_edge_cases_test that validates critical defragmentation
buffer management scenarios not covered by existing tests.
Test scenarios:
1. Last fragment arriving first - validates special buffer positioning
at KNET_MAX_PACKET_SIZE - len offset, last_first flag handling, and
fragment relocation when packet completes. Tests asymmetric MTU with
fragments in order [3/3, 1/3, 2/3] and verifies data integrity across
all fragments (280 bytes total with distinct payloads 'A', 'B', 'C').
2. Buffer exhaustion and reclamation - validates window-based reclamation
when all 32 defrag buffers are filled with incomplete packets. Sends
new complete packet with distant sequence number (9000 vs 2000-2031)
triggering reclamation of all out-of-window buffers. Verifies data
integrity with no corruption from old buffer data in new packet.
3. Fragment data overwrite protection - validates correct assembly of
large fragmented packets without buffer overflow. Test case 1 sends
100 fragments × 500 bytes (50,000 bytes total), test case 2 sends
50 fragments × 1,300 bytes (65,000 bytes approaching KNET_MAX_PACKET_SIZE).
Each fragment filled with its index number and verified on assembly.
4. Duplicate fragment handling - validates that duplicate fragments (same
sequence number and fragment index) are silently rejected without
corrupting the buffer. Sends frag 1/2, frag 1/2 (duplicate with different
data), frag 2/2 and verifies only one correct packet is delivered with
original fragment data preserved.
5. Maximum realistic fragments - validates fragment map can handle high
fragment counts (100 fragments, 500 bytes each = 50,000 bytes total).
PCKT_FRAG_MAX (255) is theoretical limit, but realistic max is determined
by min_mtu. Tests worst-case scenario with min MTU ~550 bytes.
6. Single fragment packets (1/1) - validates degenerate case where packets
are marked as fragmented but contain only one fragment. Sends 5 packets
of 200 bytes each, all marked as 1/1, and verifies correct delivery
without unnecessary defragmentation overhead.
7. Interleaved fragment assembly across wraparound - validates concurrent
assembly of multiple fragmented packets with fragments arriving in
interleaved order across sequence number wraparound boundary. Sends
4 packets (seq 65534, 65535, 0, 1) with all first fragments, then
completes them in reverse order (1→0→65535→65534). Verifies all packets
received correctly with no cross-contamination between defrag buffers.
8. Zero-payload fragments - validates defensive handling of zero-length
fragments (packet injection attacks, corrupted packets). Skipped on
FreeBSD/OpenIndiana (BSD kernel does not deliver 0-byte SEQPACKET
messages). On Linux: 2-fragment, 3-fragment, and single-fragment
zero-payload tests verify correct packet delivery and buffer management.
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
Commit: d9d68f0653107271f010e6ab689e0c4e608feb91
https://github.com/kronosnet/kronosnet/commit/d9d68f0653107271f010e6ab689e0…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-27 (Wed, 27 May 2026)
Changed paths:
M libknet/tests/Makefile.am
A libknet/tests/int_buffer_management.c
Log Message:
-----------
[tests] add defragmentation buffer management test suite
Add new int_buffer_management_test that validates dynamic defragmentation
buffer allocation, growth, shrinking, and reuse scenarios.
Test scenarios:
1. Dynamic buffer growth - validates automatic buffer reallocation when
all defrag buffers are in use. Fills all 32 initial buffers with
incomplete packets (fragment 1/2 only), then sends one additional
packet to trigger growth. Verifies buffer allocation doubles from
32 to 64 and packet reception works correctly after reallocation.
2. Buffer reuse after reclamation - validates that reclaimed buffers
are properly cleared before reuse, preventing data leakage. Sends
incomplete packet at seq 5000 filled with 'X', then complete packet
at seq 10000 (distance 5000 > KNET_CBUFFER_SIZE 4096) triggering
reclamation. Verifies new packet contains only 'Z' with no trace of
'X', then reuses same buffer with new packet 'M'+'N' and confirms
no leakage.
3. Dynamic buffer shrinking - validates automatic buffer deallocation
when usage stays below threshold. Starting from 64 buffers (grown in
test 1), clears all incomplete packets to achieve low usage, reduces
defrag_bufs_usage_samples from 255 to 10 for faster testing, then
sends complete packets over 10+ sample periods (1 second each) to
trigger shrinking. Verifies buffers halve from 64 to 32 and packet
reception works correctly after shrinking.
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
Compare: https://github.com/kronosnet/kronosnet/compare/98c97c75f1e4...d9d68f065310
To unsubscribe from these emails, change your notification settings at https://github.com/kronosnet/kronosnet/settings/notifications
Branch: refs/heads/misc-bugfixes
Home: https://github.com/kronosnet/kronosnet
Commit: 98c97c75f1e4b36707b373a00b44e78afa0d261b
https://github.com/kronosnet/kronosnet/commit/98c97c75f1e4b36707b373a00b44e…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-27 (Wed, 27 May 2026)
Changed paths:
M libknet/tests/int_defrag_edge_cases.c
Log Message:
-----------
[tests] skip Test 8 zero-payload fragments on FreeBSD/OpenIndiana
FreeBSD and OpenIndiana/illumos SEQPACKET socketpair implementations
do not deliver zero-byte messages even when marked with MSG_EOR.
Root cause: BSD's uipc_soreceive_stream_or_seqpacket() checks
sb->sb_acc < sb->sb_lowat before checking the M_EOR flag. For 0-byte
messages, sb->sb_acc=0 and sb->sb_lowat=1 (default), causing it to
return EWOULDBLOCK without ever delivering the message.
Linux SEQPACKET uses datagram semantics (unix_dgram_recvmsg) which
correctly delivers 0-byte messages.
The knet defragmentation code handles zero-payload fragments correctly
on all platforms. This is purely a BSD kernel socketpair limitation.
Test 8 validates defensive programming against packet injection attacks
or corrupted packets. Skipping it on BSD platforms does not indicate
a knet bug.
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
To unsubscribe from these emails, change your notification settings at https://github.com/kronosnet/kronosnet/settings/notifications
Branch: refs/heads/misc-bugfixes
Home: https://github.com/kronosnet/kronosnet
Commit: 3532a06f4d790eeccb9e191b152a3e043fcfc61c
https://github.com/kronosnet/kronosnet/commit/3532a06f4d790eeccb9e191b152a3…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-26 (Tue, 26 May 2026)
Changed paths:
M libknet/tests/Makefile.am
A libknet/tests/int_seq_wraparound_stress.c
Log Message:
-----------
[tests] add comprehensive sequence number wraparound stress test
Add new int_seq_wraparound_stress_test that validates sequence number
wraparound handling and defragmentation buffer management under realistic
packet loss scenarios.
Test scenarios:
1. Normal sequential with packet loss - validates basic packet handling
with gaps in sequence numbers. Sends seq 1000-1006 with some complete
(both fragments), some lost (no fragments), and some incomplete (only
one fragment). Verifies only complete packets are delivered (4/7).
2. Wraparound boundary with packet loss - validates wraparound crossing
from seq 65533 to seq 4 with mixed complete/incomplete/lost packets.
Tests special case where sequence numbers wrap from SEQ_MAX (65535)
to 0. Verifies 5 complete packets delivered correctly across boundary.
3. Large sequence jump (> KNET_CBUFFER_SIZE) - validates buffer clearing
logic when sequence gap exceeds circular buffer size. Sends seq 5000,
then jumps to 10000 (5000 packet gap > KNET_CBUFFER_SIZE 4096),
triggering buffer reclamation. Verifies all complete packets delivered.
4. Out-of-order fragment delivery - validates fragment assembly when
fragments arrive in reverse order (frag 2 before frag 1) for same
sequence number. Sends 3 packets with mixed fragment ordering and
verifies all packets assembled correctly regardless of fragment order.
5. Out-of-order complete packet delivery - validates handling when
complete packets arrive with out-of-order sequence numbers. Sends
seq 1000, 1001, 999 (last one arrives late) and verifies all 3
packets are delivered.
6. Extreme packet loss beyond receive window - validates recovery from
massive packet loss exceeding KNET_CBUFFER_SIZE. Creates incomplete
packets at seq 30000-30002, then jumps to 35000 (5000 gap), tests
buffer clearing and continued operation. Verifies 5 complete packets.
7. Wraparound with extreme packet loss - validates wraparound combined
with massive loss. Sends seq 60000-60001, then jumps to 100-103
(gap = 5636 packets wrapping around + exceeding buffer size).
Verifies buffer clearing across wraparound and 5 complete packets.
8. Wraparound stress with multiple cycles and duplicate detection -
rapidly cycles through wraparound boundary (65530-65535-0-10) twice
with different packet filters. First cycle sends packets where
(seq % 3) != 0, second cycle sends packets where (seq % 3) != 1.
Tests duplicate rejection and verifies only unique sequence numbers
are delivered.
9. Fragment corruption across wraparound - validates protection against
historical bug where fragments from different packet transmissions
could be incorrectly mixed. Sends seq 5000 frag 1 filled with 'A',
advances through complete wraparound (65536 sequences), sends seq 5000
frag 2 filled with 'B'. Verifies old fragment 1 was invalidated and
no corrupted packet delivered (mixing A+B fragments).
10. Defragmentation buffer reclamation window calculation - validates
_reclaim_old_defrag_bufs() correctly reclaims buffers outside current
sequence window using seq_num (not dst_seq_num). Creates incomplete
fragments at seq 100, 105, 110, 115, 120, then advances window to
seq 150. Verifies buffers outside window (100-115) are reclaimed and
buffer within window (120) is preserved.
11. Circular buffer clearing at boundaries - validates _seq_num_lookup
correctly clears circular_buffer ranges in both wraparound (tail > head)
and normal (tail <= head) cases. Test case 1: seq 3000 → 10 creates
tail=3001 > head=10, should clear [3001..4095] and [0..10]. Test case 2:
seq jump to 8191 creates tail=0 <= head=4095, should clear [0..4095].
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
Commit: 11423d0e04dc662daeab81184403453636948ce5
https://github.com/kronosnet/kronosnet/commit/11423d0e04dc662daeab811844034…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-26 (Tue, 26 May 2026)
Changed paths:
M libknet/tests/Makefile.am
A libknet/tests/int_defrag_edge_cases.c
Log Message:
-----------
[tests] add defragmentation edge cases test suite
Add new int_defrag_edge_cases_test that validates critical defragmentation
buffer management scenarios not covered by existing tests.
Test scenarios:
1. Last fragment arriving first - validates special buffer positioning
at KNET_MAX_PACKET_SIZE - len offset, last_first flag handling, and
fragment relocation when packet completes. Tests asymmetric MTU with
fragments in order [3/3, 1/3, 2/3] and verifies data integrity across
all fragments (280 bytes total with distinct payloads 'A', 'B', 'C').
2. Buffer exhaustion and reclamation - validates window-based reclamation
when all 32 defrag buffers are filled with incomplete packets. Sends
new complete packet with distant sequence number (9000 vs 2000-2031)
triggering reclamation of all out-of-window buffers. Verifies data
integrity with no corruption from old buffer data in new packet.
3. Fragment data overwrite protection - validates correct assembly of
large fragmented packets without buffer overflow. Test case 1 sends
100 fragments × 500 bytes (50,000 bytes total), test case 2 sends
50 fragments × 1,300 bytes (65,000 bytes approaching KNET_MAX_PACKET_SIZE).
Each fragment filled with its index number and verified on assembly.
4. Duplicate fragment handling - validates that duplicate fragments (same
sequence number and fragment index) are silently rejected without
corrupting the buffer. Sends frag 1/2, frag 1/2 (duplicate with different
data), frag 2/2 and verifies only one correct packet is delivered with
original fragment data preserved.
5. Maximum realistic fragments - validates fragment map can handle high
fragment counts (100 fragments, 500 bytes each = 50,000 bytes total).
PCKT_FRAG_MAX (255) is theoretical limit, but realistic max is determined
by min_mtu. Tests worst-case scenario with min MTU ~550 bytes.
6. Single fragment packets (1/1) - validates degenerate case where packets
are marked as fragmented but contain only one fragment. Sends 5 packets
of 200 bytes each, all marked as 1/1, and verifies correct delivery
without unnecessary defragmentation overhead.
7. Interleaved fragment assembly across wraparound - validates concurrent
assembly of multiple fragmented packets with fragments arriving in
interleaved order across sequence number wraparound boundary. Sends
4 packets (seq 65534, 65535, 0, 1) with all first fragments, then
completes them in reverse order (1→0→65535→65534). Verifies all packets
received correctly with no cross-contamination between defrag buffers.
8. Zero-payload fragments - validates defensive handling of zero-length
fragments (packet injection attacks, corrupted packets). Test case 1:
2-fragment packet with all fragments zero bytes. Test case 2: 3-fragment
packet with all fragments zero bytes. Test case 3: Single fragment (1/1)
with zero payload. Verifies correct 0-byte packet delivery and buffer
management for all cases.
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
Commit: 23ee544077778de105a29b306818561352e3d53b
https://github.com/kronosnet/kronosnet/commit/23ee544077778de105a29b3068185…
Author: Fabio M. Di Nitto <fdinitto(a)redhat.com>
Date: 2026-05-26 (Tue, 26 May 2026)
Changed paths:
M libknet/tests/Makefile.am
A libknet/tests/int_buffer_management.c
Log Message:
-----------
[tests] add defragmentation buffer management test suite
Add new int_buffer_management_test that validates dynamic defragmentation
buffer allocation, growth, shrinking, and reuse scenarios.
Test scenarios:
1. Dynamic buffer growth - validates automatic buffer reallocation when
all defrag buffers are in use. Fills all 32 initial buffers with
incomplete packets (fragment 1/2 only), then sends one additional
packet to trigger growth. Verifies buffer allocation doubles from
32 to 64 and packet reception works correctly after reallocation.
2. Buffer reuse after reclamation - validates that reclaimed buffers
are properly cleared before reuse, preventing data leakage. Sends
incomplete packet at seq 5000 filled with 'X', then complete packet
at seq 10000 (distance 5000 > KNET_CBUFFER_SIZE 4096) triggering
reclamation. Verifies new packet contains only 'Z' with no trace of
'X', then reuses same buffer with new packet 'M'+'N' and confirms
no leakage.
3. Dynamic buffer shrinking - validates automatic buffer deallocation
when usage stays below threshold. Starting from 64 buffers (grown in
test 1), clears all incomplete packets to achieve low usage, reduces
defrag_bufs_usage_samples from 255 to 10 for faster testing, then
sends complete packets over 10+ sample periods (1 second each) to
trigger shrinking. Verifies buffers halve from 64 to 32 and packet
reception works correctly after shrinking.
Signed-off-by: Fabio M. Di Nitto <fabbione(a)kronosnet.org>
Co-Authored-By: Claude Sonnet 4.5 <noreply(a)anthropic.com>
Compare: https://github.com/kronosnet/kronosnet/compare/a541323887eb...23ee54407777
To unsubscribe from these emails, change your notification settings at https://github.com/kronosnet/kronosnet/settings/notifications