id: smb-version-detect info: name: SMB Version - Detection author: pussycat0x severity: info description: | SMB version detection involves identifying the specific Server Message Block protocol version used by a system or network. This process is crucial for ensuring compatibility and security, as different SMB versions may have distinct features and vulnerabilities. metadata: max-request: 1 shodan-query: "port:445" tags: js,network,smb,enum javascript: - code: | let m = require("nuclei/smb"); let c = new m.SMBClient(); let response = c.ConnectSMBInfoMode(Host, Port); Export(response); args: Host: "{{Host}}" Port: "445" matchers: - type: dsl dsl: - "len(smb-version) != 0" extractors: - type: json name: smb-version json: - '.Version.VerString' # digest: 4a0a0047304502203db641d02e5d92b195b7c32bc022ff57227ac479cc970391b2c513538c827f52022100c5b9e5467b6e319975f14b151536704dfbd011b6a185f5efee3e6acbad9ee10a:922c64590222798bb761d5b6d8e72950