Search code examples
c#dnsdhcpcaptiveportalarsoft.tools.net

Detect hotspot usage


I need a develop captive portal for windows.

What i did?

  1. I share my ethernet connection via wireless adapter with

netsh wlan set hostednetwork mode=allow ssid=wifix key=pass1234

command.

  1. Detect connecting users (mac/ip pairing) with help of http://www.codeproject.com/Articles/20431/A-Small-DHCP-Server-Using-UDP-With-Asynchronous-Ca sample.

  2. Block or allow requests which i want with https://arsofttoolsnet.codeplex.com/

ICS Ok

DHCP Server Ok

DNS Server Ok

But i can't found how measure and limit users usage quota or set limit. What is subject should i research?

(I need windows base captive portal and i need some personal changes. So i don't want to use ready to use captive portals)


Solution

  • My solution was capturing packets with SharpPCap (using WinPCap libraries)