<feed xmlns='http://www.w3.org/2005/Atom'>
<title>accel-ppp.git/accel-pppd/radius, branch sstp-alloc-invariant</title>
<subtitle>High performance PPTP/L2TP/SSTP/PPPoE/IPoE server for Linux (mirror of https://github.com/accel-ppp/accel-ppp.git)
</subtitle>
<id>https://git.amelek.net/accel-ppp/accel-ppp.git/atom?h=sstp-alloc-invariant</id>
<link rel='self' href='https://git.amelek.net/accel-ppp/accel-ppp.git/atom?h=sstp-alloc-invariant'/>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/'/>
<updated>2026-07-06T09:45:36+00:00</updated>
<entry>
<title>radius: fix request slot leak when queued request wakeup fails</title>
<updated>2026-07-06T09:45:36+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-07-06T09:43:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=1a9923a07c1283b30a5b02a1668f57015f26232e'/>
<id>urn:sha1:1a9923a07c1283b30a5b02a1668f57015f26232e</id>
<content type='text'>
req_wakeup() ignored the return value of req-&gt;send(req, 1). When a
request dequeued from the req-limit queue failed at socket setup
(__rad_req_send returns -2, e.g. under ephemeral port exhaustion or a
routing error), the server's req_cnt slot taken in
rad_server_req_exit() was never released and the request was orphaned
with no callback and no timer.

Leaked slots accumulate until req_cnt permanently saturates req-limit,
after which every request queues forever and the server is effectively
dead until restart.

Handle -2 the same way rad_server_req_enter() does: release the slot,
mark the server failed and drive the request through the regular
failover path so it either retries on another server or reports the
failure to its owner.

Signed-off-by: Denys Fedoryshchenko &lt;denys.f@collabora.com&gt;
</content>
</entry>
<entry>
<title>radius: fix permanent socket leak in Acct-Stop retry path</title>
<updated>2026-07-06T09:44:52+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-07-06T09:42:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=8a94a47e8068dbc8b308cea0b875c516d2ad13f5'/>
<id>urn:sha1:8a94a47e8068dbc8b308cea0b875c516d2ad13f5</id>
<content type='text'>
When an accounting Stop request cannot be retransmitted because no
server is available (single server inside its fail-timeout window,
server removed on config reload, or a transient socket/connect error
that marks the server failed), rad_acct_stop_timeout() reset req-&gt;try
and returned. The retransmit timer is one-shot (no period), so it
never fired again: the request leaked forever together with its open
UDP socket, epoll registration and timerfd.

The same dead end existed in rad_acct_stop_sent(): a deferred Stop
request (req-&gt;rpd == NULL) whose queued send was cancelled by
rad_server_fail() fell through the failure branch without freeing the
request or scheduling a retry.

With the RADIUS client bound to a source address (bind=/nas-ip-address)
every leaked socket pins one ephemeral port. On a busy NAS each session
terminating during a short RADIUS outage leaks one socket; after months
of uptime the ephemeral port range is exhausted and every new request
fails with "radius:bind: Address already in use" followed by
"no available servers", requiring a restart.

Fix by re-arming the one-shot timer on send failure instead of
resetting the try counter, so retries are bounded by max-try and the
request is freed cleanly once attempts are exhausted.

Both defects date back to the accounting rewrite (62e89248, 2014).

Fixes: https://github.com/accel-ppp/accel-ppp/issues/324

Signed-off-by: Denys Fedoryshchenko &lt;denys.f@collabora.com&gt;
</content>
</entry>
<entry>
<title>Merge pull request #320 from nuclearcat/radius-reload-secret-new</title>
<updated>2026-06-23T15:33:54+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-06-23T15:33:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=61699f574e2b1dda858bf39b7426c844e14de2c7'/>
<id>urn:sha1:61699f574e2b1dda858bf39b7426c844e14de2c7</id>
<content type='text'>
radius: update server secret on config reload</content>
</entry>
<entry>
<title>Merge pull request #315 from nuclearcat/khedor-fixes</title>
<updated>2026-06-23T15:33:09+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-06-23T15:33:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=6a2dfa19254637ac8d844550d9bd36b7467c181f'/>
<id>urn:sha1:6a2dfa19254637ac8d844550d9bd36b7467c181f</id>
<content type='text'>
Several bugfixes for problems reported by Khodor Tahech </content>
</entry>
<entry>
<title>openssl: suppress deprecated API warnings</title>
<updated>2026-06-10T18:28:29+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-06-10T14:15:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=c1689506bbc27f498612ca69648876599ded7d7c'/>
<id>urn:sha1:c1689506bbc27f498612ca69648876599ded7d7c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>radius: update server secret on config reload</title>
<updated>2026-06-05T19:42:06+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-06-05T19:30:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=950dad62c7544dd42de319db29c4f57bd867971a'/>
<id>urn:sha1:950dad62c7544dd42de319db29c4f57bd867971a</id>
<content type='text'>
On EV_CONFIG_RELOAD, __add_server() re-parses each server line into a
fresh rad_server_t and, when it matches an existing server by
addr/auth_port/acct_port, copied over only the timeout/limit/bind
fields before freeing the new struct. The freshly parsed secret was
discarded, so editing a shared secret and reloading had no effect until
a full restart. The strdup'd secret on the freed struct was also leaked
on every matched reload.

Adopt the new secret into the existing server (freeing the old one) so
secret changes take effect on reload. New requests read
req-&gt;serv-&gt;secret directly, so they pick up the update immediately.
This covers both the modern "server=" path and the legacy
auth-server/acct-server path, which both funnel through __add_server().
</content>
</entry>
<entry>
<title>fix: dict.c: split() could return 0, making dict_load read ptr[-1]</title>
<updated>2026-05-21T14:03:17+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-05-21T14:03:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=22c61e8e2e16ebe8e9576fe46487e3614982e8ac'/>
<id>urn:sha1:22c61e8e2e16ebe8e9576fe46487e3614982e8ac</id>
<content type='text'>
If a RADIUS dictionary contains a line consisting of exactly one
word with no trailing spaces (for example, standard keywords like
"END-VENDOR\n"  or  "END-TLV\n" ), this bug getting triggered.
Triggering crash is compiler dependent, it might not happen now,
but a bit different compiler, flags, and it might crash on load.

Reported-by: Khedor &lt;khedor@gmail.com&gt;
Signed-off-by: Denys Fedoryshchenko &lt;denys.f@collabora.com&gt;
</content>
</entry>
<entry>
<title>radius: encapsulate server statistics counters</title>
<updated>2026-05-04T00:09:49+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-04-29T10:38:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=dd29f19a14a79437928638029bdb43ba1bba8c08'/>
<id>urn:sha1:dd29f19a14a79437928638029bdb43ba1bba8c08</id>
<content type='text'>
Group the per-server RADIUS statistics in struct rad_server_stat_t under rad_server_t.stat instead of keeping auth, accounting, interim, and failure counters as separate fields on rad_server_t.  This keeps the statistics state collected behind one ownership boundary and makes the relationship between the total counters and their rolling accumulators explicit.

Route counter updates through rad_server_stat_*() helpers.  Auth, accounting, interim, and server-failure paths no longer open-code individual counter increments and accumulator updates; the update policy now lives in serv.c with the rest of the RADIUS server accounting logic.

Make the CLI show-stat path render from a local snapshot.  The displayed totals are loaded with relaxed atomic reads, the rolling one-minute/five-minute values are collected in one place, and the in-flight request/queue counters are copied under the server lock before printing.  Future changes to synchronization or accumulator storage can stay inside the snapshot/update helpers instead of leaking into the CLI formatting code.

Signed-off-by: Denys Fedoryshchenko &lt;denys.f@collabora.com&gt;
</content>
</entry>
<entry>
<title>Merge pull request #297 from nuclearcat/fixes-radius</title>
<updated>2026-03-16T16:07:36+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-03-16T16:07:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=06f64b19a123d623438b95b5e6da00f4bf4ce9c1'/>
<id>urn:sha1:06f64b19a123d623438b95b5e6da00f4bf4ce9c1</id>
<content type='text'>
Various radius fixes</content>
</entry>
<entry>
<title>radius: fix stop accounting timeout flow and request cleanup</title>
<updated>2026-02-28T06:25:59+00:00</updated>
<author>
<name>Denys Fedoryshchenko</name>
<email>denys.f@collabora.com</email>
</author>
<published>2026-02-28T06:25:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/accel-ppp/accel-ppp.git/commit/?id=bd936f6074b6b6c515cfd40a1c0215b3dfa7889d'/>
<id>urn:sha1:bd936f6074b6b6c515cfd40a1c0215b3dfa7889d</id>
<content type='text'>
When sending accounting STOP requests, the timer callback was
incorrectly set to the START timeout handler.  This caused stop
retries to follow the wrong termination path.

Also clear rpd-&gt;acct_req before freeing on stop timeout/shutdown
failures to avoid leaving a stale pointer.

This bug is very nasty, revealed during stress tests, leading to
memory corruption and other bad stuff when there is noticeable
loss of radius "Stop" packets.

Signed-off-by: Denys Fedoryshchenko &lt;denys.f@collabora.com&gt;
</content>
</entry>
</feed>
