Update IKEv2 script

- Update client config file generation code due to a recent change
  on Ubuntu 20.04: The libnss3 package was recently updated to
  version 3.98 on Ubuntu 20.04, which requires these changes to the
  IKEv2 script.
  Ref: https://packages.ubuntu.com/focal/libnss3
This commit is contained in:
hwdsl2 2024-04-10 22:06:28 -05:00
parent 4c6f37e5a5
commit 25670f39e7

View File

@ -157,7 +157,7 @@ confirm_or_abort() {
show_header() {
cat <<'EOF'
IKEv2 Script Copyright (c) 2020-2024 Lin Song 3 Feb 2024
IKEv2 Script Copyright (c) 2020-2024 Lin Song 10 Apr 2024
EOF
}
@ -820,7 +820,7 @@ export_p12_file() {
-legacy -name "$client_name" -passin "pass:$p12_password" -passout pass: || exit 1
fi
/bin/rm -f "$pem_file"
elif [ "$os_type" = "alpine" ] || [ "$os_ver" = "kalirolling" ] || [ "$os_type$os_ver" = "ubuntu11" ]; then
elif [ "$os_type" = "alpine" ] || [ "$os_ver" = "kalirolling" ] || [ "$os_ver" = "bullseyesid" ]; then
pem_file="$export_dir$client_name.temp.pem"
openssl pkcs12 -in "$p12_file_enc" -out "$pem_file" -passin "pass:$p12_password" -passout "pass:$p12_password" || exit 1
openssl pkcs12 -keypbe PBE-SHA1-3DES -certpbe PBE-SHA1-3DES -export -in "$pem_file" -out "$p12_file_enc" \