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

Explicit servername in ca-certificates test #18120

Merged
merged 1 commit into from
Nov 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions tests/console/ca_certificates_mozilla.pm
@@ -1,13 +1,13 @@
# SUSE's openQA tests
#
# Copyright 2018-2020 SUSE LLC
# Copyright 2018-2023 SUSE LLC
# SPDX-License-Identifier: FSFAP

# Package: ca-certificates-mozilla openssl
# Summary: Install ca-certificates-mozilla and test connection to a secure website
# - install ca-certificates-mozilla and openssl
# - connect to static.opensuse.org:443 using openssl and verify that the return code is 0
# Maintainer: Orestis Nalmpantis <onalmpantis@suse.de>
# Maintainer: QE Core <qe-core@suse.de>

use base "consoletest";
use strict;
Expand All @@ -19,7 +19,8 @@ use utils 'zypper_call';
sub run {
select_serial_terminal;
zypper_call 'in ca-certificates-mozilla openssl';
assert_script_run('echo "x" | openssl s_client -connect static.opensuse.org:443 | grep "Verify return code: 0"');
my $server = "static.opensuse.org"; # due to infra setup, need to pass explicit servername for older openssl
assert_script_run(qq[echo "x" | openssl s_client -connect $server:443 -servername $server | grep "Verify return code: 0"]);
}

1;