0xma Cyber Security Articles




July 23, 2021

Browse SMB File Shares with smbmap

In this tutorial we will see how to connect to a SMB server using credentials and browse it to find directories or files that we are interested in. We will also cover how to download individual files from the SMB server and find them on the local machine.

Now let's connect to the SMB server. We have passed on four options to this command which are:

We can see a long listing of all the available paths on this server.

Connecting to a SMB server using smbmap.

We can browse a specific directory if we choose to do so. In this case we are browsing the "Users" directory. The -r option allows us to point smbmap to a specific directory.

Browsing a specific directory using smbmap.

It shows us the contents of the "Users\SVC_TGS\Desktop" directory.

Browsing a specific directory using smbmap.

In the "Users\SVC_TGS\Desktop" directory, there is a file called user.txt. The --download option in smbmap allows us to download a specific file if we choose to do so.

Downloading a file with smbmap.

This shows that the user.txt file has been downloaded to the local machine.

Accessing the contents of the downloaded file.

If you liked reading this article, you can follow me on Twitter: 0xmaCyberSec.