Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Dec 2008 09:18:04 -0300
From:      Mario Lobo <mlobo@digiart.art.br>
To:        freebsd-questions@freebsd.org
Subject:   Re: Hi
Message-ID:  <200812100918.04892.mlobo@digiart.art.br>
In-Reply-To: <692660060812100307xe1ad17ax1661a18a51ecfa0@mail.gmail.com>
References:  <fdbdc4330812100144w9cd634en1a050239cc2874eb@mail.gmail.com> <fdbdc4330812100227i55eadea8r86611447c7d6f1ab@mail.gmail.com> <692660060812100307xe1ad17ax1661a18a51ecfa0@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 10 December 2008 08:07:39 Sebastian Tymk=F3w wrote:
> Hello,
>
> If you don't want to do this using server features you should do it in yo=
ur
> program
> (like in config file).
>
> Best regards,
>
> Shamrock
>
> 2008/12/10 pugal pugal <pugalanand.bsd@gmail.com>
>
> > Hi all
> > I will explain the scenario clearly.
> >
> > I have a server program say server.c listening on some XXX port-number.I
> > accepts all the client.
> >
> > Now i want to DENY only the particular client say x.x.x.x/16 .
> >
> > I want to deny that Client by not using hosts.deny.
> >
> > For this scenario what can i do?? If anyone knows Let me explain clearl=
y.
> > Since i am very new to this.please explain clearly.
> >
> > On Wed, Dec 10, 2008 at 3:43 PM, Odhiambo Washington <odhiambo@gmail.com
> >
> > >wrote:
> > >
> > >
> > >
> > > On Wed, Dec 10, 2008 at 12:44 PM, pugal pugal <pugalanand.bsd@gmail.c=
om
> > >
> > >wrote:
> > >> Hi all
> > >> Did anyone knows how to deny the TCP connection Without using
> > >> hosts.deny and ipfilter.
> > >
> > > Let the "service" listen on 127.0.0.1 or just don't start it:-)
> > >
> > >
> > > --
> > > Best regards,
> > > Odhiambo WASHINGTON,
> > > Nairobi,KE
> > > +254733744121/+254722743223
> > > _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> > > "Okay guys. This is Kenya. You pay taxes because you feel
> > > philanthropic, unlike our MPs!"
> > >                     -- Kenneth Marende, Speaker, 10th Parilament.
> >
> > --
> > Thanks
> > With Regards
> > Pugal
> >  _______________________________________________
> > freebsd-questions@freebsd.org mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> > To unsubscribe, send any mail to "
> > freebsd-questions-unsubscribe@freebsd.org"
>
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"

It seems you wrote the code, so you have the power. Just check the client's=
 IP=20
after accept()ing the connection. Then fork(), close(), etc...

=2D-=20
Mario Lobo
http://www.mallavoodoo.com.br
=46reeBSD since version 2.2.8 [not Pro-Audio.... YET!!] (99,7% winedows FRE=
E)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200812100918.04892.mlobo>