The --juniper switch has been deprecated in favour of --protocol=nc. Fix the
proto script thusly, while keeping compatibility with existing configurations.
Note that, as far as UCI is concerned, if both options juniper and vpn_protocol
are specified, the latter takes precedence.
Signed-off-by: Rui Salvaterra <rsalvaterra@gmail.com>
append_args --no-system-trust
}
- if [ "${juniper:-0}" -gt 0 ]; then
- append_args --juniper
- fi
+ [ "${juniper:-0}" -gt 0 ] && [ -z "$vpn_protocol" ] && {
+ vpn_protocol="nc"
+ }
[ -n "$vpn_protocol" ] && {
append_args --protocol "$vpn_protocol"