πŸ“ File & Directory Management

Navigation

  • cd : Change directory.
  • cd ..: Go back to the previous directory.
  • cd /: Go to the root partition.
  • pushd : Push directory.
  • popd: Pop directory.
  • cd %USERPROFILE%: Go to user profile directory.
  • cd %TEMP%: Go to temporary directory.
  • cd /d : Change drive and directory.

Viewing Contents

  • dir: Show files and folders.
  • type : Display file contents.
  • more : Display file contents page-by-page.
  • tree: Display directory structure graphically.
  • dir /w: Wide list format.
  • dir /p: Pause after each screen.
  • dir /s: Include subdirectories.
  • dir /a: Show hidden files.
  • dir /o:n: Sort by name.
  • dir /o:d: Sort by date.
  • dir /o:s: Sort by size.
  • tree /f: Show files in tree.
  • tree /a: Use ASCII characters.

Creation & Deletion

  • md / mkdir : Create a directory.
  • rd / rmdir : Remove a directory.
  • del / erase : Delete one or more files.

Copying, Moving & Renaming

  • copy : Copies files.
  • xcopy : Copies files and directory trees (advanced).
  • robocopy : Robust file copy.
  • move : Moves files or directories.
  • rename / ren : Renames a file or directory.
  • mklink : Create symbolic or hard links.

βš™οΈ System & Process Management

Tasks & Utilities

  • tasklist: List running tasks.
  • taskkill /pid 9716: Kill the task with process ID 9716.
  • calc: Open the calculator.
  • cls: Clear the screen.
  • winver: Check Windows version.
  • hostname: Display the hostname of the computer.
  • start : Start a program or open a file/URL.
  • title : Set command prompt window title.
  • color : Change console color.
  • help : Get help for a command.
  • ver: Display OS version.
  • where : Locate files in PATH.
  • echo : Display messages / control command echoing.
  • pause: Pause script execution.
  • exit: Exit command prompt or script.
  • | (Pipe): Redirect output.
  • > & >>: Redirect output to file.

Hardware & Disk Info

  • driverquery: List installed and missing drivers.
  • wmic cpu: Get CPU information.
  • wmic nic get macaddress: Get MAC address information.
  • wmic process list brief: List all processes.
  • systeminfo: Displays detailed system information.
  • date: Displays or sets the system date.
  • time: Displays or sets the system time.
  • vol: Displays the disk volume label and serial number.
  • label : Change disk volume label.

Firewall Control

  • netsh advfirewall set all state off: Turn off the firewall.
  • netsh advfirewall set all state on: Turn on the firewall.

πŸ›‘οΈ Advanced Operations & Security

User & Group Management

  • lusrmgr.msc: Open Windows user management tool.
  • net user: Check all users.
  • net localgroup: Manage local groups.
  • query user / quser: Query user sessions.
  • net accounts: Manage user account policy.
  • net group: Manage global groups.
  • whoami: Display current user info.
  • net user hacker 123456 /add: Add user 'hacker' with password '123456'.
  • net user hacker /del: Delete user 'hacker'.
  • logoff: Log off a user.
  • runas /user: : Run as different user.
  • net user /active:no: Disable user account.
  • net user /active:yes: Enable user account.
  • net user /passwordchg:no: Prevent password change.

Security & Attributes

  • cipher /e: Encrypt files.
  • cipher /d: Decrypt files.
  • attrib +h +r +s: Hide files.
  • attrib -h -r -s: Unhide files.
  • compact /c /s:: Compress files/folders.
  • takeown /f : Take ownership of a file.
  • icacls /grant :F: Set file permissions (advanced).
  • cacls /g :F: Set file permissions (legacy).
  • cipher /w:: Securely wipe free space.
  • attrib +s : Set system attribute.
  • attrib +a : Set archive attribute.

Group Policy & Security Config

  • gpupdate: Update Group Policy.
  • gpresult /r: Display Group Policy results.
  • secedit /configure /db : Configure security.
  • gpresult /h report.html: Generate HTML report.
  • gpresult /z: Display super verbose output.
  • secedit /export /cfg : Export security configuration.
  • secedit /validate : Validate security template.

Audit & Event Logging

  • auditpol /get /category:*: Get audit policy.
  • relog : Relog performance counters.
  • wevtutil el: List event logs.
  • openfiles /query: Query open files.
  • auditpol /set /category:* /success:enable: Enable success auditing.
  • auditpol /set /category:* /failure:enable: Enable failure auditing.
  • wevtutil qe /f:text: Query event log.
  • wevtutil cl : Clear event log.

Registry & Service Mgmt

  • reg query : Query registry.
  • reg add /v /t /d : Add registry entry.
  • reg delete /v : Delete registry entry.
  • sc query : Query service status.
  • net start : Start a service.
  • net stop : Stop a service.
  • svchost: Host for services.
  • reg export : Export registry key.
  • reg import : Import registry file.
  • sc config start=auto: Set service to auto-start.
  • sc config start=disabled: Disable service.

Scheduled Tasks

  • schtasks /create: Create scheduled task.
  • schtasks /query: Query scheduled tasks.
  • taskschd.msc: Open Task Scheduler.
  • schtasks /delete /tn : Delete scheduled task.
  • schtasks /run /tn : Run scheduled task immediately.
  • schtasks /end /tn : End running scheduled task.
  • schtasks /change /tn /enable: Enable scheduled task.
  • schtasks /change /tn /disable: Disable scheduled task.

🌐 Network & Connectivity

Wi-Fi Management

  • netsh wlan show profiles: Show all Wi-Fi profiles.
  • netsh wlan show all: Show all network information.
  • netsh wlan show profile blackhat key=clear: Show Wi-Fi password for 'blackhat' profile.
  • netsh wlan delete profile name=blackhat: Delete Wi-Fi profile 'blackhat'.
  • netsh: Network Shell utility.

Network Diagnostics

  • ipconfig: Display IP configuration.
  • ping : Send ICMP echo requests.
  • tracert : Trace route to host.
  • pathping : Trace route with latency.
  • netstat -e: Check data usage.
  • netstat -an: Display all connections and listening ports.
  • nbtstat -a : Display NetBIOS over TCP/IP statistics.
  • arp -a: Display ARP cache.
  • route print: Display routing table.
  • net view: View network resources.
  • net session: List network sessions.
  • net share: List network shares.
  • net use \\\: Map network drive.
  • net config server: Display server configuration.
  • telnet : Telnet client (if installed).
  • ftp : FTP client.
  • tftp get : TFTP client.
  • nslookup google.com: Get IP address of google.com.
  • curl : Transfer data from/to a server.
  • wget : Download files from the web.

🩺 System Diagnostics & Health

File & Disk Integrity

  • sfc /scannow: System File Checker.
  • chkdsk: Check disk.
  • diskpart: Disk Partition Utility.
  • format : Format a disk.
  • bootrec /fixmbr: Repair boot configuration.
  • reagentc /info: Windows Recovery Environment config.
  • bcdedit /enum: Boot Configuration Data editor.
  • cleanmgr: Disk Cleanup utility.

Performance & Event Monitoring

  • perfmon: Performance Monitor.
  • eventvwr: Event Viewer.
  • dxdiag: DirectX Diagnostic Tool.
  • resmon: Resource Monitor.
  • msinfo32: System Information.
  • lodctr: Load/Unload Perfmon Counters.
  • vssadmin list shadows: Volume Shadow Copy Service.
  • drwtsn32: Dr. Watson Debugger (Legacy).

πŸ‘¨β€πŸ’» Development & Build Tools

Languages & Runtimes

  • python: Python interpreter.
  • java: Java runtime.
  • javac: Java compiler.
  • node: Node.js runtime.
  • dotnet: .NET CLI.
  • php: PHP interpreter.
  • go: Go language compiler/tool.
  • rustc: Rust compiler.
  • cl: MSVC C/C++ compiler.
  • g++: GNU C++ compiler.
  • clang: Clang C/C++/Objective-C compiler.
  • tsc: TypeScript compiler.

Package Managers & Version Control

  • pip: Python package installer.
  • npm: Node.js package manager.
  • npx: Execute Node.js packages.
  • git: Version control system.
  • svn: Subversion.
  • hg: Mercurial.
  • cargo: Rust package manager/build system.
  • composer: PHP dependency manager.
  • yarn: Fast, reliable, secure Node.js package manager.
  • pnpm: Performant Node.js package manager.

Build Systems & IDEs

  • msbuild: Microsoft Build Engine.
  • cmake: Cross-platform build system generator.
  • make: Build automation tool.
  • code: Visual Studio Code.
  • devenv: Visual Studio IDE.

πŸ–₯️ System Administration & Scripting

Service & Task Management

  • sc query : Query service status.
  • net start : Start a service.
  • net stop : Stop a service.
  • schtasks /create: Create scheduled task.
  • schtasks /query: Query scheduled tasks.
  • taskschd.msc: Open Task Scheduler.
  • logman query: Manage performance logs.
  • svchost: Host for services.

Registry Management

  • reg query : Query registry.
  • reg add /v /t /d : Add registry entry.
  • reg delete /v : Delete registry entry.

Scripting & Utilities

  • powershell: Launch PowerShell.
  • cmdkey /list: Credential Manager.
  • mshta : HTML Application host.
  • msiexec /i : Windows Installer.
  • rundll32 ,: Run DLL function.
  • wscript : Windows Script Host (VBScript/JScript).
  • cscript : Windows Script Host (console).
  • tzutil /g: Time Zone Utility.
  • slmgr /dli: Windows Software Licensing Management Tool.
  • bdehdcfg: BitLocker Drive Encryption.
  • bcdboot : Create/repair boot files.

πŸ”¬ Sysinternals Tools (Advanced)

Process & System Monitoring

  • procexp: Process Explorer.
  • procmon: Process Monitor.
  • autoruns: Autoruns utility.
  • pslist: List processes (PsTools).
  • psinfo: System information (PsTools).
  • du: Disk Usage (Sysinternals).
  • diskmon: Disk Activity Monitor.

Process Control & File Utilities

  • psexec : Execute processes remotely.
  • pskill : Kill process (PsTools).
  • handle : View open handles.
  • sdelete -z : Securely delete files.
  • strings : Extract strings from files.
  • sigcheck : Verify file signatures.
  • contig : Defragment files.
  • accesschk : Check access permissions.

Network & Info Gathering

  • tcpview: TCP/UDP endpoint viewer.
  • whois : Domain registration lookup.
  • bginfo: Desktop background info.

πŸ–ΌοΈ Windows Built-in Apps & Shortcuts

Core Applications

  • explorer.exe: Open File Explorer.
  • calc: Open Calculator.
  • notepad: Open Notepad.
  • mspaint: Open Paint.
  • snippingtool: Open Snipping Tool.

Settings & URI Schemes

  • start ms-settings:: Open Settings app.
  • start bing:: Open Bing search.
  • start microsoft-edge:: Open Microsoft Edge.
  • start outlook:: Open Outlook.

Control Panel Applets & MMC Snap-ins

  • services.msc: Services management.
  • compmgmt.msc: Computer Management.
  • devmgmt.msc: Device Manager.
  • gpedit.msc: Local Group Policy Editor.
  • eventvwr.msc: Event Viewer.
  • secpol.msc: Local Security Policy.
  • appwiz.cpl: Programs and Features.
  • firewall.cpl: Windows Defender Firewall.
  • sysdm.cpl: System Properties.
  • ncpa.cpl: Network Connections.
  • inetcpl.cpl: Internet Properties.
  • lusrmgr.msc: Local Users and Groups.
  • diskmgmt.msc: Disk Management.

πŸ“¦ Package Management & Terminal

Package Managers

  • winget: Windows Package Manager.
  • choco: Chocolatey Package Manager.
  • pip: Python Package Installer.
  • npm: Node.js Package Manager.

Terminal Applications

  • wt: Windows Terminal.
  • cmd: Command Prompt.
  • powershell: Windows PowerShell.
  • terminal: (Alias for wt).

πŸ•°οΈ Legacy & Compatibility Commands

DOS-era Utilities

  • debug: Debugger (Legacy).
  • edlin: Line editor (Legacy).
  • qbasic: QBasic interpreter (Legacy).
  • command.com: DOS command interpreter (Legacy).
  • doskey: Command-line history and macros.
  • msav: Microsoft Anti-Virus (Legacy).
  • interlnk: Interlink client (Legacy).
  • assign =: Assign drive letter (Legacy).
  • append : Set search path for data files (Legacy).
  • join : Join drive to directory (Legacy).
  • sort : Sort text file.

MMC Snap-ins & Control Panel Applets

  • services.msc: Services management.
  • compmgmt.msc: Computer Management.
  • devmgmt.msc: Device Manager.
  • gpedit.msc: Local Group Policy Editor.
  • eventvwr.msc: Event Viewer.
  • secpol.msc: Local Security Policy.
  • appwiz.cpl: Programs and Features.
  • firewall.cpl: Windows Defender Firewall.
  • sysdm.cpl: System Properties.
  • ncpa.cpl: Network Connections.
  • inetcpl.cpl: Internet Properties.
  • lusrmgr.msc: Local Users and Groups.
  • diskmgmt.msc: Disk Management.

🐧 Linux-like Commands (WSL/Git Bash)

Basic File & Directory

  • ls: List directory contents.
  • pwd: Print working directory.
  • clear: Clear terminal screen.
  • rm : Remove files or directories.
  • mv : Move or rename files/directories.
  • cp : Copy files/directories.
  • touch : Create empty file or update timestamp.

Text Processing & System Info

  • cat : Concatenate and display files.
  • grep : Search text.
  • head : Display first lines of file.
  • tail : Display last lines of file.
  • less : View file interactively.
  • env: Display environment variables.
  • printenv: Display environment variables (alternative).
  • history: Display command history.
  • man : Display manual page.
  • top: Display Linux processes (interactive).
  • htop: Interactive process viewer (enhanced).
  • alias =: Create command alias.

Note: This guide covers essential Windows commands. It’s recommended to experiment in a controlled environment to build and refine your skills..