Good news - I got some time, and the patch was pretty simple, so here it is. It is made against the 3/16 snapshot. There are two parts. One is to change radiusd.conf.in so that acct_unique is in the pre-accounting section. The other is to change rad_accounting in acct.c to not send Accounting-Response if the accounting module returns RLM_MODULE_NOOP. I tested it both for messages that are handled locally and that are proxied. Both cases work as I would expect, but let me know if you see a problem.
Dave
-----------------------------------------------------------------------
$ diff -u raddb/radiusd.conf.in.orig raddb/radiusd.conf.in
--- raddb/radiusd.conf.in.orig 2004-03-15 13:10:47.000000000 -0600
+++ raddb/radiusd.conf.in 2004-03-17 14:07:29.000000000 -0600
@@ -1602,17 +1602,17 @@
#
# Read the 'acct_users' file
files
-}
-#
-# Accounting. Log the accounting data.
-#
-accounting {
#
# Ensure that we have a semi-unique identifier for every
# request, and many NAS boxes are broken.
acct_unique
+}
+#
+# Accounting. Log the accounting data.
+#
+accounting {
#
# Create a 'detail'ed log of the packets.
# Note that accounting requests which are proxied
-----------------------------------------------------------------------
$ diff -u src/main/acct.c.orig src/main/acct.c
--- src/main/acct.c.orig 2004-02-26 13:04:22.000000000 -0600
+++ src/main/acct.c 2004-03-17 12:09:21.000000000 -0600
@@ -138,9 +138,11 @@
* We get here IF we're not proxying, OR if we've
* received the accounting reply from the end server,
* THEN we can reply to the NAS.
+ * If the accounting module returns NOOP, the data
+ * storage did not succeed, so radiusd should not send
+ * Accounting-Response.
*/
- if (reply == RLM_MODULE_NOOP ||
- reply == RLM_MODULE_OK ||
+ if (reply == RLM_MODULE_OK ||
reply == RLM_MODULE_UPDATED) {
/* -----------------------------------------------------------------------
Alan DeKok wrote:
Dave Mason wrote:
Maybe Freeradius should not send Accounting-Response if the accounting module returns noop?
That's probably the best solution.
Patch?
Alan DeKok.
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

