Certificate, CSR & Private Key Matcher

Cryptographically verify whether a Private Key, Certificate Signing Request (CSR), and Leaf Certificate belong to the same certificate/key pair.

Modulus & SPKI Check Leaf Verification In-Memory Only
Provide Files or PEM Text to Match
1. Private Key .key / .pem
— OR PASTE TEXT —
Supports unencrypted PKCS#1 and PKCS#8 RSA/EC private keys. Drag & drop file onto this card supported.
2. Certificate Request (CSR) .csr / .req
— OR PASTE TEXT —
Supports standard PKCS#10 Certificate Signing Requests. Drag & drop file onto this card supported.
3. Leaf Certificate .crt / .cer
— OR PASTE TEXT —
Upload the End-Entity (Leaf) SSL/TLS server certificate. Drag & drop file onto this card supported.
All dates and times in analysis results and Excel exports are formatted in this timezone.
Loading...
Cryptographically verifying key pair and certificate lifecycle...
In-Memory Processing Keys and certificates are never logged or stored
Reset
No Files Matched Yet

Upload or paste your Private Key, CSR, and Leaf Certificate above to cryptographically verify if they belong to the same key pair. Or click below to try a verified sample matching set.

Understanding Certificate, CSR, and Private Key Matching
Cryptographic Pair Verification
How Cryptographic Matching Works

In public-key cryptography (such as RSA or ECDSA), every certificate lifecycle revolves around a single asymmetric key pair:

  • Private Key: Kept strictly confidential on your server. For RSA, it contains secret prime numbers p and q which compute the public modulus n = p × q and private exponent d.
  • Certificate Signing Request (CSR): Sent to a Certificate Authority (CA). Contains your public key (the modulus n and exponent e) and requested domain identities, cryptographically self-signed with your private key.
  • Leaf Certificate: Issued by the CA. Contains your exact public key (the identical modulus n) signed by the CA's intermediate key.
  • SPKI Pinning: The Subject Public Key Info (SPKI) SHA-256 hash produces a distinct, format-independent fingerprint of the public key structure, guaranteeing 100% cryptographic certainty.
Matching via OpenSSL CLI

Sysadmins often use OpenSSL to print and compare the SHA-256 or MD5 checksum of the modulus:

# 1. Check Private Key Modulus SHA-256:
openssl rsa -noout -modulus -in private.key | openssl sha256
# 2. Check CSR Modulus SHA-256:
openssl req -noout -modulus -in request.csr | openssl sha256
# 3. Check Certificate Modulus SHA-256:
openssl x509 -noout -modulus -in certificate.crt | openssl sha256

If all three commands output the exact same 64-character hash, the files belong to the same key pair. For ECDSA keys, compare the public key coordinates: openssl ec -in key.pem -pubout.

Diagnosing & Resolving Web Server Key Mismatch Errors
Nginx: SSL_CTX_use_PrivateKey_file() failed

When Nginx fails to start with error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch, the certificate specified in ssl_certificate does not correspond to ssl_certificate_key.

Resolution: Use this tool to compare all available .key and .crt files on your server until a 100% Modulus & SPKI match is verified.
Apache: Private key does not match certificate

Apache HTTP Server logs AH00016: Configuration Failed with SSL Library Error: error:0B080074:key values mismatch when SSLCertificateFile and SSLCertificateKeyFile point to different key generations.

Resolution: Confirm whether a recent renewal generated a new private key in /etc/ssl/private/ or Let's Encrypt live directory.
Common Causes of Mismatches
Re-generated Private Key

Generating a new CSR often generates a new private key. If an older private key is deployed instead of the newly generated key, the web server fails to start.

Intermediate / Chain Upload

Uploading an Intermediate CA bundle instead of the server Leaf certificate will result in a mismatch because the CA has its own independent key pair.

Wrong Domain / Multi-SAN

On servers hosting multiple virtual hosts, accidentally referencing the private key of an adjacent domain or stale certificate is a frequent operational mistake.

Frequently Asked Questions

WONTERA.IO operates with a strict in-memory execution architecture. Uploaded private keys are processed purely in volatile system RAM to compute their public parameters and hashes; they are never written to disk, never logged to database records, and never transmitted across external networks. The buffers are zeroed and deallocated immediately upon request termination.

You do not need all three files! The tool supports partial pair matching. You can match a Private Key with a Certificate, a Private Key with a CSR, or a CSR with a Certificate. The matcher compares the public key modulus and SPKI pin between whichever files are provided.

Encrypted private keys (ENCRYPTED PRIVATE KEY) protect key parameters with a passphrase. To inspect an encrypted key, you must either decrypt it locally with OpenSSL (openssl rsa -in enc.key -out dec.key) or provide an unencrypted PEM/DER key file.