hostapd/RADIUS_server: add config option for IPv6

Even though IPv6 support for hostapd RADIUS server is implemented
(flag `-6`), it's not possible to enable it from configuration.

This commit adds this option and adapts init script.

Signed-off-by: Dávid Benko <davidbenko@davidbenko.dev>
Link: https://github.com/openwrt/openwrt/pull/18089
Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
Dávid Benko 2025-02-24 10:43:10 +01:00 committed by Robert Marko
parent 843e50f4fa
commit dbdd84725d
2 changed files with 3 additions and 0 deletions

View File

@ -1,5 +1,6 @@
config radius
option disabled '1'
option ipv6 '1'
option ca_cert '/etc/radius/ca.pem'
option cert '/etc/radius/cert.pem'
option key '/etc/radius/key.pem'

View File

@ -12,6 +12,7 @@ radius_start() {
[ "$disabled" -gt 0 ] && return
config_get_bool ipv6 "$cfg" ipv6 1
config_get ca "$cfg" ca_cert
config_get key "$cfg" key
config_get cert "$cfg" cert
@ -28,6 +29,7 @@ radius_start() {
-s "$clients" -u "$users" \
-p "$auth_port" -P "$acct_port" \
-i "$identity"
[ "$ipv6" -gt 0 ] && procd_append_param command -6
procd_close_instance
}