RE: [RadiusNT] defining server port access

Stephen Johnson ( (no email) )
Wed, 21 Jun 2000 11:13:30 -0500

Works great!
thanks ;-)

Stephen

> -----Original Message-----
> From: radiusnt-request@iea-software.com
> [mailto:radiusnt-request@iea-software.com]On Behalf Of Dale E. Reed Jr.
> Sent: Tuesday, June 20, 2000 7:17 PM
> To: radiusnt@iea-software.com
> Subject: Re: [RadiusNT] defining server port access
>
>
> Stephen Johnson wrote:
> >
> > I am looking at setting up server port access, like time-of-day
> > restrictions. I use RadiusNT 2.5 and Microsoft SQL 6.5. I guess
> this may be
> > more of a basic SQL question - in setting up the serverports and
> > serveraccess tables is there an easy way to populate them with
> the necessary
> > records - like reading them in from a text file?
> > Any other pointers on setting this up?
>
> Here is one trick that I use sometimes to make it easier to manage.
>
> In the stored proc RadCheckPort, update the second to last line like
> this(adding the NULL part):
>
> CREATE PROCEDURE RadCheckPort @nasid varchar(16), @nasport integer, @at
> varchar(15) AS
> Select MaxSessionLength, StartTime, StopTime, CurrTime = (DatePart(Hour,
> GetDate()) * 60) + DatePart(Minute, GetDate())
> >From Servers s, ServerAccess sa
> Where s.ServerID = sa.ServerID
> AND s.IPAddress = @nasid
> AND (sa.Port=@nasport or sa.Port=NULL)
> AND sa.AccountType = @at
>
> What this allows you to do is set port to NULL to allow all ports for
> that server.
>
> Then you can use a query like:
>
> Insert Into ServerAccess (ServerID, Port, AccountType, StartTime,
> StopTime, MaxSessionLength)
> Select ServerID, NULL, AccountType, NULL, NULL, NULL
> >From Servers, AccountTypes
> Where AccountType in ('Email', 'PPP', 'ISDN')
>
> And adjust the where clause. You could use just one account types to
> restrict times for all the servers like:
>
> Insert Into ServerAccess (ServerID, Port, AccountType, StartTime,
> StopTime, MaxSessionLength)
> Select ServerID, NULL, AccountType, 480, 1080, NULL
> >From Servers, AccountTypes
> Where AccountType = 'PPP-Day Only'
>
> To configure the PPP-Day Only account type to login into servers
> from 8am to 6pm.
>
>
> --
>
> Dale E. Reed Jr. Emerald and RadiusNT/X
> __________________________________________
> IEA Software, Inc. www.iea-software.com
>
> For more information about this list (including removal) go to:
> http://www.iea-software.com/support/maillists/liststart
>

For more information about this list (including removal) go to:
http://www.iea-software.com/support/maillists/liststart