- Notifications
You must be signed in to change notification settings - Fork15
Description
Summary
ION-DTN 4.1.3s rejects a BPv7 bundle containing a canonical block with type 8 because it fails to parse it as a Metadata Extension Block despite the MEB being only defined for BPv6, not for BPv7.
Test case (hex)
This BPv7 bundle has a canonical block type=8 with flags=0x0001 (delete-if-unprocessednot set) and a payload block (“Hello, World!”).
9f88070000820282030182028201018202820100821b000000bb0e20b4ea001a000927c08508020100410086010100014d48656c6c6f2c20576f726c64214254b3ffWhen sent to ION-DTN's bpsink:
~/targets/nasa/ION-DTN/receiver-bpv7/3.bench.udp$ bpsink ipn:3.1ION-DTN rejects the bundle with the following log:
ion.log:
[2025/09/03-10:23:29] [?] Can't decode MEB block.[2025/09/03-10:23:29] [?] Malformed bundle: extension blocks processing.The "Can't decode MEB block" message implies that it attempted to parse the block as a Metadata Extension Block (MEB).
However, block type 8 corresponds to MEB only in BPv6, while that block type is not defined for BPv7.
Note that the delete-if-unprocessed is not set, so the bundle should not be deleted.
Instead, when the same bundle is sent to three other BPv7 implementations (ESA BP,bp7-rs,uD3TN)
they all treat the extension with type 8 as unknown but donot reject the bundle.
[ESA_BP] OK:Decoded bundle: esa.egos.bp.protocol.coding.api.bundle.BundleBpv7@6d7fc27[bp7-rs] OK:Bundle { primary: PrimaryBlock { ... }, canonicals: [ CanonicalBlock { block_type: 8, block_number: 2, block_control_flags: 1, crc: CrcNo, data: Unknown(), }, CanonicalBlock { block_type: 1, block_number: 1, block_control_flags: 0, crc: Crc16([84,179]), data: Data([72,101,108,108,111,44,32,87,111,114,108,100,33]), }, ],}[ud3tn_v0.14.2] OK:BPv7 bundle - source: ipn:1.1 - destination: ipn:2.1 - report to: ipn:1.0 - creation ts.: 803395908842 - sequence no.: 0 - expires at: 803396509 - payload len.: 13 - proc. flags: 0x0000 - block no. 2 of type = 8 (unknown block) - flags: 0x0001 - length: 1 - block no. 1 of type = 1 (payload block) - flags: 0x0000 - length: 13Suggested fix
Since block type 8 is not defined for BPv7, do not try to parse it as MEB but instead consider it an unknown block