Skip to content

enum4linux

45 commands

A wrapper around Samba tools that enumerates users, groups, shares, password policy and OS details from Windows and Samba hosts.

  • SMB
  • users
  • shares

Install enum4linux

sudo apt install enum4linux

Basic Enumeration1

enum4linux 192.168.1.10

Performs a standard enumeration scan with default settings against the target IP

Verbose Mode1

enum4linux -v 192.168.1.10

Runs the scan in verbose mode to show all underlying commands and detailed output

Complete Enumeration1

enum4linux -a 192.168.1.10

Executes 'Do Everything' mode, running all standard enumeration options (-U -S -G -P -r -o -n -i)

NetBIOS Name Enumeration1

enum4linux -n 192.168.1.10

Queries NetBIOS names using nmblookup to identify the hostname and workgroup

OS Information1

enum4linux -o 192.168.1.10

Fetches operating system information using smbclient

User Enumeration1

enum4linux -U 192.168.1.10

Enumerates the userlist from the target system using MSRPC or RAP

Machine Enumeration1

enum4linux -M 192.168.1.10

Enumerates the machine list (computer accounts) from the target domain controller

Share Enumeration1

enum4linux -S 192.168.1.10

Lists available SMB shares and attempts to check access permissions

Group Enumeration1

enum4linux -G 192.168.1.10

Enumerates groups and their member lists from the target system

Password Policy Enumeration1

enum4linux -P 192.168.1.10

Retrieves the password policy information such as minimum length and lockout thresholds

Link

Printer Enumeration1

enum4linux -i 192.168.1.10

Checks for attached printers and print spooler services

Link

Detailed Enumeration1

enum4linux -d 192.168.1.10

Performs a detailed enumeration, often useful for retrieving auto-logon information

Link

LDAP Enumeration1

enum4linux -l 192.168.1.10

Attempts to retrieve information via LDAP if the target is a Domain Controller

Link

RID Cycling1

enum4linux -r 192.168.1.10

Performs RID cycling to find users by iterating through Relative IDs

Link

Advanced RID Cycling1

enum4linux -R 500-2000 192.168.1.10

Performs RID cycling using a custom range of IDs from 500 to 2000

Link

RID Cycling with Known User1

enum4linux -k administrator 192.168.1.10

Optimizes RID cycling by starting checks relative to a known valid username

Link

Workgroup Specification1

enum4linux -w CORP 192.168.1.10

Manually specifies the workgroup or domain name 'CORP' for the connection attempt

Link

Authenticated Enumeration1

enum4linux -u admin -p password123 192.168.1.10

Performs enumeration using valid credentials for a specific user

Link

Authenticated Complete Scan1

enum4linux -a -u admin -p password123 192.168.1.10

Runs a full 'Do Everything' scan authenticated as a valid user

Link

Authenticated Share Enumeration1

enum4linux -S -u admin -p password123 192.168.1.10

Lists shares that are visible or accessible to the specified authenticated user

Link

Authenticated User List1

enum4linux -U -u guest -p "" 192.168.1.10

Attempts to list users authenticating as the guest account with an empty password

Link

Explicit Null Session1

enum4linux -u "" -p "" 192.168.1.10

Forces an explicit null session attempt with empty username and password

Link

Target Domain Controller1

enum4linux -a dc.example.local

Runs a full scan against a Domain Controller using its DNS hostname

Link

Quiet Mode1

enum4linux 192.168.1.10 | grep "+"

Runs the tool and filters output to show only section headers and findings

Link

OS and NetBIOS Only1

enum4linux -o -n 192.168.1.10

Performs a lightweight scan checking only OS version and NetBIOS information

Link

Users and Groups Only1

enum4linux -U -G 192.168.1.10

Focuses enumeration solely on discovering users and group memberships

Link

Shares and Policy Only1

enum4linux -S -P 192.168.1.10

Targeted scan to find file shares and password policies without aggressive user cycling

Link

Authenticated RID Cycling1

enum4linux -r -u user -p pass 192.168.1.10

Uses valid credentials to perform RID cycling, often revealing more than null sessions

Link

Large Range RID Cycling1

enum4linux -R 500-10000 192.168.1.10

Aggressive RID cycling over a large range to find hidden accounts on older systems

Link

SMB Version Detection (Implicit)1

enum4linux -o 10.10.10.5

Uses the OS check to infer the SMB version based on the reported operating system

Link

Service Identification1

enum4linux -S 10.10.10.5

Identifies roles like IPC$ (Inter-Process Communication) during share enumeration

Link

Red Team Initial Recon1

enum4linux -a -u "" -p "" 192.168.1.10

Quickly checks if a target allows full enumeration via anonymous null sessions

Link

Blue Team Exposure Validation1

enum4linux -a 10.0.0.5

Used by defenders to verify if a server is leaking sensitive data to unauthenticated users

Link

Logging Output1

enum4linux -a 192.168.1.10 > enum_results.txt

Saves the full enumeration output to a text file for reporting

Link

Verbose Authenticated Scan1

enum4linux -v -u admin -p pass 192.168.1.10

Debug mode with authentication to troubleshoot why specific checks might be failing

Link

Workgroup and Users1

enum4linux -w WORKGROUP -U 192.168.1.10

Targets a specific workgroup context while enumerating the user list

Link

Check Default Admin1

enum4linux -k Administrator -r 192.168.1.10

Specifically checks the Administrator account status via RID cycling logic

Link

Legacy Mode RID1

enum4linux -K 500 -L 1000 192.168.1.10

Uses legacy flags K (start) and L (last) for RID cycling on older script versions

Link

Incident Response Check1

enum4linux -S -u compromised_user -p pass 192.168.1.10

Simulates what a compromised user account can access on the file shares

Link

Domain Info Only1

enum4linux -w DOMAIN -o 192.168.1.10

Retrieves OS and domain controller information for a specific domain target

Link

Share List with Workgroup1

enum4linux -w WORKGROUP -S 192.168.1.10

Lists shares available to the specific workgroup context

Link

Printers and OS1

enum4linux -i -o 192.168.1.10

Identifies printer services and the underlying OS version simultaneously

Link

Groups and Password Policy1

enum4linux -G -P 192.168.1.10

Maps out security groups and the governing password complexity rules

Link

Authenticated Detailed View1

enum4linux -d -u admin -p pass 192.168.1.10

Gets detailed configuration info including auto-logon registry keys using credentials

Link

Automation Friendly1

enum4linux -a 192.168.1.10 2>&1 | tee scan.log

Runs a full scan and pipes both stdout and stderr to a file for automated processing

Link