From a59ead7bd54cb75307da5c8a76ec0b574a0547b2 Mon Sep 17 00:00:00 2001 From: Machiavelli <145562237+MachiavelliII@users.noreply.github.com> Date: Mon, 26 May 2025 07:35:18 +0300 Subject: [PATCH] smbclient.py, impacket-smbclient: add page (#16580) * smbclient.py, impacket-smbclient: add page * Update pages/common/smbclient.py.md Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com> --------- Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com> --- pages/common/impacket-smbclient.md | 7 ++++++ pages/common/smbclient.py.md | 36 ++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 pages/common/impacket-smbclient.md create mode 100644 pages/common/smbclient.py.md diff --git a/pages/common/impacket-smbclient.md b/pages/common/impacket-smbclient.md new file mode 100644 index 0000000000..9138143c63 --- /dev/null +++ b/pages/common/impacket-smbclient.md @@ -0,0 +1,7 @@ +# impacket-smbclient + +> This command is an alias of `smbclient.py`. + +- View documentation for the original command: + +`tldr smbclient.py` diff --git a/pages/common/smbclient.py.md b/pages/common/smbclient.py.md new file mode 100644 index 0000000000..4bd13d2975 --- /dev/null +++ b/pages/common/smbclient.py.md @@ -0,0 +1,36 @@ +# smbclient.py + +> A Python-based SMB client for interacting with SMB servers. +> More information: . + +- Connect to an SMB server with username and password: + +`smbclient.py {{domain}}/{{username}}:{{password}}@{{target}}` + +- Connect using NTLM hashes for authentication: + +`smbclient.py -hashes {{LM_HASH}}:{{NT_HASH}} {{domain}}/{{username}}@{{target}}` + +- Connect using Kerberos authentication: + +`smbclient.py -k {{domain}}/{{username}}@{{target}}` + +- Connect specifying a domain controller IP: + +`smbclient.py -dc-ip {{domain_controller_ip}} {{domain}}/{{username}}:{{password}}@{{target}}` + +- Connect to a specific target IP instead of NetBIOS name: + +`smbclient.py -target-ip {{target_ip}} {{domain}}/{{username}}:{{password}}@{{target}}` + +- Connect to a non-standard SMB port: + +`smbclient.py -port {{port}} {{domain}}/{{username}}:{{password}}@{{target}}` + +- Execute commands from an input file in the SMB shell: + +`smbclient.py -inputfile {{path/to/input_file}} {{domain}}/{{username}}:{{password}}@{{target}}` + +- Log SMB client commands to an output file: + +`smbclient.py -outputfile {{path/to/output_file}} {{domain}}/{{username}}:{{password}}@{{target}}`