Overview
Features
Download
Documentation
Community
Add-Ons & Services

access avoidance

Please post support and help requests here.

access avoidance

Postby Hellbard » 13 Apr 2007, 12:35

Hi , I am working on HTTP server and I need some access avoidance. I need to block some IP to access my server. Is here any chance to do it with this library?
Hellbard
 
Posts: 12
Joined: 16 Mar 2007, 11:21

Re: access avoidance

Postby guenter » 13 Apr 2007, 13:40

You can check the client's IP address in your HTTPRequestHandlerFactory. The IP address of the client can be obtained by using the clientAddress() member function of HTTPServerRequest. You can then check the client address agains a list of addresses, or against a certain subnet. If the client address is valid, return a new request handler. Otherwise return 0.
guenter
 
Posts: 1107
Joined: 11 Jul 2006, 16:27
Location: Austria

Re: Re: access avoidance

Postby Hellbard » 15 Apr 2007, 21:30

> You can check the client's IP address in your HTTPRequestHandlerFactory. The IP address of the client can be obtained by using the clientAddress() member function of HTTPServerRequest. You can then check the client address agains a list of addresses, or against a certain subnet. If the client address is valid, return a new request handler. Otherwise return 0.
>

Thanks for your reply.
Hellbard
 
Posts: 12
Joined: 16 Mar 2007, 11:21


Return to Support

Who is online

Users browsing this forum: No registered users and 2 guests