Why TLS analysis matters

TLS (Transport Layer Security) is the backbone of internet security, protecting data in transit across billions of connections daily. As quantum computing advances, the cryptographic algorithms underlying TLS face an existential threat.

The Quantum Clock is Ticking CNSA 2.0 mandates that National Security Systems transition to quantum-resistant algorithms by 2030-2035. The timeline for commercial systems follows closely. Organizations need visibility into their TLS posture today.

TLS Analyzer helps you understand:

What is TLS Analyzer

TLS Analyzer is an open-source security assessment tool that scans TLS/SSL endpoints and evaluates them against modern security standards and the CNSA 2.0 quantum-readiness timeline.

CNSA 2.0 timeline assessment

Tracks compliance against NSA's Commercial National Security Algorithm Suite 2.0 milestones from 2025-2035.

Quantum risk scoring

Evaluates vulnerability to harvest-now-decrypt-later attacks with clear risk levels and remediation guidance.

Multiple output formats

Generate reports in text, JSON, SARIF (GitHub Security), HTML, and CycloneDX CBOM for compliance.

Policy-based scanning

Define custom policies in YAML or use the built-in presets (modern, strict, and the CNSA 2.0 targets for 2027, 2030 and 2035) for consistent enforcement.

Getting started

Installation

Clone and build TLS Analyzer from source:

git clone https://github.com/csnp/tls-analyzer.git
cd tls-analyzer
go build -o tlsanalyzer ./cmd/tlsanalyzer

Basic usage

Scan a single target:

# Scan a host (default port 443)
tlsanalyzer example.com

# Scan a specific port
tlsanalyzer example.com:8443

# Scan multiple targets: one host per line in a file
printf 'example.com\napi.example.com\nmail.example.com\n' > hosts.txt
tlsanalyzer --targets hosts.txt

Common options

# Output as JSON
tlsanalyzer example.com --format json

# Generate HTML report
tlsanalyzer example.com --format html --output report.html

# Generate SARIF for GitHub Security
tlsanalyzer example.com --format sarif --output results.sarif

# Generate Cryptographic Bill of Materials
tlsanalyzer example.com --format cbom --output tls-cbom.json

# Apply a security policy
tlsanalyzer example.com --policy strict

# Batch scan from file
tlsanalyzer --targets hosts.txt

CNSA 2.0 timeline

The Commercial National Security Algorithm Suite (CNSA) 2.0 establishes a timeline for transitioning to quantum-resistant cryptography. TLS Analyzer tracks your compliance against these milestones:

1

2025: preparation phase

Begin inventory of cryptographic assets. Start planning migration to quantum-resistant algorithms. TLS 1.2+ should be baseline.

2

2027: software/firmware signing

Transition to quantum-resistant algorithms for software and firmware signing (ML-DSA, SLH-DSA).

3

2030: web/cloud services

Quantum-resistant TLS for web browsers, cloud services, and key establishment (ML-KEM hybrid modes).

4

2033: traditional networking

VPNs, routers, and legacy systems must support quantum-resistant algorithms.

5

2035: full transition

Complete migration to CNSA 2.0 algorithms. Classical algorithms deprecated for National Security Systems.

Algorithm Requirements CNSA 2.0 specifies: ML-KEM-768/1024 for key establishment, ML-DSA-65/87 or SLH-DSA for digital signatures, AES-256 for symmetric encryption, and SHA-384/512 for hashing.

Security grading system

TLS Analyzer assigns letter grades based on protocol support, cipher strength, certificate quality, and quantum readiness:

Grade Score Meaning
A+ 95-100 Excellent security posture with quantum-ready or hybrid key exchange
A 90-94 Strong configuration with TLS 1.3 and modern cipher suites
B 80-89 Good security but may have minor issues or outdated protocols
C 65-79 Acceptable but significant improvements recommended
D 50-64 Weak configuration with known vulnerabilities
F 0-49 Critical vulnerabilities or severely outdated configuration

Scoring factors

Output formats

HTML reports

Generate professional HTML reports for stakeholder communication:

tlsanalyzer example.com --format html --output tls-report.html

HTML reports include visual grade indicators, detailed findings, and remediation recommendations.

SARIF (GitHub security integration)

SARIF integrates directly with GitHub's Security tab for automated scanning:

tlsanalyzer example.com --format sarif --output results.sarif

CBOM (cryptographic bill of materials)

Generate CycloneDX-compatible CBOMs for compliance and supply chain transparency:

tlsanalyzer example.com --format cbom --output tls-cbom.json

CBOMs document all cryptographic components discovered during the scan, including algorithms, key sizes, and protocol versions.

Policy-based scanning

Built-in policies

# List available policies
tlsanalyzer policies

# Apply the strict policy
tlsanalyzer example.com --policy strict

# Apply the modern policy
tlsanalyzer example.com --policy modern

Custom policies

Define custom policies in YAML for organization-specific requirements. From 0.4.0 an unknown key is refused rather than silently ignored, so start from a file the tool prints for you and edit that: tlsanalyzer print-policy modern > my-policy.yaml. To inherit a built-in policy and override individual rules, add extends: modern rather than restating the whole file.

# my-policy.yaml
name: corporate-standard
version: "1.0"
description: Corporate TLS requirements
rules:
  protocol:
    minVersion: TLS 1.2
    bannedVersions:
      - TLS 1.0
      - TLS 1.1
  cipher:
    minKeySize: 128
    requireForwardSecrecy: true
    bannedAlgorithms:
      - 3DES
      - RC4
      - MD5
      - SHA1
  certificate:
    minValidityDays: 30
    minRsaKeySize: 2048
    bannedSignatureAlgorithms:
      - SHA1
      - MD5
    allowSelfSigned: false

Apply your custom policy:

tlsanalyzer example.com --policy-file my-policy.yaml

CI/CD integration

GitHub Actions

name: TLS Security Scan
on:
  schedule:
    - cron: '0 6 * * 1'  # Weekly on Monday
  workflow_dispatch:

jobs:
  tls-scan:
    runs-on: ubuntu-latest
    steps:
      - name: Setup Go
        uses: actions/setup-go@v5
        with:
          go-version: '1.21'

      - name: Install TLS Analyzer
        run: |
          git clone --depth 1 https://github.com/csnp/tls-analyzer.git
          cd tls-analyzer && go build -o /usr/local/bin/tlsanalyzer ./cmd/tlsanalyzer

      - name: Scan Production Endpoints
        run: |
          printf 'api.example.com\napp.example.com\n' > hosts.txt
          tlsanalyzer \
            --targets hosts.txt \
            --format sarif \
            --output tls-results.sarif \
            --policy modern
      # Exit 2 means the policy was evaluated and not satisfied, which is what
      # fails this job. Exit 1 means a host could not be scanned, so there is no
      # verdict. Exit 0 means every target satisfied the policy.

      - name: Upload SARIF Results
        uses: github/codeql-action/upload-sarif@v3
        with:
          sarif_file: tls-results.sarif

GitLab CI

tls-security-scan:
  image: golang:1.21
  stage: security
  script:
    - git clone --depth 1 https://github.com/csnp/tls-analyzer.git
    - cd tls-analyzer && go build -o /usr/local/bin/tlsanalyzer ./cmd/tlsanalyzer
    - echo "$PRODUCTION_HOSTS" | tr ' ' '\n' > hosts.txt
    - tlsanalyzer --targets hosts.txt --format json --output tls-report.json
  artifacts:
    reports:
      security: tls-report.json
  only:
    - schedules

Ready to assess your TLS security?

Get started with TLS Analyzer today - scan your endpoints for quantum readiness and CNSA 2.0 compliance.

View on GitHub Take QRAMM Assessment

Related resources