(RADIATOR) pooled connections

Hugh Irvine hugh at open.com.au
Fri Mar 19 15:57:02 CST 2004


Hello Tariq Rashid -

Yes you can do what you describe quite easily by defining AuthBy SQL 
and AuthBy LDAP2 clauses with Identifiers in "global" space and then 
refer to them in your hooks by using the Identifiers. You can also use 
the "GlobalVar" variables for static values.

# define AuthBy clauses with Identifiers for use in hooks

<AuthBy SQL>
	Identifier SQLTag
  	.....
</AuthBy>

<AuthBy LDAP2>
	Identifier LDAPTag
	.....
</AuthBy>


There are some example hooks in the file "goodies/hooks.txt" that do 
most of what you describe.

regards

Hugh


On 19 Mar 2004, at 21:27, Tariq Rashid wrote:

>
> i've been using radiator very happily using the perl hooks.
>
> now i have a new task which requires the hooks to make decisions 
> depending
> on the results of LDAP and SQL lookups. of course its possible to open 
> a
> connection, do the lookups, and then release the connections.
>
> however this happens for each request. which is not very efficient and
> drives up the load.
>
> i wonder if:
>
> 	* it is poosible to open a single / pool of connections during the
> startup hook
> 	  and use it for every request postsearchhook? and close them on
> shutdown/restart.
>
> 	* i also wonder if its possible to create global static variables in
> the starttup
> 	  and refer to the in subsequent hooks, and even modify these
> variables.
> 	  namespaces?
>
> i think the moduule instantiations of freeradius (which appear very 
> parallel
> to objects of classes and their life-cycles) are the closest i've seen 
> to
> this
>
> thanks
>
> tariq rashid
>
> --
> Archive at http://www.open.com.au/archives/radiator/
> Announcements on radiator-announce at open.com.au
> To unsubscribe, email 'majordomo at open.com.au' with
> 'unsubscribe radiator' in the body of the message.
>
>

NB: have you included a copy of your configuration file (no secrets),
together with a trace 4 debug showing what is happening?

-- 
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. Available on *NIX, *BSD, Windows, MacOS X.
-
Nets: internetwork inventory and management - graphical, extensible,
flexible with hardware, software, platform and database independence.
-
CATool: Private Certificate Authority for Unix and Unix-like systems.

--
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.


More information about the radiator mailing list