User Tools

Site Tools


сервис_captive_portal

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
сервис_captive_portal [2026/03/29 16:10]
val [Сервис Captive Portal]
сервис_captive_portal [2026/05/04 10:23] (current)
val [Services/Captive Portal]
Line 1: Line 1:
 ====== Сервис Captive Portal ====== ====== Сервис Captive Portal ======
  
-  * Captive Portal Using PHP and iptables Firewall on Linux ([[http://​aryo.info/​labs/​captive-portal-using-php-and-iptables.html]]) +===== pfSense =====
-  * Using iptables and PHP to create a captive portal ([[http://​www.andybev.com/​index.php/​Using_iptables_and_PHP_to_create_a_captive_portal]])+
  
   * [[https://​www.pfsense.org/​]]   * [[https://​www.pfsense.org/​]]
   * [[https://​ftp.fagskolen.gjovik.no/​pub/​pfSense/​]]   * [[https://​ftp.fagskolen.gjovik.no/​pub/​pfSense/​]]
   * [[https://​simplificandoredes.com/​en/​install-pfsense-on-virtualbox/​]]   * [[https://​simplificandoredes.com/​en/​install-pfsense-on-virtualbox/​]]
-===== Linux(Ubuntu) =====+ 
 +==== Базовая настройка ​==== 
 + 
 +  * По умолчанию,​ em0 WAN, em1 LAN 
 +<​code>​ 
 +Username: admin 
 +Password: pfsense 
 +Default IP: 192.168.1.1 
 + 
 +Через консоль назначаем LAN IP: 192.168.X.1/​24 
 +</​code>​ 
 + 
 +  * Подключаемся через Web и отвечаем на вопросы Визарда:​ 
 +<​code>​ 
 +Hostname: gate 
 +Domain: corpX.un 
 +Primary DNS Server: 192.168.X.10 
 +Override DNS: No 
 + 
 +Timezone: Europe/​Moscow 
 + 
 +Configure WAN Interface 
 +SelectedType:​ static 
 +IP Address: 172.16.1.X 
 +Subnet Mask: 24 
 +Add a new gateway ... 
 + 
 +Admin Password: Pa$$w0rd 
 + 
 +Services/​DNS Resolver/​General Settings/​Enable:​ false 
 +</​code>​ 
 + 
 +==== Services/​DHCP Server/LAN ==== 
 + 
 +<​code>​ 
 +Address Pool Range: 192.168.13.101 - 192.168.13.109 
 +DNS Servers: 192.168.13.10 
 +</​code>​ 
 + 
 +==== System/​Certificates/​Certificates ==== 
 + 
 +  * [[Пакет OpenSSL#​Создание самоподписанного сертификата]] wild 
 + 
 +==== System/​Advanced/​Admin Access ==== 
 + 
 +  * SSL/TLS Certificate:​ wild 
 + 
 +==== System/User Manager/​Authentication Servers ==== 
 + 
 +  * [[Сервис FreeRADIUS]] 
 + 
 +<​code>​ 
 +Descriptive name: radius server 
 +Type: RADIUS 
 +Hostname or IP address: server 
 +Shared Secret: testing123 
 +RADIUS NAS IP Attribute: LAN... 
 +</​code>​ 
 + 
 +==== Services/​Captive Portal ==== 
 + 
 +<​code>​ 
 +Interfaces: LAN 
 + 
 +Authentication Method: Authentication backend !!! По умолчанию 
 +Authentication Server: radius server 
 +NAS Identifier: gate 
 + 
 +Enable HTTPS login: yes 
 +HTTPS server name: gate.corpX.un 
 +SSL/TLS Certificate:​ wild 
 + 
 +Services/​Captive Portal/​corpX/​Allowed IP Addresses 
 +192.168.X.10 
 +</​code>​ 
 +===== Самописный вариант ===== 
 + 
 +  * Captive Portal Using PHP and iptables Firewall on Linux ([[http://​aryo.info/​labs/​captive-portal-using-php-and-iptables.html]]) 
 +  * Using iptables and PHP to create a captive portal ([[http://​www.andybev.com/​index.php/​Using_iptables_and_PHP_to_create_a_captive_portal]]) 
 + 
 +==== Linux(Ubuntu) ​====
 <​code>​ <​code>​
 root@gate:​~#​ cat nat.sh root@gate:​~#​ cat nat.sh
Line 22: Line 101:
 </​code>​ </​code>​
  
-===== FreeBSD ​=====+==== FreeBSD ====
 <​code>​ <​code>​
 gate# cat /​etc/​pf.conf gate# cat /​etc/​pf.conf
Line 31: Line 110:
 </​code>​ </​code>​
  
-===== Apache ​=====+==== Apache ====
  
 <​code>​ <​code>​
сервис_captive_portal.1774789803.txt.gz · Last modified: 2026/03/29 16:10 by val