Fix suse-packaging.patch for non-root usage.
OBS-URL: https://build.opensuse.org/package/show/network:vpn/easy-rsa?expand=0&rev=25
This commit is contained in:
parent
be3c4c1cc5
commit
d9dcf74b8a
@ -13,7 +13,7 @@
|
|||||||
# license that conforms to the Open Source Definition (Version 1.9)
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
# published by the Open Source Initiative.
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,8 +1,24 @@
|
|||||||
Index: easyrsa
|
--- easyrsa.orig 2018-09-15 06:21:19.000000000 +0200
|
||||||
===================================================================
|
+++ easyrsa 2018-12-03 23:38:04.420888219 +0100
|
||||||
--- easyrsa.orig
|
@@ -315,7 +315,7 @@
|
||||||
+++ easyrsa
|
EASYRSA_PKI env-var undefined"
|
||||||
@@ -1124,7 +1124,7 @@ vars_setup() {
|
|
||||||
|
# make safessl-easyrsa.cnf
|
||||||
|
- make_ssl_config
|
||||||
|
+ [ "$1" == "no_safe_ssl_config" ] || make_ssl_config
|
||||||
|
|
||||||
|
# Verify EASYRSA_OPENSSL command gives expected output
|
||||||
|
if [ -z "$EASYRSA_SSL_OK" ]; then
|
||||||
|
@@ -415,7 +415,7 @@
|
||||||
|
|
||||||
|
# init-pki backend:
|
||||||
|
init_pki() {
|
||||||
|
- vars_source_check
|
||||||
|
+ vars_source_check no_safe_ssl_config
|
||||||
|
|
||||||
|
# If EASYRSA_PKI exists, confirm before we rm -rf (skiped with EASYRSA_BATCH)
|
||||||
|
if [ -e "$EASYRSA_PKI" ]; then
|
||||||
|
@@ -1124,7 +1124,7 @@
|
||||||
vars=
|
vars=
|
||||||
|
|
||||||
# set up program path
|
# set up program path
|
||||||
@ -11,7 +27,7 @@ Index: easyrsa
|
|||||||
# set up PKI path
|
# set up PKI path
|
||||||
pki_vars="${EASYRSA_PKI:-$PWD/pki}/vars"
|
pki_vars="${EASYRSA_PKI:-$PWD/pki}/vars"
|
||||||
|
|
||||||
@@ -1154,7 +1154,7 @@ Note: using Easy-RSA configuration from:
|
@@ -1154,7 +1154,7 @@
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Set defaults, preferring existing env-vars if present
|
# Set defaults, preferring existing env-vars if present
|
||||||
@ -20,11 +36,22 @@ Index: easyrsa
|
|||||||
set_var EASYRSA_OPENSSL openssl
|
set_var EASYRSA_OPENSSL openssl
|
||||||
set_var EASYRSA_PKI "$PWD/pki"
|
set_var EASYRSA_PKI "$PWD/pki"
|
||||||
set_var EASYRSA_DN cn_only
|
set_var EASYRSA_DN cn_only
|
||||||
Index: vars.example
|
@@ -1185,7 +1185,11 @@
|
||||||
===================================================================
|
set_var EASYRSA_SSL_CONF "$EASYRSA_PKI/openssl-easyrsa.cnf"
|
||||||
--- vars.example.orig
|
set_var EASYRSA_SAFE_CONF "$EASYRSA_PKI/safessl-easyrsa.cnf"
|
||||||
+++ vars.example
|
else set_var EASYRSA_SSL_CONF "$EASYRSA/openssl-easyrsa.cnf"
|
||||||
@@ -47,7 +47,7 @@ fi
|
- set_var EASYRSA_SAFE_CONF "$EASYRSA/safessl-easyrsa.cnf"
|
||||||
|
+ if touch "$EASYRSA/safessl-easyrsa.cnf" &>/dev/null; then
|
||||||
|
+ set_var EASYRSA_SAFE_CONF "$EASYRSA/safessl-easyrsa.cnf"
|
||||||
|
+ else
|
||||||
|
+ set_var EASYRSA_SAFE_CONF "$EASYRSA_PKI/safessl-easyrsa.cnf"
|
||||||
|
+ fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Same as above for the x509-types extensions dir
|
||||||
|
--- vars.example.orig 2018-12-03 23:06:35.863084842 +0100
|
||||||
|
+++ vars.example 2018-12-03 23:07:12.538808022 +0100
|
||||||
|
@@ -47,7 +47,7 @@
|
||||||
# itself, which is also where the configuration files are located in the
|
# itself, which is also where the configuration files are located in the
|
||||||
# easy-rsa tree.
|
# easy-rsa tree.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user