Skip to main content

smb

(smb).SMBClient

SMBClient is a client for SMB servers. Kind: inner class of smb

smbClient.ConnectSMBInfoMode(host, port) ⇒ SMBLog

ConnectSMBInfoMode tries to connect to provided host and port and discover SMB information Kind: instance method of SMBClient
Returns: SMBLog - - The log of the SMB handshake.
Throws:
  • error - The error encountered during the connection.
Example

smbClient.DetectSMBGhost(host, port) ⇒ boolean

DetectSMBGhost tries to detect SMBGhost vulnerability by using SMBv3 compression feature. Kind: instance method of SMBClient
Returns: boolean - - The result of the SMBGhost vulnerability detection.
Throws:
  • error - The error encountered during the detection.
Example

smbClient.ListSMBv2Metadata(host, port) ⇒ ServiceSMB

ListSMBv2Metadata tries to connect to provided host and port and list SMBv2 metadata. Kind: instance method of SMBClient
Returns: ServiceSMB - - The metadata of the SMBv2 service.
Throws:
  • error - The error encountered during the listing.
Example

smbClient.ListShares(host, port, user, password) ⇒ Array.<string>

ListShares tries to connect to provided host and port and list shares by using given credentials. Kind: instance method of SMBClient
Returns: Array.<string> - - The list of shares.
Throws:
  • error - The error encountered during the listing.
Example

(smb).SMBLog : object

SMBLog is an object containing the log of the SMB handshake. Kind: inner typedef of smb

(smb).ServiceSMB : object

ServiceSMB is an object containing the metadata of the SMBv2 service. Kind: inner typedef of smb