nuclei-templates/javascript/enumeration/smb/smb-enum-domains.yaml

43 lines
1.2 KiB
YAML

id: smb-enum-domains
info:
name: SMB - Enum Domains
author: DhiyaneshDK
severity: info
description: |
SMB enumeration of domains is often part of the reconnaissance phase, where security professionals or attackers attempt to gather information about the target network to identify potential vulnerabilities.
reference:
- https://nmap.org/nsedoc/scripts/smb-enum-domains.html
metadata:
verified: true
max-request: 1
shodan-query: port:445
product: dionaea
vendor: dionaea
tags: js,network,smb,enum
javascript:
- code: |
var m = require("nuclei/smb");
var c = new m.SMBClient();
var response = c.ListSMBv2Metadata(Host, Port);
Export(response);
args:
Host: "{{Host}}"
Port: "445"
matchers:
- type: dsl
dsl:
- "len(DNSDomainName) != 0"
extractors:
- type: json
internal: true
name: DNSDomainName
json:
- '.DNSDomainName'
- type: json
json:
- '"DomainName: "+ .DNSDomainName '
# digest: 4a0a00473045022100d8fce979c08ce14ebb597411a9e84a004b9e5acd7ed54eed1d5c7cf76330404c02207d1fb84dc54f6612d2fc223c13ca0005e6635c2b6ed76f51b7829fdac23a221d:922c64590222798bb761d5b6d8e72950