MikroTik – oсновна конфигурация на HotSpot

MikroTik Router

/interface bridge
add fast-forward=no name=bridge1
add fast-forward=no name=bridge2
/ip hotspot user profile
set [ find default=yes ] mac-cookie-timeout=1d shared-users=100
add mac-cookie-timeout=1d name=trial rate-limit=5M/5M shared-users=300 transparent-proxy=yes
/ip hotspot profile
add dns-name=internetportal.bg hotspot-address=192.168.4.1 http-cookie-lifetime=1d login-by=cookie,http-chap,trial name=hsprof1 trial-uptime-limit=1d trial-user-profile=trial
/ip pool
add name=dhcp_pool0 ranges=192.168.0.2-192.168.3.254
add name=dhcp_pool1 ranges=192.168.4.2-192.168.7.254
/ip dhcp-server
add address-pool=dhcp_pool0 disabled=no interface=bridge1 lease-time=1d name=dhcp1
add address-pool=dhcp_pool1 disabled=no interface=bridge2 lease-time=1d name=dhcp2
/ip hotspot
add address-pool=dhcp_pool1 disabled=no interface=bridge2 name=hotspot1 profile=hsprof1
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
add bridge=bridge1 interface=ether5
add bridge=bridge2 interface=ether6
add bridge=bridge2 interface=ether7
add bridge=bridge2 interface=ether8
add bridge=bridge2 interface=ether9
add bridge=bridge2 interface=ether10
/ip address
add address=192.168.0.1/22 interface=bridge1 network=192.168.0.0
add address=192.168.4.1/22 interface=bridge2 network=192.168.4.0
/ip dhcp-client
add dhcp-options=hostname,clientid disabled=no interface=ether1
/ip dhcp-server network
add address=192.168.0.0/22 dns-server=192.168.0.1 gateway=192.168.0.1
add address=192.168.4.0/22 dns-server=192.168.4.1 gateway=192.168.4.1
/ip dns
set allow-remote-requests=yes
/ip firewall filter
add action=drop chain=input connection-state=invalid in-interface=ether1
add action=accept chain=input in-interface=ether1 src-address=93.155.130.0/23
add action=accept chain=input connection-state=established,related in-interface=ether1
add action=accept chain=input in-interface=ether1 protocol=icmp
add action=drop chain=input in-interface=ether1
add action=drop chain=forward disabled=yes src-address=192.168.4.0/22 time=22h-0s,sun,mon,tue,wed,thu,fri,sat
add action=drop chain=forward disabled=yes src-address=192.168.4.0/22 time=0s-7h,sun,mon,tue,wed,thu,fri,sat
/ip firewall nat
add action=masquerade chain=srcnat out-interface=ether1
/ip hotspot user
add name=admin password=55556666
/ip service
set telnet disabled=yes
set www disabled=yes
set ssh port=2222
set api disabled=yes
set api-ssl disabled=yes
/system clock
set time-zone-name=Europe/Sofia
/system identity
set name=Router
/
password

MikroTik cAP ac

/interface wireless
set [ find default-name=wlan1 ] country=bulgaria ssid=WIFI
set [ find default-name=wlan2 ] country=bulgaria ssid=WIFI
/ip service
set telnet disabled=yes
set ftp disabled=yes
set www disabled=yes
set ssh port=2222
set api disabled=yes
set api-ssl disabled=yes
/system identity
set name=AP
/
password

HotSpot HTML directory

https://itservice-bg.net/wp-content/uploads/2018/12/hotspot.zip

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.