V
V
vanomel2012-12-07 10:36:51
Programming
vanomel, 2012-12-07 10:36:51

How to implement free wifi with ads on cisco?

There is a free Wi-Fi network, a Cisco 1841 router, Internet access and a desire to give Internet access after watching ads. I read the post "Free Wi-Fi, with a little twist" on Habré and it tells how this can be done on linux.
I have the ability to pile up a web server that does exactly the same thing. My vision is this:
The client registers in the Wi-Fi network and receives an address via DHCP from the router. When trying to access any site, he gets to a page where he watches ads and performs the specified actions, which launches a script that changes the router settings for this IP address and the client uses the full-fledged Internet.
The question is next. It is necessary to suggest how it is better to implement it, specifics are not needed, but I would not like to reinvent the wheel. How to redirect all requests of specific users over http to local server? It is necessary to be able to exclude users from this list in order to provide a full-fledged Internet.
What should you pay attention to when writing a router management script?

Answer the question

In order to leave comments, you need to log in

5 answer(s)
J
JDima, 2012-12-07
@JDima

1) The easiest way is to make two SSIDs, one for full viewing, the other for redirecting through the server.
2) Passing traffic through a proxy and back can be done using policy-based routing or by dividing into vrfs and static routes in each (but then 100% of the traffic will go through a proxy, which is also not bad in general).
If in the requirement "How to redirect all requests of certain users via http to the local server?" If you can identify "certain users" by IP address, then PBR definitely looks more interesting.
Just remember to do it both ways.

A
amario, 2012-12-07
@amario

I don't know if your wireless hardware is capable of web authentication, but that's what you want (probably).

How to redirect all requests of specific users over http to local server? It is necessary to be able to exclude users from this list in order to provide a full-fledged Internet.

"google" on the subject of dhcp option proxy server.

W
Wott, 2012-12-07
@Wott

firewall, where by default everything is forwarded to the http server, and for those who have passed “authorization” on this server, a rule is created for free access to the outside, which is killed when the address lease time expires.

C
charon, 2012-12-08
@charon

and I advise you to reconsider the idea. The foreign world is moving towards free wifi, like openwireless.org . Even Bruce Schneier wrote a few years ago that his home hotspot was open to everyone. I'm afraid that even if you succeed, soon there will be a lot of completely free points around, and yours will simply not be used.

V
vvh1te, 2013-01-11
@vvh1te

In any case, you raise linux with a web server, can it be easier to do everything on it already according to the ready-made instructions?
I can throw off the modified versions of scripts where a simple system of blocking by poppy addresses is implemented.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question