Created
December 5, 2024 20:39
-
-
Save nullenc0de/b31ec44c612bdabef98f3d92e2a4b307 to your computer and use it in GitHub Desktop.
Exposed Internal PKI Infrastructure Detection nuclei template
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
id: exposed-pki-infrastructure | |
info: | |
name: Exposed Internal PKI Infrastructure Detection | |
author: nullenc0de | |
severity: critical | |
description: Detects exposed internal PKI infrastructure including CRL distribution points and OCSP responders | |
tags: pki,exposure,misconfig | |
requests: | |
- method: GET | |
path: | |
- "{{BaseURL}}/certsrv/" | |
- "{{BaseURL}}/pki/" | |
- "{{BaseURL}}/crl/" | |
- "{{BaseURL}}/.well-known/pki-validation/" | |
- "{{BaseURL}}/ocsp/" | |
- "{{BaseURL}}/CertEnroll/" | |
- "{{BaseURL}}/CertSrv/" | |
matchers-condition: or | |
matchers: | |
- type: word | |
words: | |
- "Microsoft-IIS/10.0" | |
- "certsrv" | |
- "Certificate Services" | |
- "Microsoft CA" | |
- "Certificate Authority" | |
- "CRL Distribution Point" | |
- "OCSP Responder" | |
condition: or | |
- type: status | |
status: | |
- 200 | |
- 401 | |
- 403 | |
- type: regex | |
regex: | |
- "CN=[A-Za-z0-9-]+-CA" | |
- "\.crl$" | |
- "\.cer$" | |
- "\.p7b$" | |
extractors: | |
- type: regex | |
name: certificate_details | |
regex: | |
- "CN=[A-Za-z0-9-]+-CA" | |
- "O=[A-Za-z0-9 ]+" | |
- "OU=[A-Za-z0-9 ]+" | |
Stop-If-Match: true | |
http: | |
- max-redirects: 2 | |
- follow-redirects: true | |
- tls-verification: false |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
id: exposed-pki-infrastructure
info:
name: Exposed Internal PKI Infrastructure Detection
author: nullenc0de
severity: critical
description: Detects exposed internal PKI infrastructure including CRL distribution points and OCSP responders
tags: pki,exposure,misconfig
http:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
method: GET
path:
matchers-condition: and
matchers:
words:
condition: and
status:
regex:
extractors:
name: certificate_details
part: body
group: 0
regex: