INNER CODE UNIT · Python

testssl_cmd

rfc-st/humble · humble.py:505

    testssl_cmd = [testssl_path, *TESTSSL_OPTIONS, uri]
    testssl_analysis(testssl_cmd)
    sys.exit(0)


def testssl_analysis(testssl_cmd):
    """Run TLS/SSL analysis with testssl.sh, related to `-e` option.

    ??? note
        This function is safe from injection: `shell=True` is not used,
        arguments are passed as a list and `testssl.sh` options are defined in
        the `TESTSSL_OPTIONS` constant.
    """
    try:
        # nosemgrep: dangerous-subprocess-use-audit
        with Popen(testssl_cmd, stdout=PIPE, stderr=STDOUT,
                   text=True) as process:  # false-positive
            for ln in iter(process.stdout.readline, ""):

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…