<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.edge.arista.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Mahotz</id>
	<title>Edge Threat Management Wiki - Arista - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.edge.arista.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Mahotz"/>
	<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Special:Contributions/Mahotz"/>
	<updated>2026-04-04T08:00:55Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.3</generator>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20930</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20930"/>
		<updated>2017-10-09T22:43:57Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Session Redirect */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Use hostname instead of IP address for the capture page redirect&#039;&#039;&#039;: Create the browser redirect using the hostname instead of the IP address of the server.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Always redirect to the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20929</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20929"/>
		<updated>2017-10-09T22:43:01Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Session Redirect */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Use hostname instead of IP address for the capture page redirect&#039;&#039;&#039;: Create the browser redirect using the hostname instead of the IP address of the server.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20928</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20928"/>
		<updated>2017-10-09T22:41:09Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Session Redirect */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20927</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20927"/>
		<updated>2017-10-09T22:39:18Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20926</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20926"/>
		<updated>2017-10-09T22:39:02Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20925</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20925"/>
		<updated>2017-10-09T22:38:46Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20923</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20923"/>
		<updated>2017-10-09T22:38:04Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20922</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20922"/>
		<updated>2017-10-09T22:37:10Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for User Authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the agree checkbox and text will be used when generating the OAuth provider selection page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20921</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20921"/>
		<updated>2017-10-09T22:35:44Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the Agree checkbox and text will be used when generating the provider selection page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20920</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20920"/>
		<updated>2017-10-09T22:34:52Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Captive Page */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; When using &#039;Any OAuth provider&#039; for authentication, you should select &#039;Basic Message&#039;. All of the &#039;Page Configuration&#039; options except for the Agree checkbox and text will be used when generating the provider selection page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20919</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20919"/>
		<updated>2017-10-09T22:29:49Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* User Authentication */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page where they will click the icon or link corresponding to the provider account they wish to use.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20918</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=20918"/>
		<updated>2017-10-09T22:27:25Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* User Authentication */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Google Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Google account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Facebook Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Facebook account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Microsoft Account&#039;&#039;&#039;: can be used to allow users to authenticate via OAuth using a Microsoft account.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any OAuth Provider&#039;&#039;&#039;: can be used to allow users to select and authenticate using any of the supported OAuth providers. When this option is selected, unauthenticated users will first encounter the OAuth selection page.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=17641</id>
		<title>Captive Portal</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=Captive_Portal&amp;diff=17641"/>
		<updated>2017-10-09T22:17:39Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* User Authentication */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal&amp;quot;&amp;gt;Captive_Portal&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_status&amp;quot;&amp;gt;Captive_Portal#Status&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_capture_rules&amp;quot;&amp;gt;Captive_Portal#Capture_Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_passed_hosts&amp;quot;&amp;gt;Captive_Portal#Passed_Hosts&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_captive_page&amp;quot;&amp;gt;Captive_Portal#Captive_Page&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_authentication&amp;quot;&amp;gt;Captive_Portal#User_Authentication&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_user_event_log&amp;quot;&amp;gt;Captive_Portal#User_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource captive_portal_rule_event_log&amp;quot;&amp;gt;Captive_Portal#Rule_Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:CaptivePortal_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;Captive Portal&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/captive-portal.html Captive Portal Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://demo.untangle.com/admin/index.do#apps/1/captive-portal Captive Portal Demo]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/captive-portal/ Captive Portal Forums]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[Captive Portal FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About Captive Portal ==&lt;br /&gt;
&lt;br /&gt;
Captive Portal allows administrators to require network users to log in or accept a network usage policy before accessing the internet. Captive Portal can authenticate users against Untangle&#039;s built-in [[Local Directory]], Active Directory (if [[Directory Connector]] is installed), or RADIUS. It can be used to set up policies (for [[Policy Manager]]) by username (or group name if using Active Directory) rather than IP. While Captive Portal is running, &#039;&#039;&#039;captured&#039;&#039;&#039; machines will be forced to authenticate (or just press OK) on the Captive Portal page before they are able to access the internet.&lt;br /&gt;
&lt;br /&gt;
Captive Portal is a common technique used to identify users on the network as describe in [[User Management]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Getting Started with Captive Portal ===&lt;br /&gt;
&lt;br /&gt;
After installing Captive Portal, complete the following steps to get it working:&lt;br /&gt;
&lt;br /&gt;
# Define which machines will be &#039;&#039;&#039;captured&#039;&#039;&#039; and required to complete the Captive Portal process before accessing the Internet - enabling the first example rule in the Capture Rules table will force all machines on the internal interface to use Captive Portal.&lt;br /&gt;
# Enter any IPs that unauthenticated machines will need to access - these can be entered in the &#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Enter any IPs that always need access to the internet - these can be entered in the &#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039; section of the &#039;&#039;&#039;Passed Hosts&#039;&#039;&#039; tab.&lt;br /&gt;
# Customize the Captive Portal page on the &#039;&#039;&#039;Captive Page&#039;&#039;&#039; tab. If &#039;&#039;&#039;Basic Login&#039;&#039;&#039; is chosen, set the appropriate authentication method for users on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
# Turn on Captive Portal.&lt;br /&gt;
&lt;br /&gt;
At this point Captive Portal will evaluate your &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; and any traffic that matches will be stopped until that user has completed the Captive Portal process.&lt;br /&gt;
&lt;br /&gt;
== Settings ==&lt;br /&gt;
&lt;br /&gt;
This section reviews the different settings and configuration options available for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
This tab shows the current status of Captive Portal. You can see information about current captured IPs, such as the username and other session information.  You can also logout any active session.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|status}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Capture Rules ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Capture Rules&#039;&#039;&#039; tab allows you to specify rules to Capture or Pass traffic that crosses the Untangle.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured.  Captive Portal uses rules to determine whether to capture or pass each network session.  The rules are evaluated in order, and on the first match, the configured action will be applied.  If no rules match, the traffic is allowed by default.  Once a client has completed the authentication process configured in Captive Portal, all traffic for that client is allowed to pass.  Once the client logs out or expires, the rules will again be applied.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|capture-rules}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Passed Hosts ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Pass Hosts&#039;&#039;&#039; tab allows you to specify machines that either &#039;&#039;&#039;a)&#039;&#039;&#039; should not be affected by Captive Portal, or &#039;&#039;&#039;b)&#039;&#039;&#039; servers that machines behind Captive Portal should be able to access even if unauthenticated.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Client Addresses&#039;&#039;&#039;: These machines will not be affected by Captive Portal. This is useful for servers and devices without browsers.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Pass Listed Server Addresses&#039;&#039;&#039;: Machines behind Captive Portal will be able to access these servers whether or not they have authenticated through Captive Portal. Typically these will be any DNS or DHCP servers that are separated from their clients by Untangle. If Untangle is handling DHCP or DNS, this is not necessary.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|passed-hosts}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Captive Page ===&lt;br /&gt;
&lt;br /&gt;
This tab controls the type of Captive Portal page displayed to unauthenticated users. Please note that you can use HTML in the Captive Portal page fields, however invalid HTML will prevent the page from properly rendering.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Message&#039;&#039;&#039;: Select this option if users should see (or accept) a message before being allowed to the internet. It has several tunable properties such as &#039;&#039;&#039;Page Title,&#039;&#039;&#039; &#039;&#039;&#039;Welcome Text,&#039;&#039;&#039; &#039;&#039;&#039;Message Text&#039;&#039;&#039; and &#039;&#039;&#039;Lower Text&#039;&#039;&#039;. If &#039;&#039;&#039;Agree Checkbox&#039;&#039;&#039; is enabled, users must check a checkbox (labeled with the &#039;&#039;&#039;Agree Text&#039;&#039;&#039;) before continuing.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Basic Login&#039;&#039;&#039;: Select this option if users should see a page that requires them to login. Similar to &#039;&#039;&#039;Basic Message&#039;&#039;&#039;, it has several properties that can be configured. When the login/continue button on the page is clicked the user will be authenticated. You&#039;ll also need to set your authentication method on the &#039;&#039;&#039;User Authentication&#039;&#039;&#039; tab.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Custom&#039;&#039;&#039;: Select this option if you would like to upload a custom Captive Portal page. This is for experienced web developers that are comfortable with HTML, Python and JavaScript - Untangle Support department can not help with development of custom Captive Portal pages. If &#039;&#039;&#039;Custom&#039;&#039;&#039; is selected it is advised to turn off automatic upgrades - newer versions of Untangle may be incompatible with any custom captive page.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|captive-page}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== HTTPS/Root Certificate Detection =====&lt;br /&gt;
&lt;br /&gt;
This feature checks if the root certificate is installed on the client machine. If the root certificate is not installed, you have the option to display a warning or block the connection. The [[Certificates#Certificate_Authority|root certificate]] used by HTTPS Inspector and other HTTPS connections to the unit including Captive Portal. This feature is highly recommended if you have HTTPS installed. The [[Certificates#Server_Certificate|server certificate]] must have all the names and IP address used on the Untangle.  &lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Disable Certificate Detection&#039;&#039;&#039;: No checking for the root certificate.&lt;br /&gt;
*&#039;&#039;&#039;Check Certificate. Show warning when not detected&#039;&#039;&#039;: Checks the root certificate. If not found, displays a warning with instructions to install the certificate. &lt;br /&gt;
*&#039;&#039;&#039;Require Certificate. Prohibit login when not detected&#039;&#039;&#039;: Checks the root certificate. If the root certificate is not found, the connection is blocked and the client is given instructions to install the certificate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Preview Captive Portal Page&#039;&#039;&#039; button can be used to view what the configured captive page looks like. This button only works when Captive Portal in on.&lt;br /&gt;
&lt;br /&gt;
===== Session Redirect =====&lt;br /&gt;
&lt;br /&gt;
HTTPS Captive Portal &lt;br /&gt;
*&#039;&#039;&#039;Always use HTTPS for the capture page redirect&#039;&#039;&#039;: Requires use of the HTTPS version of the login page when using Captive Portal.&lt;br /&gt;
Redirect URL&lt;br /&gt;
* &#039;&#039;&#039;Redirect URL&#039;&#039;&#039;: Users will be rerouted to this site after successful authentication. If &#039;&#039;&#039;Redirect URL&#039;&#039;&#039; is blank they will be sent to the original destination.&lt;br /&gt;
:Make sure to enter a complete url (e.g. &amp;lt;nowiki&amp;gt;http://www.untangle.com&amp;lt;/nowiki&amp;gt;) or this setting will not properly operate.&lt;br /&gt;
&lt;br /&gt;
=== Custom Pages ===&lt;br /&gt;
&lt;br /&gt;
There are two levels for customizing the Captive Portal capture page.  One is fairly easy and the other is more complex.&lt;br /&gt;
&lt;br /&gt;
For the easy method, you create a custom.html file and place it along with any supporting image files, etc. into a zip file, and then upload the file via the administrative interface.  This allows you to customize the look and layout of the page while leveraging the existing code and application settings.  To use this model, you need to be familiar with HTML and forms.  We have created two examples that each include a simple and well documented custom.html file to help you get started.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom login text&lt;br /&gt;
| [[Media:Custom_login.zip | custom_login.zip]]&lt;br /&gt;
| [[File:Cp-custom-login-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom agree text&lt;br /&gt;
| [[Media:Custom_agree.zip | custom_agree.zip]]&lt;br /&gt;
| [[File:Cp-custom-agree-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The more difficult method also gives you the most flexibility, as your custom zip will include a custom.py Python script.  This gives you the ability to perform any kind of authentication or validation you wish.  To use this model, you should be fluent in Python programming, and experience with mod_python will also be helpful.  Listed are some examples that include documented custom.py files you can use as a guide to see how it works and what is possible.&lt;br /&gt;
&lt;br /&gt;
{| border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
|+&lt;br /&gt;
! Description !! Download !! Screenshot&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;width: 80%;&amp;quot; | Custom hotel login screen, where the user must enter a room number.&lt;br /&gt;
| [[Media:Custom_hotel.zip | custom_hotel.zip]]&lt;br /&gt;
| [[File:Cp-custom-hotel-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page with restricted number of logins. Useful for limiting users to X hrs or X logins per day.&lt;br /&gt;
| [[Media:Custom_logincount.zip | custom_logincount.zip]]&lt;br /&gt;
| [[File:Cp-custom-logincount-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to create new accounts on the fly.&lt;br /&gt;
| [[Media:Custom_registration.zip | custom_registration.zip]]&lt;br /&gt;
| [[File:Cp-custom-registration-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| Custom page allowing users to use paypal to pay for internet&lt;br /&gt;
| [[Media:Custom_paypal.zip | custom_paypal.zip]]&lt;br /&gt;
| [[File:Cp-custom-paypal-page.jpg|50px|thumb|left|screenshot]] &lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=== User Authentication ===&lt;br /&gt;
&lt;br /&gt;
This section controls how users will be authenticated if the &#039;&#039;&#039;Basic Login&#039;&#039;&#039; page is used.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;None&#039;&#039;&#039;: is used in the case where no login is required.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Local Directory&#039;&#039;&#039;: Use the Untangle&#039;s built-in Local Directory (&#039;&#039;&#039;Config &amp;gt; Local Directory&#039;&#039;&#039;) to authenticate users.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;RADIUS&#039;&#039;&#039;: Use an external RADIUS server to authenticate users. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Active Directory&#039;&#039;&#039;: can be used if user should be authenticated against an Active Directory server. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Any Directory Connector&#039;&#039;&#039;: can be used to allow users to authenticate against any of the configured and enabled Directory Connector methods. &#039;&#039;This option requires Directory Connector to be installed and enabled and configured.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Session Settings&#039;&#039;&#039; section controls the timeout and concurrent login settings for Captive Portal.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Idle Timeout&#039;&#039;&#039;: This option controls the amount of time before a host is automatically logged out if no traffic is seen. While a machine may be idle, it is still active on the network level. In this case &#039;&#039;&#039;Idle&#039;&#039;&#039; means no new TCP or UDP connections are seen by the Captive Portal. &#039;&#039;&#039;IMPORTANT: It is recommended to leave this at zero (not enabled).&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Timeout&#039;&#039;&#039;: This option controls the amount of time before a computer will be automatically logged out. After this the user must log in again through Captive Portal.  Timeouts greater than 1440 minutes (1 day) is &#039;&#039;&#039;not recommended&#039;&#039;&#039;. The authenticated table is store in memory and will be flushed on reboot/upgrade. Additionally, the logout time should also be shorter than your DHCP lease time to assure IPs don&#039;t change before the Captive Portal timeout.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Concurrent Logins&#039;&#039;&#039;: This option controls if multiple machines can use the same login credentials simultaneously. If enabled, two or more users can login with the same username/password at the same time.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Allow Cookie-based authentication&#039;&#039;&#039;: When enabled, a cookie is added to the users browser and used to authenticate the user in future sessions. Cookies must be allowed by the browser and not cleared when closing the browser or by other security programs. When the Cookie timeout is reached the user is forced to re-authenticate (regardless of activity). The default is 24 hours.&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Track logins using MAC address&#039;&#039;&#039;: When enabled, Captive Portal will use the MAC address instead of IP address to identify the client machine. If the MAC address for a given IP address is not known it will revert to using an IP address. This option is useful on smaller flat networks where Untangle is on the same network segment as all the hosts, and you have a very long timeout period such that a client&#039;s IP address might change.&lt;br /&gt;
&lt;br /&gt;
{{AppScreenshot|captive-portal|user-authentication}}&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Related Topics ==&lt;br /&gt;
&lt;br /&gt;
[[Directory_Connector|Directory Connector]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Captive Portal FAQs ==&lt;br /&gt;
&lt;br /&gt;
{{:Captive Portal FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16844</id>
		<title>File:1200x800 apps captive-portal user-authentication.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16844"/>
		<updated>2017-10-09T22:10:55Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: Mahotz uploaded a new version of File:1200x800 apps captive-portal user-authentication.png&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Importing file&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16843</id>
		<title>File:1200x800 apps captive-portal user-authentication.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16843"/>
		<updated>2017-10-09T22:10:41Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: Mahotz uploaded a new version of File:1200x800 apps captive-portal user-authentication.png&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Importing file&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16842</id>
		<title>File:1200x800 apps captive-portal user-authentication.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=File:1200x800_apps_captive-portal_user-authentication.png&amp;diff=16842"/>
		<updated>2017-10-09T22:10:14Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: Mahotz uploaded a new version of File:1200x800 apps captive-portal user-authentication.png&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Importing file&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
	<entry>
		<id>https://wiki.edge.arista.com/index.php?title=SSL_Inspector&amp;diff=3761</id>
		<title>SSL Inspector</title>
		<link rel="alternate" type="text/html" href="https://wiki.edge.arista.com/index.php?title=SSL_Inspector&amp;diff=3761"/>
		<updated>2016-03-03T01:28:45Z</updated>

		<summary type="html">&lt;p&gt;Mahotz: /* Configuration */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Applications]]&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource https_inspector&amp;quot;&amp;gt;SSL_Inspector&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource https_inspector_configuration&amp;quot;&amp;gt;SSL_Inspector#Configuration&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource https_inspector_rules&amp;quot;&amp;gt;SSL_Inspector#Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource https_inspector_event_log&amp;quot;&amp;gt;SSL_Inspector#Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource ssl_inspector&amp;quot;&amp;gt;SSL_Inspector&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource ssl_inspector_configuration&amp;quot;&amp;gt;SSL_Inspector#Configuration&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource ssl_inspector_rules&amp;quot;&amp;gt;SSL_Inspector#Rules&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;display:none&amp;quot; class=&amp;quot;helpSource ssl_inspector_event_log&amp;quot;&amp;gt;SSL_Inspector#Event_Log&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| width=&#039;100%&#039;&lt;br /&gt;
|-&lt;br /&gt;
| align=&amp;quot;center&amp;quot; | [[Image:SSLInspector_128x128.png]] &amp;amp;nbsp; &amp;amp;nbsp; &#039;&#039;&#039;SSL Inspector&#039;&#039;&#039;&lt;br /&gt;
| align=&amp;quot;center&amp;quot; |&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Other Links:&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/https-inspector.html SSL Inspector Description Page]&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.untangle.com/store/https-inspector.html SSL Inspector Screenshots]&lt;br /&gt;
|-&lt;br /&gt;
|[http://forums.untangle.com/https-inspector/ SSL Inspector]&lt;br /&gt;
|-&lt;br /&gt;
|[[SSL Inspector Reports]]&lt;br /&gt;
|-&lt;br /&gt;
|[[SSL Inspector FAQs]]&lt;br /&gt;
|}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
= About SSL Inspector =&lt;br /&gt;
&lt;br /&gt;
The SSL Inspector is a special application that allows other Untangle applications that&lt;br /&gt;
process HTTP traffic to also process encrypted HTTPS traffic and applications that process SMTP to also process SMTP over SSL.&lt;br /&gt;
It does this by performing man-in-the-middle decryption and encryption of SSL traffic, passing the unencrypted traffic through the Untangle&lt;br /&gt;
server for inspection by other applications and services.&lt;br /&gt;
&lt;br /&gt;
When a client makes an HTTPS request, the Inspector first initiates a secure SSL connection with the external&lt;br /&gt;
server on behalf of the client.  While this session is being established, the inspector captures information about&lt;br /&gt;
the server SSL certificate.  Once the server session is active, the Inspector uses the details from the server&lt;br /&gt;
certificate to create a new certificate that will be used to encrypt the session between the inspector and the&lt;br /&gt;
client.  This certificate is generated or loaded on the fly, and is created using the same subject details&lt;br /&gt;
contained in the actual server certificate.  The certificate is then signed by the internal CA on the Untangle&lt;br /&gt;
server, and is used to establish a secure connection between the inspector and the client.  Creating the&lt;br /&gt;
certificate this way is necessary to eliminate security warnings on the client, but it does require a&lt;br /&gt;
few extra steps to properly configure the client computers and devices on your network.  See the&lt;br /&gt;
[[#SSL Certificates|SSL Certificates]] section below for details.&lt;br /&gt;
&lt;br /&gt;
= SSL Certificates =&lt;br /&gt;
&lt;br /&gt;
SSL Certificates serve two primary purposes.  They allow traffic between the client and server to be&lt;br /&gt;
encrypted, and they allow the client to validate the authenticity of the server.  There are two main ways&lt;br /&gt;
the client checks the authenticity of the server certificate.  The first is by validating the server certificate&lt;br /&gt;
to ensure it has been issued or signed by a known and trusted third party certificate authority.  Once that&lt;br /&gt;
trust has been established, the client checks the server name portion of the target URL to ensure it matches&lt;br /&gt;
the server name registered in the certificate presented by the server.  If either of these checks fail, the&lt;br /&gt;
client will typically display a warning, indicating that the security of the connection may be compromised.&lt;br /&gt;
&lt;br /&gt;
When the Untangle server is initially installed, a default Certificate Authority is created automatically&lt;br /&gt;
and used to sign the man-in-the-middle certificates created by the SSL Inspector.  To view or make changes&lt;br /&gt;
to the internal Certificate Authority, check out Certificates tab of the Config/Administration page.&lt;br /&gt;
&lt;br /&gt;
[[Config]] &amp;gt; [[Administration]] &amp;gt; [[Certificates]]&lt;br /&gt;
&lt;br /&gt;
== Client Configuration ==&lt;br /&gt;
&lt;br /&gt;
For the client authenticity checks to be successful, the client must be configured to trust the root&lt;br /&gt;
certificate used by the Untangle server to sign the man-in-the-middle certificates described above.&lt;br /&gt;
To configure clients, you must first use the [[#Download Root Certificate|Download Root Certificate]]&lt;br /&gt;
button located on the [[#Configuration|Configuration]] tab of SSL Inspector Settings page to download&lt;br /&gt;
the root certificate.  You must then install this certificate in correct the location on the client.&lt;br /&gt;
&lt;br /&gt;
Another way to download the root certificate is to simply access a special URL using the IP address of the Untangle server:&lt;br /&gt;
&lt;br /&gt;
 http://0.0.0.0/cert&lt;br /&gt;
&lt;br /&gt;
Simply replace 0.0.0.0 with the IP address of your Untangle server.  This method is especially useful when using mobile devices.  For example, accessing this URL on an iPad or iPhone will download and display the certificate, and provide an option to install and trust the certificate directly on the device.&lt;br /&gt;
&lt;br /&gt;
Below are basic instructions for installing the root certificate on some common client platforms.  If yours is not listed, or you have any difficulty, consult the reference material for the target platform for further information.&lt;br /&gt;
&lt;br /&gt;
=== Internet Explorer or Google Chrome on Microsoft Windows ===&lt;br /&gt;
&lt;br /&gt;
# Log into the Untangle server running SSL Inspector.&lt;br /&gt;
# Go to Settings/Configuration and download the certificate using the &amp;quot;Download Root Certificate&amp;quot; button.&lt;br /&gt;
# Copy the root_authority.crt you just downloaded to the Windows client computer.&lt;br /&gt;
# From a command prompt, or from Start/Run, run the command &amp;quot;certmgr.msc&amp;quot;.&lt;br /&gt;
# Open the &amp;quot;Trusted Root Certification Authorities&amp;quot; tree in the panel on the left.&lt;br /&gt;
# Right click on &amp;quot;Certificates&amp;quot; and select All Tasks --&amp;gt; Import.&lt;br /&gt;
# Proceed with the Certificate Import Wizard, selecting the the root_authority.crt file.&lt;br /&gt;
&lt;br /&gt;
=== Firefox on Microsoft Windows ===&lt;br /&gt;
&lt;br /&gt;
# Log into the Untangle server running SSL Inspector.&lt;br /&gt;
# Go to Settings/Configuration and download the certificate using the &amp;quot;Download Root Certificate&amp;quot; button.&lt;br /&gt;
# Copy the root_authority.crt you just downloaded to the Windows client computer.&lt;br /&gt;
# Launch Firefox&lt;br /&gt;
# From the Tools menu, go to Options -&amp;gt; Advanced -&amp;gt; Encryption -&amp;gt; View Certificates -&amp;gt; Authorities (**On version 41+ of Firefox ** From the Tools menu, go to Options -&amp;gt; Advanced -&amp;gt; View Certificates)&lt;br /&gt;
# Click the Import button and select the root_authority.crt file.&lt;br /&gt;
# Enable the &amp;quot;Trust this CA to identify websites&amp;quot; checkbox and click the OK button.&lt;br /&gt;
&lt;br /&gt;
=== Opera on Microsoft Windows ===&lt;br /&gt;
&lt;br /&gt;
# Log into the Untangle server running SSL Inspector.&lt;br /&gt;
# Go to Settings/Configuration and download the certificate using the &amp;quot;Download Root Certificate&amp;quot; button.&lt;br /&gt;
# Copy the root_authority.crt you just downloaded to the Windows client computer.&lt;br /&gt;
# Launch Opera&lt;br /&gt;
# From the Tools menu, go to Preferences -&amp;gt; Advanced -&amp;gt; Security and click Manage Certificates&lt;br /&gt;
# Select the Authorities tab, click Import, and select the root_authority.crt file.&lt;br /&gt;
# Click Install and click OK when asked if you are sure you want to trust the certificate.&lt;br /&gt;
&lt;br /&gt;
== Group Policy Distribution ==&lt;br /&gt;
&lt;br /&gt;
If you have a fully deployed and implemented Active Directory infrastructure, you can leverage&lt;br /&gt;
the Group Policy model to distribute the Untangle root certificate to all of your client computers.&lt;br /&gt;
This is way outside our own area of expertise, so we can&#039;t provide much help or assistance, but we&lt;br /&gt;
have compiled links to some TechNet articles with instructions for several common versions&lt;br /&gt;
of Windows Server.&lt;br /&gt;
&lt;br /&gt;
[http://technet.microsoft.com/en-us/library/cc782744.aspx Windows Server 2003]&lt;br /&gt;
&lt;br /&gt;
[http://technet.microsoft.com/en-us/library/cc731253.aspx Windows Server 2008]&lt;br /&gt;
&lt;br /&gt;
[http://technet.microsoft.com/en-us/library/dd807084.aspx Windows Server 2012]&lt;br /&gt;
&lt;br /&gt;
= Settings =&lt;br /&gt;
&lt;br /&gt;
This section describes the different settings and configuration options available for SSL Inspector.&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
=== Download Root Certificate ===&lt;br /&gt;
&lt;br /&gt;
As described above, client computers and devices on your network need to be configured to trust the&lt;br /&gt;
root certificate of the Untangle server.  Clicking this button will allow you to download the root&lt;br /&gt;
certificate.  Once downloaded, you need to install it in the Trusted Authorities certificate store&lt;br /&gt;
on your client computers and devices.  Note that this is the same root certificate that can be downloaded&lt;br /&gt;
from the [[Config]] &amp;gt; [[Administration]] &amp;gt; [[Certificates]] page.  The download link is included&lt;br /&gt;
on the SSL Inspector Configuration page for convenience.&lt;br /&gt;
&lt;br /&gt;
=== Download Root Certificate Installer ===&lt;br /&gt;
&lt;br /&gt;
Click this button to download a Windows installer that will automatically and properly install the root certificate for most popular web browsers that are installed and detected on the computer.&lt;br /&gt;
&lt;br /&gt;
=== Enable SMTPS Traffic Processing ===&lt;br /&gt;
&lt;br /&gt;
This option is enabled by default, and allows the SSL Inspector to work cooperatively with the other applications that act on SMTP mail traffic.  When enabled, port 25 mail sessions that use STARTTLS will be decrypted inbound, allowing the clear traffic to pass through all other applications, and the re-encrypted again before passing outbound.&lt;br /&gt;
&lt;br /&gt;
=== Enable HTTPS Traffic Processing ===&lt;br /&gt;
&lt;br /&gt;
This option is enabled by default, and allows the SSL Inspector to work cooperatively with the other applications that act on HTTP web traffic.  When enabled, port 443 web sessions that use SSL/TLS will be decrypted inbound, allowing the clear traffic to pass through all other applications, and then re-encrypted again before passing outbound.&lt;br /&gt;
&lt;br /&gt;
=== Block Invalid HTTPS Traffic ===&lt;br /&gt;
&lt;br /&gt;
When processing a new HTTPS session, the first thing the inspector does is analyze the initial client&lt;br /&gt;
request to see if it contains a valid SSL negotiation message.  If not, by default the session will be ignored and the traffic will flow directly between the client and server with no inspection performed.&lt;br /&gt;
By enabling this checkbox, you can change the default behavior and effectively block any port 443&lt;br /&gt;
traffic that does not contain a valid HTTPS signature.&lt;br /&gt;
&lt;br /&gt;
=== Client/Server Connection Protocols ===&lt;br /&gt;
&lt;br /&gt;
This section includes checkboxes for turning on and off the SSL and TLS protocols that will be used when negotiating secure HTTPS and SMTPS inbound and outbound connections. The client protocols are used when the server is communicating with a client. The server protocols are used when the server is communicating with a server.&lt;br /&gt;
&lt;br /&gt;
* SSLv2Hello - This is really a legacy handshake protocol that is used between a client and server when deciding which encryption protocol to use. This means it&#039;s possible to enable SSLv2Hello and still have a TLSv1.x connection negotiated. While there are no known security issues, we still recommend leaving this disabled unless you specifically need this legacy support.&lt;br /&gt;
&lt;br /&gt;
* SSLv3 - This is an older protocol that is now deprecated since the discovery of the POODLE vulnerability. For that reason, we recommend this be disabled for maximum security.&lt;br /&gt;
&lt;br /&gt;
* TLSv1 - This is an older protocol that has some known weaknesses. These can be mitigated if the other side of the connection forces certain secure ciphers to be used. However, since this can&#039;t be guaranteed, best practice is to disable this protocol unless it is required to support connections with legacy clients or servers.&lt;br /&gt;
&lt;br /&gt;
* TLSv1.1 - This is a more modern protocol that is generally regarded as secure.&lt;br /&gt;
&lt;br /&gt;
* TLSv1.2 - This is the most recent version of the TLS protocol.&lt;br /&gt;
&lt;br /&gt;
=== Trust All Server Certificates ===&lt;br /&gt;
&lt;br /&gt;
Normally, when establishing an SSL connection with an external web server, the inspector will authenticate the server certificate against a standard list of trusted certificate authorities.  If this trust cannot be established, the inspector will end the session.  By enabling this checkbox, you can force the inspector to blindly trust all external server certificates.&lt;br /&gt;
&lt;br /&gt;
Please note that we &#039;&#039;&#039;DO NOT&#039;&#039;&#039; recommend running with this option enabled, as it exposes&lt;br /&gt;
all HTTPS traffic to significant security risks.&lt;br /&gt;
&lt;br /&gt;
The standard list of trusted certificates used by Untangle is generated from the standard ca-certificates package.  It includes, among others, certificate authorities used by Mozilla&#039;s browsers.  Please note that Untangle can neither confirm nor deny whether the certificate authorities whose certificates are included in this list have in any way been audited for trustworthiness or RFC 3647 compliance. Full responsibility to assess them belongs to the local system administrator.&lt;br /&gt;
&lt;br /&gt;
=== Upload Trusted Certificate ===&lt;br /&gt;
The inspector emulates a web browser when it makes outbound connections to external web servers.  Just&lt;br /&gt;
like a web browser, it must verify the authenticity of the server certificate before it will trust the&lt;br /&gt;
connection and allow traffic to flow freely.  As mentioned above, the inspector uses a standard list&lt;br /&gt;
of known certificate authorities to validate server certificates.  However, it&#039;s also possible you have&lt;br /&gt;
servers in your network that use certificates that can&#039;t be authenticated this way.  Perhaps you have&lt;br /&gt;
your own certificate authority, or use self-signed certificates.  Whatever the reason, you can use this section of the configuration page to upload additional certificates that you want the inspector to trust.&lt;br /&gt;
&lt;br /&gt;
== Rules ==&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Rules&#039;&#039;&#039; tab allows you to specify explicit rules to Inspect or Ignore HTTPS traffic that crosses the Untangle.  By default, many common HTTPS sites (google, youtube, yahoo, etc) are inspected, but not all HTTPS. This provides a safe default which provides HTTPS inspection on those sites without interfering with other HTTPS communications. It can easily be configured to inspect all HTTPS by enabling the &amp;quot;Inspect All Traffic&amp;quot; rule.&lt;br /&gt;
&lt;br /&gt;
The [[Rules|Rules documentation]] describes how rules work and how they are configured. SSL Inspector uses rules to determine if it should inspect or ignore traffic for the specific session.&lt;br /&gt;
&lt;br /&gt;
In addition to all the common rule types, there are three that are unique to the SSL Inspector, and these can be very useful for ignoring traffic that you don&#039;t want to inspect, or that isn&#039;t compatible with the SSL Inspector.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;HTTPS: SNI Hostname&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Most web browsers and many client applications include the destination hostname in the initial packet of an HTTPS session.  The mechanism used is called the Server Name Indication, or the SNI extension to the TLS protocol.  The main purpose is to allow a single web server to host multiple secure web sites.  By analyzing the SNI hostname in the client request, the server can decide which SSL certificate to use for encrypting the session.  This extension is necessary because the encryption must be established long before the server ever sees the HTTP request, and by then it would be too late to use a different certificate.&lt;br /&gt;
&lt;br /&gt;
Creating ignore rules based on the SNI hostname is an effective way to have the SSL Inspector ignore incompatible traffic.  A prime example is the default rule for Microsoft Update.  The Microsoft Update client checks the server certificate to ensure it was signed by a specific authority.  Since it doesn&#039;t trust the Root Aurthority the SSL Inspector uses to generate certificates on-the-fly, Microsoft Update will fail with an error.  The default rule allows this traffic to be detected and ignored, allowing Microsoft Update to work properly.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;HTTPS: Certificate Subject&#039;&#039;&#039; and &#039;&#039;&#039;HTTPS: Certificate Issuer&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
These two rule conditions are useful when dealing with client applications that don&#039;t use SNI, and aren&#039;t compatible with SSL Inspectory.  An excellent example is the Dropbox client utility for which there is also a default rule.  Like Microsoft Update, the Dropbox client will reject SSL certificates that it doesn&#039;t explicitly trust.&lt;br /&gt;
&lt;br /&gt;
Using either of these rule conditions, you can match traffic on any portion of the Subject or Issuer Distinguished Name (DN) included in the server certificate.  In both cases, the information in the match string includes the standard information fields commonly stored within the SSL certificates, such as CN (common name), C (country), ST (state), L (locality), O (organization), and OU (organizational unit).  Each of these are appended to the match string and separated by commas.  Note that not all fields are required in all certificates, and some certificates may have others not listed.  The order they occur in the match string is also not guaranteed.&lt;br /&gt;
&lt;br /&gt;
The Subject DN generally includes information about the company to which the certificate was issued.  Here is an example Certificate Subject:&lt;br /&gt;
&lt;br /&gt;
 CN=*.dropbox.com, O=&amp;quot;Dropbox, Inc.&amp;quot;, L=San Francisco, ST=California, C=US&lt;br /&gt;
&lt;br /&gt;
The Issuer DN generally includes information about the company that issued and authenticated the certificate.  Here is an example Certificate Issuer:&lt;br /&gt;
&lt;br /&gt;
 CN=Thawte SSL CA, O=&amp;quot;Thawte, Inc.&amp;quot;, C=US&lt;br /&gt;
&lt;br /&gt;
=== Rule Actions ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Inspect&#039;&#039;&#039;: Causes the traffic which matched the rule to be decrypted and passed along to other applications and service for further inspection, classification, and possible action.&lt;br /&gt;
* &#039;&#039;&#039;Ignore&#039;&#039;&#039;: Causes the traffic which matched the rule to be ignored the SSL Inspector.&lt;br /&gt;
&lt;br /&gt;
== Reports ==&lt;br /&gt;
&lt;br /&gt;
{{:SSL Inspector Reports}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=[[SSL Inspector FAQs]]=&lt;br /&gt;
&lt;br /&gt;
{{:SSL Inspector FAQs}}&lt;/div&gt;</summary>
		<author><name>Mahotz</name></author>
	</entry>
</feed>