Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Easyrsa version range #452

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

jan-win1993
Copy link

Pull Request (PR) description

This pull request addresses 3 problems:

  1. Since easy-rsa version 3.0.3 the name of the easy-rsa configuration file did change from "openssl-1.0.cnf" to "openssl-easyrsa.cnf"
    The following is a link to the corresponding commit:
    OpenVPN/easy-rsa@e8cd6c9.
    To tackle that problem I would like to introduce easy-rsa version ranges and change the file name if a version above 3.0.3 is used.
  2. I did also run into a problem with the "./easy-rsa build-server-full" command which opened an input prompt, which could be suppressed using the "--batch" option
  3. The whole openssl output with text gets copied to the client configuration file. I've added a exec resource which runs the "openssl" command with the "-noout" option to suppress the unnecessary text output.

@fraenki
Copy link
Member

fraenki commented Jun 25, 2024

@bastelfreak Could we get a review please? Thanks :)

Comment on lines +146 to +151
if versioncmp($openvpn::easyrsa_version, '4') == -1 {
if versioncmp($openvpn::easyrsa_version, '3.0.3') == 1 {
$default_easyrsa_openssl_conf = 'openssl-easyrsa.cnf'
} else {
$default_easyrsa_openssl_conf = 'openssl-1.0.cnf'
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if versioncmp($openvpn::easyrsa_version, '4') == -1 {
if versioncmp($openvpn::easyrsa_version, '3.0.3') == 1 {
$default_easyrsa_openssl_conf = 'openssl-easyrsa.cnf'
} else {
$default_easyrsa_openssl_conf = 'openssl-1.0.cnf'
}
if versioncmp($openvpn::easyrsa_version, '4') == -1 {
$default_easyrsa_openssl_conf = if versioncmp($openvpn::easyrsa_version, '3.0.3') == 1 {
'openssl-easyrsa.cnf'
} else {
'openssl-1.0.cnf'
}

@bastelfreak
Copy link
Member

@fraenki I cannot merge this with the failing jobs. Can you pick up #441? We need to get the latest modulesync in, afterwards we can drop the EoL operating systems, that should get the pipeline green again. I currently don't have the time to work on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants