summaryrefslogtreecommitdiffstats
path: root/usr/local/www/interfaces.php
diff options
context:
space:
mode:
Diffstat (limited to 'usr/local/www/interfaces.php')
-rwxr-xr-xusr/local/www/interfaces.php114
1 files changed, 64 insertions, 50 deletions
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php
index a2a07ed..578bcde 100755
--- a/usr/local/www/interfaces.php
+++ b/usr/local/www/interfaces.php
@@ -215,6 +215,7 @@ if (isset($wancfg['wireless'])) {
/* Get wireless modes */
$wlanif = get_real_interface($if);
interface_wireless_clone($wlanif, $wancfg);
+ $wlanbaseif = interface_get_wireless_base($wancfg['if']);
$wl_modes = get_wireless_modes($if);
$pconfig['standard'] = $wancfg['wireless']['standard'];
$pconfig['mode'] = $wancfg['wireless']['mode'];
@@ -295,6 +296,9 @@ if ($_POST['apply']) {
if ($_POST && $_POST['enable'] == "no") {
unset($wancfg['enable']);
interface_bring_down($if);
+ if (isset($wancfg['wireless'])) {
+ interface_sync_wireless_clones($wancfg, false);
+ }
write_config("Interface {$_POST['descr']}({$if}) is now disabled.");
mark_subsystem_dirty('interfaces');
header("Location: interfaces.php?if={$if}");
@@ -773,6 +777,7 @@ function handle_wireless_post() {
$wancfg['wireless']['wep']['key'][] = $newkey;
}
}
+ interface_sync_wireless_clones($wancfg, true);
}
$pgtitle = array("Interfaces", $pconfig['descr']);
@@ -1232,7 +1237,10 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "pppoe"
<td colspan="2" valign="top" height="16"></td>
</tr>
<tr>
- <td colspan="2" valign="top" class="listtopic">Wireless configuration</td>
+ <td colspan="2" valign="top" class="listtopic">Common wireless configuration</td>
+ </tr>
+ <tr>
+ <td colspan="2" valign="top" class="vtable">These settings apply to all wireless networks on <?=$wlanbaseif;?>.</td>
</tr>
<tr>
<td valign="top" class="vncellreq">Standard</td>
@@ -1250,16 +1258,6 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "pppoe"
</td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Mode</td>
- <td class="vtable">
- <select name="mode" class="formselect" id="mode">
- <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss">Infrastructure (BSS)</option>
- <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc">Ad-hoc (IBSS)</option>
- <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap">Access Point</option>
- </select>
- </td>
- </tr>
- <tr>
<td valign="top" class="vncellreq">802.11g OFDM Protection Mode</td>
<td class="vtable">
<select name="protmode" class="formselect" id="protmode">
@@ -1272,45 +1270,6 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "pppoe"
<br/>
</td>
</tr>
- <tr>
- <td valign="top" class="vncellreq">SSID</td>
- <td class="vtable">
- <input name="ssid" type="text" class="formfld unknown" id="ssid" size="20" value="<?=htmlspecialchars($pconfig['ssid']); ?>">
- </td>
- </tr>
- <tr>
- <td valign="top" class="vncell">802.11g only</td>
- <td class="vtable">
- <input name="pureg_enable" type="checkbox" value="yes" class="formfld" id="pureg_enable" <? if ($pconfig['pureg_enable']) echo "checked";?>>
- <br/>When operating as an access point in 802.11g mode allow only 11g-capable stations to associate (11b-only stations are not permitted to associate).
- </td>
- </tr>
- <tr>
- <td valign="top" class="vncell">Allow intra-BSS communication</td>
- <td class="vtable">
- <input name="apbridge_enable" type="checkbox" value="yes" class="formfld" id="apbridge_enable" <? if ($pconfig['apbridge_enable']) echo "checked";?>>
- <br/>
- When operating as an access point, enable this if you want to pass packets between wireless clients directly.
- <br/>
- Disabling the internal bridging is useful when traffic is to be processed with packet filtering.
- </td>
- </tr>
- <tr>
- <td valign="top" class="vncell">Enable WME</td>
- <td class="vtable">
- <input name="wme_enable" type="checkbox" class="formfld" id="wme_enable" value="yes" <? if ($pconfig['wme_enable']) echo "checked";?>>
- <br/>Setting this option will force the card to use WME (wireless QoS).
- </td>
- </tr>
- <tr>
- <td valign="top" class="vncell">Enable Hide SSID</td>
- <td class="vtable">
- <input name="hidessid_enable" type="checkbox" class="formfld" id="hidessid_enable" value="yes" <? if ($pconfig['hidessid_enable']) echo "checked";?>>
- <br/>
- Setting this option will force the card to NOT broadcast its SSID
- <br/>
- (this might create problems for some clients). </td>
- </tr>
<tr>
<td valign="top" class="vncellreq">Transmit power</td>
<td class="vtable">
@@ -1351,6 +1310,61 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "pppoe"
</td>
</tr>
<tr>
+ <td colspan="2" valign="top" height="16"></td>
+ </tr>
+ <tr>
+ <td colspan="2" valign="top" class="listtopic">Wireless configuration</td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncellreq">Mode</td>
+ <td class="vtable">
+ <select name="mode" class="formselect" id="mode">
+ <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss">Infrastructure (BSS)</option>
+ <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc">Ad-hoc (IBSS)</option>
+ <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap">Access Point</option>
+ </select>
+ </td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncellreq">SSID</td>
+ <td class="vtable">
+ <input name="ssid" type="text" class="formfld unknown" id="ssid" size="20" value="<?=htmlspecialchars($pconfig['ssid']); ?>">
+ </td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncell">802.11g only</td>
+ <td class="vtable">
+ <input name="pureg_enable" type="checkbox" value="yes" class="formfld" id="pureg_enable" <? if ($pconfig['pureg_enable']) echo "checked";?>>
+ <br/>When operating as an access point in 802.11g mode allow only 11g-capable stations to associate (11b-only stations are not permitted to associate).
+ </td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncell">Allow intra-BSS communication</td>
+ <td class="vtable">
+ <input name="apbridge_enable" type="checkbox" value="yes" class="formfld" id="apbridge_enable" <? if ($pconfig['apbridge_enable']) echo "checked";?>>
+ <br/>
+ When operating as an access point, enable this if you want to pass packets between wireless clients directly.
+ <br/>
+ Disabling the internal bridging is useful when traffic is to be processed with packet filtering.
+ </td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncell">Enable WME</td>
+ <td class="vtable">
+ <input name="wme_enable" type="checkbox" class="formfld" id="wme_enable" value="yes" <? if ($pconfig['wme_enable']) echo "checked";?>>
+ <br/>Setting this option will force the card to use WME (wireless QoS).
+ </td>
+ </tr>
+ <tr>
+ <td valign="top" class="vncell">Enable Hide SSID</td>
+ <td class="vtable">
+ <input name="hidessid_enable" type="checkbox" class="formfld" id="hidessid_enable" value="yes" <? if ($pconfig['hidessid_enable']) echo "checked";?>>
+ <br/>
+ Setting this option will force the card to NOT broadcast its SSID
+ <br/>
+ (this might create problems for some clients). </td>
+ </tr>
+ <tr>
<td valign="top" class="vncell">Distance setting</td>
<td class="vtable">
<input name="distance" type="text" class="formfld unknown" id="distance" size="5" value="<?=htmlspecialchars($pconfig['distance']);?>">
OpenPOWER on IntegriCloud