When token_script fails, proto_setup_failed() notifies netifd that
setup has failed, but script execution continues regardless.
This commit adds exit 1 and sleep 5 (consistent with wireguard.sh
error handling) to abort setup on token_script failure. Also fix
typo in logger tag ("openconenct" -> "openconnect").
Signed-off-by: Thomas Winkler <redacted>
}
[ "$token_mode" = "script" ] && {
$token_script >> "$pwfile" 2> /dev/null || {
- logger -t openconenct "Cannot get password from script '$token_script'"
+ logger -t openconnect "Cannot get password from script '$token_script'"
+ sleep 5
proto_setup_failed "$config"
+ exit 1
}
}
append_args --passwd-on-stdin