首 页 网站运营 网络编程 网页制作 图象媒体 数据库 建站资源 网管专区 下载专区 最新资讯
IT学堂|红色黑客联盟
设为首页
加入收藏
联系站长
您所在的位置:首页>网管专区>网络组建>文章内容
hosspot设置说明
来源: 作者: 发布时间:2007-04-11

参照routeros的手册,针对我的情况作了部分修改。已经在2.7.14和2.8.11上测试通过。

我的routeros是2块网卡,ether1连接adsl,做pppoe client,ether2连接局域网。
首先按照论坛上置顶的说明正确安装并配置routeros,实现客户机能够正常上网。
然后terminal routeros

改变www服务端口为8081:
/ip service set www port=8081


改变hotspot服务端口为80,为用户登录页面做准备:
/ip service set hotspot port=80


Setup hotspot profile to mark authenticated users with flow name "hs-auth":
/ip hotspot profile set default mark-flow="hs-auth" login-method=enabled-address


增加一个用户:
/ip hotspot user add name=user1 password=1



重定向所有未授权用户的tcp请求到hotspot服务
/ip firewall dst-nat add in-interface="ether2" flow="!hs-auth" protocol=tcp action=redirect
to-dst-port=80 comment="redirect unauthorized clients to hotspot service"



允许dns请求、icmp ping ;拒绝其他未经认证的所有请求:
/ip firewall add name=hotspot-temp comment="limit unauthorized hotspot clients"

/ip firewall rule forward add in-interface=ether2 action=jump
jump-target=hotspot-temp comment="limit access for unauthorized hotspot clients"

/ip firewall rule input add in-interface=ether2 dst-port=80 protocol=tcp
action=accept comment="accept requests for hotspot servlet"

/ip firewall rule input add in-interface=ether2 dst-port=67 protocol=udp
action=accept comment="accept requests for local DHCP server"

/ip firewall rule input add in-interface=ether2 action=jump
jump-target=hotspot-temp comment="limit access for unauthorized hotspot clients"

/ip firewall rule hotspot-temp add flow="hs-auth" action=return
comment="return if connection is authorized"

/ip firewall rule hotspot-temp add protocol=icmp action=return
comment="allow ping requests"

/ip firewall rule hotspot-temp add protocol=udp dst-port=53 action=return
comment="allow dns requests"

/ip firewall rule hotspot-temp add action=reject
comment="reject access for unauthorized clients"


创建hotspot通道给认证后的hotspot用户
Create hotspot chain for authorized hotspot clients:
/ip firewall add name=hotspot comment="account authorized hotspot clients"


Pass all through going traffic to hotspot chain:
/ip firewall rule forward add action=jump jump-target=hotspot
comment="account traffic for authorized hotspot clients"



客户机输入任何网址,都自动跳转到登陆页面,输入账号密码,继续浏览。
如果使用ftp、pop3等,也必须先通过网页登录,才可以使用,当然使用winbox的时候也必须先登录。


[推荐] [返回顶部] [打印本页] [关闭窗口]
热点文章
·动态域名更新的实现方法
·site to site ipsec vpn
·设置ROUTEROS为透明桥接防火墙
·虚拟路由冗余协议 Virtual Router Red
·使用ROUTEROS建立PPPOE服务器
·如何在ROUTEOS中做IP转向
·ROS下实现数据镜像
·routeros和radius对接设置
·routeros端口映射内网无法访问自身公
·ROS2.9做策略路由的各种应用方法+自
相关文章
·site to site ipsec vpn
·设置ROUTEROS为透明桥接防火墙
·动态域名更新的实现方法
·虚拟路由冗余协议 Virtual Router Red
·使用ROUTEROS建立PPPOE服务器
·如何在ROUTEOS中做IP转向
·ROS下实现数据镜像
·routeros和radius对接设置
·routeros端口映射内网无法访问自身公
·ROS2.9做策略路由的各种应用方法+自
文章检索
Google
相关文章
·site to site ipsec vpn
·设置ROUTEROS为透明桥接
·动态域名更新的实现方法
·虚拟路由冗余协议 Virtu
·使用ROUTEROS建立PPPOE
·如何在ROUTEOS中做IP转
·ROS下实现数据镜像
·routeros和radius对接设
·routeros端口映射内网无
·ROS2.9做策略路由的各种
·制作串口控制RouterOS连
·routeros保证和按优先级
·RouterOS多区域VPN设置
·ROS2.96脚本详解
·基于IPIP连接方式的虚拟