invalid variable

Stelian Ionescu sionescu at cddr.org
Tue Jun 4 16:02:05 CEST 2013


On Tue, 2013-06-04 at 09:57 -0400, Alan DeKok wrote:
> duffy wrote:
> > thank you for your reply alan!
> > actually it seems the variable expansion issue is not really solved..
> 
>   Read the debug output.  It doesn't complain about variables any more,
> 
> > _bssid(NULLIF('0x=3F=3F', '')),COALESCE(NULLIF('0', ''), '0')::smallint);'
> > rlm_sql_postgresql: Status: PGRES_FATAL_ERROR
> > rlm_sql_postgresql: Error syntax error at or near ","
> > rlm_sql_postgresql: Postgresql Fatal Error: [42601: SYNTAX ERROR]
> > Occurred!!

This is from our configuration file:

authorize_check_query="\
SELECT id, inner_id, attribute, val, op \
 FROM radcheck(\
COALESCE(NULLIF('%{Event-Timestamp}', ''), '%S')::timestamp with time zone,\
'%{SQL-User-Name}',\
'%{Realm}',\
'%{Nas-Ip-Address}'::inet,\
'%{Calling-Station-Id}'::macaddr,\
parse_bssid(NULLIF('%{WiMAX-BS-Id}', '')),\
COALESCE(NULLIF('%{WiMAX-PDFID}', ''), '0')::smallint);"

additionally, the debug log shows that Event-Timestamp contains a valid value:

rlm_perl: Added pair Event-Timestamp = Jun  4 2013 15:13:09 CEST

So I guess that the error is in the xlat function.

-- 
Stelian Ionescu a.k.a. fe[nl]ix
Quidquid latine dictum sit, altum videtur.
http://common-lisp.net/project/iolib

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freeradius.org/pipermail/freeradius-devel/attachments/20130604/0d9df45f/attachment.pgp>


More information about the Freeradius-Devel mailing list