On Fri, Apr 20, 2001 at 05:48:29AM -0400, [EMAIL PROTECTED] wrote: > I've been asked to develop something like they have in Hotels, where, > when you plug into the building Network, and fire up Nutscrape, the > only thing you can get to is a page asking you register your machine > before you can get out on the Net.
here's how i'd probably attempt to do it if i ever needed to: i'd use DHCP to assign RFC1918 private network addresses to the client machines. i'd also use squid with a flexible redirector program like squidguard. transparent proxying would also be useful to force all web traffic to go through squid. a script could monitor the DHCP leases file, and when an IP was assigned to a new MAC address, insert a squid redirection rule for that client IP to send it to your registration CGI. it would also insert a packet filter rule (ipchains or whatever) preventing that IP from getting anywhere except the proxy server. the registration CGI takes the user's details, verifies them in whatever way, and removes the squid redirection rule and the firewall block. the client machine would have to be set up as a dhcp client, and they wouldn't be able to do anything until they'd fired up a web browser and registered. craig -- craig sanders <[EMAIL PROTECTED]> GnuPG Key: 1024D/CD5626F0 Key fingerprint: 9674 7EE2 4AC6 F5EF 3C57 52C3 EC32 6810 CD56 26F0