<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ouroboros/src/lib/ssm, branch be</title>
<subtitle>Ouroboros main repository</subtitle>
<id>http://www.ouroboros.rocks/cgit/ouroboros/atom?h=be</id>
<link rel='self' href='http://www.ouroboros.rocks/cgit/ouroboros/atom?h=be'/>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/'/>
<updated>2026-06-29T06:32:58+00:00</updated>
<entry>
<title>irmd: Deliver flow re-keying</title>
<updated>2026-06-29T06:32:58+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-06-14T14:16:03+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=fdb50b8256f1038d5bc4f906b41605cacc769bf4'/>
<id>urn:sha1:fdb50b8256f1038d5bc4f906b41605cacc769bf4</id>
<content type='text'>
Re-key each encrypted flow's batch root periodically so a long-lived
flow never exhausts or over-uses a single root. The IRMd re-runs the
OAP exchange with the peer IRMd over the flow-update relay. The
per-flow re-keying state is tracked in the registry (reg_flow).

A re-key delivers one root seed from the OAP exchange. keyrot
immediately HKDF-expands it into 128 node keys (KR_NODES_SZ = 128 × 32
B) and wipes the root. Then each of the 128 node keys is itself a root
→ HKDF-expanded into 64 (2^KEY_NODE_BITS) leaf keys, forked per
direction; each leaf key is the actual AEAD key, good for 2^20 packets
(the low counter bits are its nonce/seq). If the number of keys runs
low, a re-key will be triggered (KEY_REKEY_WATERMARK).

The rekey is signalled out of band to the application. The rbuff ACL
is generalized into a flags word, so an RB_REKEY bit rides alongside
the access RB_RD/RB_WR and FLOWDOWN/FLOWPEER bits. The RD and WR bits
are revised ditching the fcntl historical weirdness. The seed is
pulled via flow_read/flow_write, installed with crypt_rekey(). TX
holds the old epoch until the peer is observed on the new one (or a
grace deadline elapses), promoted from both the read and write paths
so a recv-mostly flow still advances.

Also fix the FLOW_ACCEPT and FLOW_ALLOC handlers, which on a key-buffer
allocation failure returned from inside the cleanup-push region: that
leaked the reply message and skipped both the stack-key scrub and the
cleanup pop.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Fix SSM reclaim-orphans test</title>
<updated>2026-06-29T06:32:55+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-06-14T13:14:17+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=f5b15630d20acc893e3000f248f03185763f24b0'/>
<id>urn:sha1:f5b15630d20acc893e3000f248f03185763f24b0</id>
<content type='text'>
Age the simulated-leaked blocks via alloc_ts so the aged-reclaim
triggers in the test.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Reclaim aged leaked ssm pool blocks</title>
<updated>2026-06-03T06:02:34+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-06-01T06:41:34+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=bdfea870024b8efd0a0bd16f8978482d8bbf9ed9'/>
<id>urn:sha1:bdfea870024b8efd0a0bd16f8978482d8bbf9ed9</id>
<content type='text'>
The reclaim_pid_from_sc() function reaped any block allocated with
refcount from a dead PID, but cross-process hand-offs can leave a
block briefly allocated by the producer while a live consumer still
holds it. This skips reclaim within SSM_POOL_RECLAIM_AGE_S (default
60s) so in-flight hand-offs survive a producer crash.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Fix overflow in ssm_flow_set_notify</title>
<updated>2026-06-03T06:02:34+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-06-01T06:37:39+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=b88c120f68b0e9f779fa0071a2ad095b93d5aaf6'/>
<id>urn:sha1:b88c120f68b0e9f779fa0071a2ad095b93d5aaf6</id>
<content type='text'>
ssm_flow_set_notify wrote past the fqueue because of a missing bound
check, corrupting adjacent memory under burst. Drop redundant FLOW_PKT
when full and reserve the last slot for control events so they aren't
starved by data-plane traffic.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Use push/pop for ssm_pk_buff ops</title>
<updated>2026-05-20T06:17:06+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-15T09:40:00+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=f33769c818cb1f01079405f543b36aa294764112'/>
<id>urn:sha1:f33769c818cb1f01079405f543b36aa294764112</id>
<content type='text'>
Renames the allocation for head/tail to push/pop instead of
alloc/release as it's simpler and shorter. Took this approach insted
of adopting the kernel's push/pull/put/trim.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>build: Remove deprecated cmake options</title>
<updated>2026-05-20T06:17:06+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-10T16:53:02+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=ab476259d875e8352a4ef23c2d25b0e67161c771'/>
<id>urn:sha1:ab476259d875e8352a4ef23c2d25b0e67161c771</id>
<content type='text'>
RXM_BUFFER_ON_HEAP and SSM_POOL_BLOCKS were no longer used.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Use const for ssm_pk_buff getters</title>
<updated>2026-05-20T06:17:06+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-10T15:37:31+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=46fa893af9ed74e2a473354c1777bd494b3374db'/>
<id>urn:sha1:46fa893af9ed74e2a473354c1777bd494b3374db</id>
<content type='text'>
Mark ssm_pk_buff_get_off, _head, _tail, and _len as taking a const
struct ssm_pk_buff *. Cast through the flex array in _head and _tail
since the buffer view they return remains mutable.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Rename PROG_* config to PROC_*</title>
<updated>2026-05-20T06:17:06+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-03T16:21:33+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=ea864c3d3e8ff75ffbbc1e3f01db09daa9b7a5c8'/>
<id>urn:sha1:ea864c3d3e8ff75ffbbc1e3f01db09daa9b7a5c8</id>
<content type='text'>
Per-process flow / fd / fqueue limits are properties of a process, not
a program; align the naming. Mechanical rename of PROG_MAX_FLOWS,
PROG_RES_FDS, and PROG_MAX_FQUEUES to PROC_*.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>include: Centralise atomic helpers in atomics.h</title>
<updated>2026-05-20T06:17:05+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-02T13:35:41+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=8cea9fdd2831a0bcf735d323796104cd8f318133'/>
<id>urn:sha1:8cea9fdd2831a0bcf735d323796104cd8f318133</id>
<content type='text'>
Moves the atomics macros that were defined between eth and ssm_pool to
their own header.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
<entry>
<title>lib: Fix pool_sharding_test</title>
<updated>2026-05-20T06:17:05+00:00</updated>
<author>
<name>Dimitri Staessens</name>
<email>dimitri@ouroboros.rocks</email>
</author>
<published>2026-05-01T15:31:27+00:00</published>
<link rel='alternate' type='text/html' href='http://www.ouroboros.rocks/cgit/ouroboros/commit/?id=aa3901535516d49c7a881c9c06e3582e1a6f1ada'/>
<id>urn:sha1:aa3901535516d49c7a881c9c06e3582e1a6f1ada</id>
<content type='text'>
The test was not correctly taking the correct size class. Moved the
select_size_class to the common header so tests can use it.

Signed-off-by: Dimitri Staessens &lt;dimitri@ouroboros.rocks&gt;
Signed-off-by: Sander Vrijders &lt;sander@ouroboros.rocks&gt;
</content>
</entry>
</feed>
