[Serusers] Src_ip matching

Michael Shuler mike at bwsys.net
Sun Sep 26 23:33:05 CEST 2004


Pretty close I actually needed:

If(src_ip == 192.168.1.80/28 || src_ip == 192.168.1.96/28)

I don't think you can do the src_ip/27 thing though


----------------------------------------

Michael Shuler, C.E.O.
BitWise Communications, Inc. (CLEC) And BitWise Systems, Inc. (ISP)
682 High Point Lane
East Peoria, IL 61611
Office: (217) 585-0357
Cell: (309) 657-6365
Fax: (309) 213-3500
E-Mail: mike at bwsys.net
Customer Service: (877) 976-0711 

> -----Original Message-----
> From: Greg Fausak [mailto:greg at addabrand.com] 
> Sent: Sunday, September 26, 2004 3:50 PM
> To: Michael Shuler
> Cc: serusers at lists.iptel.org; 'Andrei Pelinescu-Onciul'
> Subject: Re: [Serusers] Src_ip matching
> 
> 
> Are you saying you'll use 192.168.1.64/28 || 192.168.1.80/28 ?
> 
> Can you write 192.168.1.64/27?  I didn't look at the code, but
> some other options might be
> 
> src_ip/27 == 198.168.1.80/27
> 
> I didn't know you could put the subnet in the ip. cool.
> 
> -g
> 
> On Sep 26, 2004, at 2:13 PM, Michael Shuler wrote:
> 
> > I figured it out.  SER apparently uses strict sub netting.  
> A /27 is 
> > 32 IP's
> > and 80 is not evenly divisible by 32.  I changed it to /28 
> which is 16 
> > IP's
> > and since 80/16 = 5 with no remainder it now works.  It 
> would be nice 
> > if SER
> > didn't have that limitation but its not that big of a deal 
> because I 
> > can
> > just put an || in the if statement.
> >
> > Thanks!
> >
> > ----------------------------------------
> >
> > Michael Shuler, C.E.O.
> > BitWise Communications, Inc. (CLEC) And BitWise Systems, Inc. (ISP)
> > 682 High Point Lane
> > East Peoria, IL 61611
> > Office: (217) 585-0357
> > Cell: (309) 657-6365
> > Fax: (309) 213-3500
> > E-Mail: mike at bwsys.net
> > Customer Service: (877) 976-0711
> >
> >> -----Original Message-----
> >> From: Andrei Pelinescu-Onciul
> >> [mailto:pelinescu-onciul at fokus.fraunhofer.de]
> >> Sent: Sunday, September 26, 2004 3:14 AM
> >> To: Michael Shuler
> >> Cc: serusers at lists.iptel.org
> >> Subject: Re: [Serusers] Src_ip matching
> >>
> >>
> >> On Sep 25, 2004 at 16:45, Michael Shuler <mike at bwsys.net> wrote:
> >>>
> >>>
> >>> I have the statement:
> >>>
> >>> If(src_ip == 192.168.1.80/27)
> >>> {
> >>> 	# Do something cool
> >>> }
> >>> Else
> >>> {
> >>> 	# Don't do something cool
> >>> };
> >>>
> >>>
> >>> When the src_ip (which I verified by xlog) is 192.168.1.85
> >> it doesn't match
> >>> and goes to the else code.  Am I doing something wrong?
> >> This is on 0.8.14.
> >>>
> >>
> >> It should work (I've just checked it).
> >> Try to make a small config containing only this "if", and 
> send me the
> >> output of
> >> ./ser -ddddddddddd -c -D -E -f config_name.cfg
> >>
> >> Andrei
> >>
> >
> > _______________________________________________
> > Serusers mailing list
> > serusers at lists.iptel.org
> > http://lists.iptel.org/mailman/listinfo/serusers
> >
> >
> Greg Fausak
> www.AddaBrand.com
> (US) 469-546-1265
> 




More information about the sr-users mailing list