Welcome Page before start browsing

i want to set the Welcome page on browsing.
like, when users start browsing the browser displayed the welcome page first then go for the requested page.

( i m using transperant proxy with Dhcp, i need this in same server, not want to go for hotspot)


I hope Experts can guide soon.

Thanks.

is it possible.?

The basic solution I’m aware of for this is to redirect users that aren’t on an address list yet to the proxy, which is configured to deny all proxying with a redirect action to the welcome page. At the same time the user is added to an address list with a timeout of whatever you choose. After that the user is on the address list and isn’t proxied, until he expires and is shown the welcome page again.

Since you’re already using the proxy and don’t want to use a Hotspot I don’t see how you can make that work, unless you’re able to introduce a second proxy to your environment that could be used for the above.

Fewi, Thanks for considering my issue.

if this is possible to make users go through welcome page to internet, then please tell me the process to aquire the solution.
as i already tell u that i m using transperant proxy and dhcp.

i hope by the help of Experts i will able to get my require function.
Thanks

waiting for experts suggestions…

Personally, I would use the Hotspot (not for authentication) for the Advertise-Url feature. This let’s you display any url to the user, and checks that the user’s browser received it, then it continues to the internet. You could set the timeout and intervals as well.

As fewi mentioned though, some simple web proxy rules could do the trick.

It all depends on what exactly you want, and how much configuration you’re willing to do. You can do quite a bit of “out of the box” thinking with Mikrotik, it just takes an idea to make it happen.

Still Waiting

“i want to set the Welcome page on browsing.
like, when users start browsing the browser displayed the welcome page first then go for the requested page.”

Do you mean every time they connect to the wireless, or just the first time ?

just one time in 24 hours.

i mean after every 24 hours. the welcome page displayed to the clients before they go for the internet.

i hope i will get this option soon by the help of Experts.

Thanks

use hotspot to do this

is this possible in Webproxy?



As described, yes it is, but only if you aren’t using the web proxy for anything else. You are, according to your initial post. So you have the following options:
a) use Hotspot
b) stop using the web proxy for general proxying and only use it for a welcome page
c) introduce a second proxy (squid?) and use it for proxying, and the built in proxy for the welcome page, though this may be difficult to get right

You can still use Web Proxy for both at the same time.

Say your web-proxy listens on port 8080 for normal traffic. All your normal traffic goes to web proxy on port 8080.

Then, all you have to do is add a second port for web proxy to listen on, say 8081.

Here is how your rules would look:

/ip proxy set port="8080,8081"

Then configure the proxy access to deny->redirect traffic coming in on port 8081:

/ip proxy access add action=deny disabled=no local-port=8081 redirect-to=<domain name>/<web page>.html

Then, configure NAT to redirect specified traffic you want redirected, to port 8081:

/ip firewall nat add chain=dstnat action=redirect to-ports=8081 <other options>

Hope this makes sense. I just wanted to clarify that you can use the web proxy for multiple tasks by using the ‘local-port’ setting in a proxy rule.

In general though, for the OP’s question, the Hotspot would be a perfect fit for your scenario.

In my scenario, I use ip proxy only to redirect users browser first connection.

routerOS version : 3.30
welcome page site : www.yourdomain.com
welcome page ip addr : 3.3.3.3

/ip proxy set enable=yes port="3128"

/ip proxy access add disabled=no action=deny dst-port=80 redirect-to=www.yourdomain.com

/ip firewall nat add chain=dstnat action=redirect to-ports=3128 protocol=tcp dst-port=80
dst-address=!3.3.3.3 src-address-list=!welcome_trap 

/ip firewall mangle add chain=postrouting action=add-src-to-address-list 
address-list=welcome_trap address-list-timeout=7h  protocol=tcp dst-port=80 src-address-list=!welcome_trap dst-address=3.3.3.3

i use 7 hours for address-list-timeout option, this imply users ip address deleted from welcome_trap address list after 7 hours and make browser to redirect to welcome page again.

However its work for me
sorry for my bad english
greetings from Indonesia

:slight_smile:

Hello,

I did everything like ellozius suggested.
Still does’nt work. Please see my config if you spot any mistakes:

# may/07/2015 14:50:16 by RouterOS 6.28
#
/interface wireless
set [ find default-name=wlan1 ] l2mtu=2290
/ip pool
add name=dhcp_pool1 ranges=10.10.0.20-10.10.0.254
/ip dhcp-server
add address-pool=dhcp_pool1 disabled=no interface=ether2 lease-time=3d name=\
    dhcp1
/ip address
add address=1.0.0.222/24 interface=ether1 network=1.0.0.0
add address=10.10.0.1/24 interface=ether2 network=10.10.0.0
/ip dhcp-server network
add address=10.10.0.0/24 gateway=10.10.0.1
/ip dns
set allow-remote-requests=yes servers=8.8.8.8
/ip firewall mangle
add action=add-src-to-address-list address-list=tervitusleht \
    address-list-timeout=7h chain=postrouting dst-address=195.50.209.244 \
    dst-port=80 protocol=tcp \
    src-address-list=!tervitusleht
/ip firewall nat
add action=redirect chain=dstnat dst-address=195.50.209.244 dst-port=80 \
    protocol=tcp src-address-list=!tervitusleht to-ports=3128
add action=masquerade chain=srcnat out-interface=ether1
/ip proxy
set enabled=yes port=3128
/ip proxy access
add action=deny dst-port=80 redirect-to=www.neti.ee
/ip route
add distance=1 gateway=1.0.0.254
/romon port
add disabled=no
/system clock
set time-zone-name=Europe/Tallinn
/system leds
set 0 interface=wlan1

Thanks