跳到主要内容
uencoder

如何Use Certificate Transparency

Monitor 和验证 X.509 certificates 通过 Certificate Transparency (CT) logs 到检测 misissued certificates 和 improve trust.

问题

CA 能够 misissue certificate 为你的域 无你的知识, enabling man-in-the-middle attacks. 你需要use Certificate Transparency (RFC 6962) 到检测未授权 certificates 和监控为 misissuance.

前置条件

  • Understanding 的 X.509 certificates 和 CA hierarchy
  • 熟悉Merkle trees 和 inclusion proofs
  • Knowledge 的 TLS certificate validation

步骤

  1. 1. Understand the CT log architecture

    Certificate Transparency logs are append-only Merkle trees of certificates. When a CA issues a certificate, it must submit it to one or more CT logs. The log returns a Signed Certificate Timestamp (SCT) — a promise that the certificate will be included in the log. Browsers require SCTs in TLS handshakes; without them, certificates are rejected. The append-only nature means once logged, a certificate cannot be hidden or removed.

    输入
    certificate issued by CA
    输出
    SCT: { log_id, timestamp, extensions, signature }
  2. 2. Verify SCTs embedded in certificates

    When receiving a TLS certificate, check for embedded SCTs (in the certificate's X.509 extensions, OID 1.3.6.1.4.1.11129.2.4.2). For each SCT: verify the log's signature on the SCT, check the timestamp is within the certificate's validity period, and verify the log is trusted (in the CT log list). Use the hash tool to compute Merkle tree hashes for inclusion proofs. At least 2 SCTs from different logs are typically required.

    输入
    certificate with 3 embedded SCTs
    输出
    verified: 3/3 SCTs valid | logs: Google Argon, Cloudflare Nimbus, Let's Encrypt Oak
  3. 3. Monitor CT logs for your domains

    Set up monitoring of CT logs for certificates issued for your domains. Use APIs like Google's CT search (https://transparencyreport.google.com) or crt.sh to query for certificates matching your domain. Alert on any certificate you did not request. Check periodically: query for your domain, compare against your known certificate inventory, investigate any unknown certificates immediately. Use the DNS tools to verify the domain ownership.

    输入
    domain: example.com
    输出
    found: 2 certificates | expected: 2 | status: OK
  4. 4. Respond to misissued certificates

    If you detect an unauthorized certificate: (1) immediately report to the issuing CA for revocation, (2) revoke the certificate via OCSP or CRL, (3) investigate how the misissuance occurred (domain validation bypass, CA compromise), (4) consider using CAA (Certification Authority Authorization) DNS records to restrict which CAs can issue for your domain, (5) use DANE/TLSA records as an additional verification layer. Document the incident and update monitoring.

    输入
    unauthorized cert for example.com
    输出
    action: revoke + report CA + add CAA record

预期结果

Continuous 监控的 Certificate Transparency logs 该 detects 未授权 certificate issuance 为你的 domains, 具有 verified SCTs 开所有 legitimate certificates.

常见错误

Not checking SCTs during TLS validation
Modern browsers enforce CT, but custom TLS clients may not. Verify SCT presence and validity in your TLS stack, not just certificate chain validation.
Monitoring only one CT log
Monitor multiple logs (Google, Cloudflare, Let's Encrypt) since certificates may appear in any of them. Use aggregate APIs that search across all logs.
Ignoring CAA DNS records
CAA records restrict which CAs can issue certificates for your domain. Set them to prevent unauthorized CAs from issuing, reducing misissuance risk at the source.

排障指引

  • If your certificate is rejected for lack of SCTs, ensure your CA supports CT and submits to logs during issuance. Let's Encrypt and most modern CAs do this automatically.
  • For internal PKIs (not publicly trusted), CT does not apply — use private CA monitoring instead.
  • If monitoring produces too many false positives, filter by certificate validity period and issuer to reduce noise.

安全限制

  • CT detects misissuance but does not prevent it — the certificate is still valid until revoked. Response speed matters.
  • CT logs are public — your domain names and subdomains are visible in the logs. Do not use CT for internal/private domain names.
  • All certificate verification happens locally; no certificate data is sent to third parties.

相关工具

哈希计算器
计算 MD5、SHA-1、SHA-256 或 SHA-512 哈希,支持十六进制或 Base64 输出。免费、隐私、100% 客户端运行。SHA-256/512 基于 Web Crypto API,MD5 基于 spark-md5,适用于校验和、完整性验证、指纹识别等场景。MD5 与 SHA-1 已不适用于安全场景。
工具
SHA-3 / Keccak 哈希计算器
计算 SHA-3(224/256/384/512)和 Keccak-256 哈希。免费、隐私、100% 客户端运行。
工具
DNS 编码器
Dns Encode — 纯客户端工具。隐私优先,无服务器往返。
工具
DNS 解码器
Dns Decode — 纯客户端工具。隐私优先,无服务器往返。
工具
Base64 编码器
将文本或二进制数据编码为 Base64。免费、隐私优先、100% 纯客户端运行。支持 UTF-8、ASCII、Latin1、UTF-16LE 字符集,可处理多语言文本与二进制内容,结果可直接用于 Data URI、邮件附件、JWT 等场景。
工具
Base64 解码器
将 Base64 数据解码为可读文本。免费、隐私优先、100% 纯客户端运行。支持 UTF-8、ASCII、Latin1、UTF-16LE 字符集,可处理 Data URI、JWT 载荷、邮件附件等场景,遇到非法输入会明确报错而非静默产生乱码。
工具
RSA 工具
使用 Web Crypto API 进行 RSA 密钥生成、加密、解密、签名和验证。免费、隐私优先、100% 纯客户端运行。
工具
时间戳转换器
在 Unix 时间戳和人类可读日期之间转换,显示 UTC 和本地时间。免费、隐私、100% 客户端运行。自动识别秒(10 位)与毫秒(13 位),支持 ISO 8601 等日期字符串解析,适合调试 API 时间戳、日志分析和跨时区时间转换。
工具

相关词条

参考链接