Hello Danny -

On Wednesday 31 January 2001 03:14, Danny Kruitbosch wrote:
> Hi,
>
> I'm (still) trying to set up the following:
>
> We have users that need a static ip-address and users that need a dynamic
> address.
> Users with static addresses have 2 IP adresses because we have 2 dailin
> providers. The user has a choice which one he wants to use (e.g. If one
> provider doesn't answer, manually switch to the other).
> I want to be able to see the difference between "static users" and
> "dynamic users". To do this I have done the following:
>
> I set up a DB with GROUPID, StaticIP1 and StaticIP2 columns. I use
> AuthSQL to authenticate my users. By using AuthColumnDef I put Group-ID
> into the radius reply. Group-ID is either 0 (static) or 1 (dynamic).
>
> So after the AuthSQL the reply looks like this:
>
> Attributes:
>         Group-ID = 0 or 1
>         Static-IP1= 1.2.3.4
>         Static-IP2= 5.6.7.8
>
> For dynamic users Static-IP1 and Static-IP2 are empty.
>
>
> Now, what I want to do is this:
>
> After the AuthSQL I want to be able to say: if Group-ID=0 return
> Static-IP1 or Static-IP2 (depending on the provider the user used) as the
> Framed-IP-Address. If the user has Group-ID=1 than use Auth DYNADDRESS.
>

You will need to write a PostAuthHook to do this - should be pretty simple.

There are several examples in the file "goodies/hooks.txt" in the Radiator 
2.17.1 distribution. The closest one to what you want to do is a ReplyHook, 
which will of course need to be converted into a PostAuthHook (the parameters 
passed are different), but it does do dynamic address allocation so changing 
it should be straightforward).

BTW - we do offer contract development services, so if you would like me to 
do it for you, please send a purchase order for a couple of hours consulting 
time to Joanne ([EMAIL PROTECTED]).

regards

Hugh

-- 
Radiator: the most portable, flexible and configurable RADIUS server 
anywhere. Available on *NIX, *BSD, Windows 95/98/2000, NT, MacOS X.
-
Nets: internetwork inventory and management - graphical, extensible,
flexible with hardware, software, platform and database independence.

===
Archive at http://www.starport.net/~radiator/
Announcements on [EMAIL PROTECTED]
To unsubscribe, email '[EMAIL PROTECTED]' with
'unsubscribe radiator' in the body of the message.

Reply via email to