Hi all,

when I've compiled in snmp support (--with-snmp) on current cvs head I got 
following segmentation fault(does not matter whether NAS are stored in DB or in 
clients.conf):

>>>DEBUG OUTPUT START
...
Ready to process requests.
Nothing to do.  Sleeping until we see a request.
SMUX read start
SMUX read len: 12
SMUX message received type: 67 rest len: 4
SMUX_RRSP
SMUX_RRSP value: 0 errstat: 0
--- Walking the entire request list ---
Nothing to do.  Sleeping until we see a request.

SMUX read start
SMUX read len: 40
SMUX message received type: 161 rest len: 36
SMUX_GETNEXT
SMUX GET message parse: len 36
SMUX GET reqid: 182 len: 32
SMUX GET errstat 0 len: 29
SMUX GET errindex 0 len: 26
SMUX var parse: len 26
SMUX var parse: type 48 len 22
SMUX var parse: type must be 48
Request OID: 1.3.6.1.2.1.67.1.1.1.1.15.1.2.1
SMUX val_type: 5
ASN_NULL
SMUX function call index is 2
SMUX function call index is 3
Segmentation fault
>>>DEBUG OUTPUT END

when debugging(I can attach the gdb output if needed) I've found that it
fails somewhere on reading internal nas clients data structure. As I'm
not interested in nas clients obtained via snmp(I keep them in mysql DB)
following is the little patch which basically just ads "return NULL" when 
snmp asks for next nas client:

Index: src/main/radius_snmp.c
===================================================================
RCS file: /source/radiusd/src/main/radius_snmp.c,v
retrieving revision 1.31
diff -u -r1.31 radius_snmp.c
--- src/main/radius_snmp.c      10 Apr 2007 14:21:24 -0000      1.31
+++ src/main/radius_snmp.c      11 Apr 2007 14:41:08 -0000
@@ -194,6 +194,8 @@
        RADCLIENT *c;
        int i, len;

+       return NULL;
+
        len = *objid_len - v->namelen;

        if (!mainconfig.clients)


Hope this helps someone.


Milan Holub
holub (at) thenet (dot) ch

--------------------------------------
 TheNet-Internet Services AG,
 im Bernertechnopark, Morgenstr. 129
 CH-3018, Bern, Switzerland
 031 998 4333, Fax 031 998 4330
 http://www.thenet.ch
 http://wlan.thenet.ch
--------------------------------------

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to