使用 .net 应用程序限制 wifi 访问
目前以下是我的 wifi 连接的设置。
笔记本电脑 1 ------>无线路由器<----- 笔记本电脑2
大约有 5 台笔记本电脑连接到 wifi 路由器来访问互联网。网络受密码保护,因此任何拥有有效网络密钥的人都可以连接和访问互联网。
我计划开发一个本地网站,其中包含用户名和密码列表。我还将删除 wifi 网络的密码,以便任何人都可以连接。
如果连接的系统尝试访问互联网中的网页,则将其重定向到登录页面(在本地网站中)并要求他们登录。成功登录后,mac id 应添加到“允许”列表中并开始监控。没有有效用户名和密码的人不应使用互联网。
我正在考虑开发应用程序来阻止/允许通过 vb.net/c# 应用程序访问互联网。
我对网站部分很满意。我想知道的是
如何通过 .net 应用程序阻止/允许互联网访问。
在 .net 中是否可能,或者我应该进行非托管代码开发吗?
如果可能的话,最好从哪里开始?我有 winforms 开发经验,但没有太多网络编程经验。
我当前的 WiFi 设置会有任何变化吗?可能是一个新的网络服务器/代理服务器来托管网站和 Windows 应用程序?
抱歉问题太多;-)
Currently following is the setup of my wifi connection.
Laptop 1 ------> Wifi Router <------
Laptop 2
There are about 5 laptops which connect to the wifi router to access internet. Network is password protected so anyone with a valid network key can connect and access internet.
I am planning to develop a local website which will be having a list of username and passwords. I will also remove the password of the wifi network so that anyone can connect.
If a connected system tries to access a web page in the internet then redirect them to a Login page (in the local website) and ask them to login. Once successfully logged i,n the mac id should be added to "Allow" list and monitoring starts. Internet should not be available for those who don't have a valid username and password.
I was thinking about developing the application to block/allow internet access though a vb.net/c# application.
I am okay with the website part. What I would like to know is
How I can block/allow internet access through the .net application.
Is it possible in .net or should I be going for an unmanaged code development?
If it is possible where is the best place to start? I have experience in winforms development but not much of network programming.
Will there be any change in my current wifi setup? May be a new webserver/proxy server which will host the website and the windows application?
Sorry about too many questions ;-)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
DD-WRT(免费固件)内置了热点,其中已经包含您想要构建的许多功能:
http://www.wi-fiplanet.com/tutorials/article.php/3730746
DD-WRT 软件运行在您可能正在使用的无处不在的 WRT54G 路由器上。
总成本:0-50 美元(取决于您是否已有 WRT54G)
DD-WRT (free firmware) has built in hotspot that already includes many of the features you are looking to build:
http://www.wi-fiplanet.com/tutorials/article.php/3730746
The DD-WRT software runs on the ubiquitous WRT54G router - which you may be using.
Total cost: $0-50 (depending on if you have a WRT54G already)
有两种方法可以实现此目的:您可以购买高级无线路由器,让您连接某种身份验证系统,或者您可以在无线路由器及其上游连接(带有两个网卡)之间使用单独的有线系统。此时,您应该能够在该系统上安装软件来管理通过该系统的流量(尽管我不直接了解您可以用于此目的的任何特定软件防火墙)
There are two ways to go about this: You can buy an advanced wireless router that lets you hook up some sort of authentication system, or you can have a separate wired system between the wireless router and its upstream connection (with two network cards). At this point, you should be able to have software on that system to manage the traffic that goes across it (although I don't have direct knowledge of any particular software firewalls that you might be able to use for this)