Skip to content

[BUG] Incorrect id for cert_trust_wildcard #3051

Description

@TheraNinjaCat

General remark

The JSON and CSV output lines for the cert_trust_wildcard field are incorrect when multiple hostCerts are present. They output as cert_trust <hostCert#1>_wildcard rather than cert_trust_wildcard <hostCert#1>

Before you open an issue please check which version you are running and whether it is the latest in stable / dev branch

  • I am running version (git log | head -1 ) from the git repo
  • I am running testssl.sh version 3.2.3 from https://testssl.sh/

Before you open an issue please consult the FAQ and check whether this is a known problem by searching the issues

  • Is related to ...
  • couldn't find anything

Command line to reproduce (or docker command)

testssl.sh -oA output google.com
grep '_wildcard' output.json

                                "id"           : "cert_trust <hostCert#1>_wildcard",
                                "id"           : "cert_trust <hostCert#2>_wildcard",

grep '_wildcard' testssl_1780882190.csv

"cert_trust <hostCert#1>_wildcard","google.com/142.251.222.14","443","LOW","trust is via wildcard","",""
"cert_trust <hostCert#2>_wildcard","google.com/142.251.222.14","443","LOW","trust is via wildcard","",""

Expected behavior

testssl.sh -oA output google.com
grep '_wildcard' output.json

                                "id"           : "cert_trust_wildcard <hostCert#1>",
                                "id"           : "cert_trust_wildcard <hostCert#2>",

grep '_wildcard' testssl_1780882190.csv

"cert_trust_wildcard <hostCert#1>","google.com/142.251.222.14","443","LOW","trust is via wildcard","",""
"cert_trust_wildcard <hostCert#2>","google.com/142.251.222.14","443","LOW","trust is via wildcard","",""

Your system (please complete the following information):

  • OS: Docker for Windows
  • Platform: Linux 6.6.114.1-microsoft-standard-WSL2 x86_64
  • OpenSSL + bash:
Using OpenSSL 1.0.2-bad (Mar 28 2025)  [~183 ciphers]
Using bash 4.4.23

Additional context

The issue appears to be caused by line https://github.com/testssl/testssl.sh/blob/7f63e73ec3d3fbecd05958460733695e2a64fe2a/testssl.sh#L9998

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions