mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-12-26 23:26:47 +01:00
Fix bridged mode setting incorrect bridge parameter
When bridged mode is enabled, the bridge parameter in hostapd.conf was set to "1" instead of "br0", causing authentication failures. This fix introduces a separate bridgeName parameter for the hostapd configuration while maintaining the boolean bridge parameter for dnsmasq and dhcpcd services. Fixes #2021
This commit is contained in:
@@ -209,9 +209,9 @@ class HostapdManager
|
|||||||
}
|
}
|
||||||
|
|
||||||
// bridge handling
|
// bridge handling
|
||||||
if (!empty($params['bridge'])) {
|
if (!empty($params['bridgeName'])) {
|
||||||
$config[] = 'interface=' . $params['interface'];
|
$config[] = 'interface=' . $params['interface'];
|
||||||
$config[] = 'bridge=' . $params['bridge'];
|
$config[] = 'bridge=' . $params['bridgeName'];
|
||||||
} else {
|
} else {
|
||||||
$config[] = 'interface=' . $params['interface'];
|
$config[] = 'interface=' . $params['interface'];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -145,6 +145,7 @@ class HotspotService
|
|||||||
try {
|
try {
|
||||||
// normalize state flags
|
// normalize state flags
|
||||||
$validated['interface'] = $apIface;
|
$validated['interface'] = $apIface;
|
||||||
|
$validated["bridgeName"] = !empty($states["BridgedEnable"]) ? "br0" : null;
|
||||||
$validated['bridge'] = !empty($states['BridgedEnable']);
|
$validated['bridge'] = !empty($states['BridgedEnable']);
|
||||||
$validated['apsta'] = !empty($states['WifiAPEnable']);
|
$validated['apsta'] = !empty($states['WifiAPEnable']);
|
||||||
$validated['repeater'] = !empty($states['RepeaterEnable']);
|
$validated['repeater'] = !empty($states['RepeaterEnable']);
|
||||||
|
|||||||
Reference in New Issue
Block a user