33 lines
1.0 KiB
YAML
33 lines
1.0 KiB
YAML
id: smb-shares
|
|
|
|
info:
|
|
name: SMB Shares - Enumeration
|
|
author: pussycat0x
|
|
severity: low
|
|
description: |
|
|
Attempts to list shares using the srvsvc.NetShareEnumAll MSRPC function and retrieve more information about them using srvsvc.NetShareGetInfo. If access to those functions is denied, a list of common share names are checked.
|
|
reference:
|
|
- https://nmap.org/nsedoc/scripts/smb-enum-shares.html
|
|
metadata:
|
|
verified: true
|
|
max-request: 1
|
|
shodan-query: port:445
|
|
tags: js,network,smb,enum
|
|
javascript:
|
|
- code: |
|
|
var m = require("nuclei/smb");
|
|
var c = m.SMBClient();
|
|
var response = c.ListShares(Host, Port, User, Pass);
|
|
to_json(response);
|
|
|
|
args:
|
|
Host: "{{Host}}"
|
|
Port: "445"
|
|
User: "test"
|
|
Pass: "test"
|
|
|
|
extractors:
|
|
- type: json
|
|
json:
|
|
- '.[]'
|
|
# digest: 4a0a00473045022074af30e3f523f1af8e7f6adf1b3da6943559db29198020d8803738b1934eff0b022100f8e908053b0b14f9231e0f654d889c305c39dc6cd5c1b52fd5b09359f583232d:922c64590222798bb761d5b6d8e72950 |