Community discussions

MikroTik App
 
David1234
Forum Guru
Forum Guru
Topic Author
Posts: 1424
Joined: Sun Sep 18, 2011 7:00 pm

forward users from one page to another automatically

Sun Dec 28, 2014 11:14 am

hello ,
let my explain what I want to do
I want whenever a user on my WiFi try to goto the router (10.0.0.254) on port 80 HTTP
he will get a page with my image that say "you can't go here"

can I do this without a proxy ?

only NAT to another address inside the router?

is it possible?

Thanks,
 
User avatar
ShayanFiroozi
Member Candidate
Member Candidate
Posts: 281
Joined: Sat Jun 01, 2013 12:44 pm
Location: Bandar Abbas , Iran

Re: forward users from one page to another automatically

Tue Dec 30, 2014 10:24 pm

Hi
Use IP firewall , chain = input src address : "your wifi client's network(for example 192.168.1.0/24) destination address : your router address chain drop (means kill packets and deny access to the router) or redirect (means redirect packets to any ip orport than you want !)

good luck
 
David1234
Forum Guru
Forum Guru
Topic Author
Posts: 1424
Joined: Sun Sep 18, 2011 7:00 pm

Re: forward users from one page to another automatically

Wed Dec 31, 2014 2:43 pm

Yes , it's working
Thanks !

now I want to put a HTML page when someone try to enter to router we will get my HTML page (that will be inside the router called NoEnter.html)
can I do this?

Thanks,
 
User avatar
ShayanFiroozi
Member Candidate
Member Candidate
Posts: 281
Joined: Sat Jun 01, 2013 12:44 pm
Location: Bandar Abbas , Iran

Re: forward users from one page to another automatically

Wed Dec 31, 2014 7:08 pm

i'm not sure and never done something like this , but i think the solution is to use redirect action
 
David1234
Forum Guru
Forum Guru
Topic Author
Posts: 1424
Joined: Sun Sep 18, 2011 7:00 pm

Re: forward users from one page to another automatically

Thu Jan 01, 2015 9:51 am

in the NAT or in the Filter?
also to do input\forward?

can you show me an example?

Thanks,
 
User avatar
ShayanFiroozi
Member Candidate
Member Candidate
Posts: 281
Joined: Sat Jun 01, 2013 12:44 pm
Location: Bandar Abbas , Iran

Re: forward users from one page to another automatically

Thu Jan 01, 2015 11:01 am

in Filter

Forwards means packet going through the router , input means which packet going to your router itself.

you should use input my friend :)

it's good for you : http://wiki.mikrotik.com/wiki/Manual:Packet_Flow

good luck
 
David1234
Forum Guru
Forum Guru
Topic Author
Posts: 1424
Joined: Sun Sep 18, 2011 7:00 pm

Re: forward users from one page to another automatically

Thu Jan 01, 2015 3:49 pm

but I still don't see how it help me
I still can't make a rule that said -
"if someone go to 192.168.0.254 redirect him to 192.168.0.254\NoEnter.html "
there isn't an option to do redirect ....

Thanks ,
 
ronix
Member Candidate
Member Candidate
Posts: 151
Joined: Thu Nov 17, 2011 6:51 pm

Re: forward users from one page to another automatically

Thu Jan 01, 2015 11:05 pm

I don't know if you can redirect to router it self

but you can redirect to any server in your local network
Tray this rule (in NAT before masquerade) :
/ip firewall nat
add action=dst-nat chain=dstnat comment="To My Page" dst-address=192.168.0.254 dst-port=80 protocol=tcp to-addresses=x.x.x.x to-ports=80
where x.x.x.x is your server ip
 
David1234
Forum Guru
Forum Guru
Topic Author
Posts: 1424
Joined: Sun Sep 18, 2011 7:00 pm

Re: forward users from one page to another automatically

Sun Jan 04, 2015 9:41 am

this I know how to do ,
I want to be able to redirect to a page into my router , not to another server in the network...

Thanks any way ,

Who is online

Users browsing this forum: raphaps and 20 guests