Problem using exec module

Mitchell, Michael J Michael.Mitchell at team.telstra.com
Mon Nov 14 22:42:35 CET 2005


Hi Nan0,

The authorize section of radiusd.conf is actually run twice when an
Access-Request is received by the server.

The first time, Autz-Type is not set. During the first run through the
authorize section, one of the modules may set Autz-Type, for example, a
module may set Autz-Type to MY_AUTZ_TYPE. 

The second time through the authorize section only modules contained
within the subsection defined by the Autz-Type variable will be run. eg:

	Autz-Type MY_AUTZ_TYPE {
		echo
	}

Hope that helps,
Mike


> -----Original Message-----
> From: freeradius-users-bounces at lists.freeradius.org 
> [mailto:freeradius-users-bounces at lists.freeradius.org] 
> Sent: Tuesday, 15 November 2005 8:38 AM
> To: 'FreeRadius users mailing list'
> Subject: Problem using exec module
> 
> Hi, I'm trying to use the next exec module:
> 
> radius.conf -------------------
> 
> modules {
> 	exec {
> 		wait = yes
> 		input_pairs = request
> 	}
> 	exec echo {
> 		wait = yes
> 		program = "/bin/echo %{Autz-Type}"
> 		input_pairs = request
> 		output_pairs = reply
> 	}
> }
> 
> authorize {
> 	suffix
> 	echo
> 	files
> 	sql
> 	auth_log
> }
> 
> -------------------------------
> 
> 
> And the Radiusd gave me the next output:
> 
> radiusd -X --------------------
> 
> WARNING: Attempt to use unknown xlat function, or 
> non-existent attribute in string %{Autz-Type}
> radius_xlat:  '/bin/echo '
> Exec-Program: /bin/echo
> Exec-Program output:
> Exec-Program-Wait: plaintext:
> Exec-Program: returned: 0
> 
> -------------------------------
> 
> 
> I hope someone can help me. Thanks and bye,
> 
> 
> NanO
> 
> -
> List info/subscribe/unsubscribe? See 
> http://www.freeradius.org/list/users.html
> 




More information about the Freeradius-Users mailing list