At 01:58 PM 1/25/2002 -0500, you wrote: >Randy Moore <[EMAIL PROTECTED]> wrote: <snip>
> Yeah, but I don't run SQL, so it's a little harder for me to take a >look at it. If it would help, I'd be more than happy to give you access to my development server (he says grinning and trying not to beg). > > Program received signal SIGSEGV, Segmentation fault. > > [Switching to Thread 1024 (LWP 23259)] > > 0x40026fdc in rlm_sql_authenticate (instance=0x80b80d8, request=0x80ea080) > > at rlm_sql.c:376 > > 376 memcpy(password_pair->strvalue, row[0], > > strlen(row[0])); > > So I presume that either 'password_pair' is NULL, or row[0] is NULL. > > Knowing which one is NULL would help. Do: > >(gdb) p password_pair >(gdb) p row[0] (gdb) p password_pair $1 = (VALUE_PAIR *) 0x80eafc8 (gdb) p row[0] $2 = 0x0 This is strange, in some of my earlier testing I had put in some extra logging to show the contents of row[0] and test full NULL in password_pair. At that point, I thought both were OK. I'm going to redo that test. > What *may* be happening is that the 'paircreate' function on line >375 is failing. The code never checks for a failure, so it will SEGV, >instead of recovering. > > > Hmm... in fact, most of the CHAP specific code should be removed >from the SQL module. Now that we have rlm_chap, it can take care of >all of these issues. > > > Try configuring the modules so that 'chap' is before 'sql' in the >authorize section, and there is NO 'sql' in the authenticate section, >but there IS a 'chap'. Hmm, I don't think I understand you here. If I take 'sql' out of the authenticate section, radiusd fails to start and I get the following error: /usr/local/freeradius-snapshot-20020125/etc/raddb/users[78]: Parse error (check) for entry DEFAULT: Unknown value Sql for attribute Auth-Type Which makes sense to me. Without sql in authnticate, how could radiusd find the stored password to check against? Also, I tried adding 'chap' before 'sql' in authorize, but I get the error: ERROR: Cannot find a configuration entry for module "chap". So, I tried putting in an empty 'chap' block in the modules section. That worked but didn't change the symptoms of the crashes. Do I need something more in the modules block? > If that works, then the simplest solution is to just delete the CHAP >authentication code from the SQL module. I'll see if I can do that. Thanks much! Randy Moore Axion Information Technologies, Inc. email [EMAIL PROTECTED] phone 301-408-1200 fax 301-445-3947 - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
