Skip to content

Commit

Permalink
Merge pull request #20558 from ilmanzo/poo169087_jeos_openssl_fips_al…
Browse files Browse the repository at this point in the history
…glist

Handle absence of legacy module in JeOS
  • Loading branch information
ilmanzo authored Nov 5, 2024
2 parents 839d497 + 05cc2af commit bd05cfa
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lib/security/openssl_misc_utils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use warnings;
use testapi;
use registration 'add_suseconnect_product';
use utils 'zypper_call';
use version_utils qw(is_sle is_sle_micro is_microos is_transactional is_tumbleweed is_rt);
use version_utils qw(is_sle is_sle_micro is_microos is_transactional is_tumbleweed is_rt is_jeos);

use base 'Exporter';

Expand All @@ -24,7 +24,7 @@ use constant OPENSSL1_BINARY => "openssl-1_1";
sub get_openssl_full_version {
my $openssl_binary = shift // "openssl";
# for SLERT we don't install a package, we query the rpm file just downloaded in install_openssl
return script_output("rpm -qp --qf '%{version}\n' openssl*.rpm") if (is_rt && $openssl_binary eq OPENSSL1_BINARY);
return script_output("rpm -qp --qf '%{version}\n' openssl*.rpm") if (has_no_legacy_module() && $openssl_binary eq OPENSSL1_BINARY);
return script_output("rpm -q --qf '%{version}\n' $openssl_binary");
}

Expand All @@ -35,6 +35,10 @@ sub get_openssl_x_y_version {
return $openssl_version;
}

sub has_no_legacy_module {
return is_rt || is_jeos;
}

sub has_default_openssl1 {
return (is_sle('>=15') && is_sle('<=15-SP5'));
}
Expand All @@ -46,7 +50,7 @@ sub has_default_openssl3 {
sub install_openssl {
zypper_call 'in openssl' unless is_transactional;
if (is_sle '>=15-SP6') {
if (is_rt)
if (has_no_legacy_module())
{
install_11_workaround_when_no_legacy();
return;
Expand Down

0 comments on commit bd05cfa

Please sign in to comment.