ShellSpells
  • 🧙‍♂️Welcome!
    • ShellSpells
    • FAQs
    • License & Disclaimer
  • 🐧Linux
    • System Ops
      • Transcripts
      • Help
      • System Info
        • Date/Time
        • System Details
        • Patches & Updates
        • Init System Identification
        • Hostname / Host ID
        • Variables
        • Hardware & Resources
      • Filesystem
        • Traverse & Enumerate
        • Drives & Partitions
        • Shares
        • Packages
        • Connected Devices
        • Kernel Modules (Drivers)
      • Users & Groups
        • Enumerate
        • Modify
      • Network
        • Enumerate
        • Modify
      • Scheduled Jobs
        • Enumerate
        • Modify
      • Processes
        • Enumerate
        • Modify
        • Custom Script and Shared Object
        • Process I/O Redirection
      • Services
        • Enumerate
        • Modify
        • Create a Service
      • Startup/Boot Scripts
        • Enumerate
        • Modify
      • Security
        • Antivirus
        • Firewall
        • SSH Keys
      • History & Logs
        • History
        • Logs
    • File Ops
      • Search
        • Filename
        • Content
        • Users (Owners)
        • Time
        • Size
        • Permission
        • Hidden Files
        • Inode
        • Find + Exec
        • Notes
      • Enumerate Metadata
      • Modify Metadata
      • Read Content
      • Modify Content
      • Extract Content
      • Sort / Compare / Count
      • Move
      • Copy
      • Execute
      • Hash
      • Encode/Decode
      • Compress/Decompress
      • Working With Weird Filenames
    • Terminal Ops
      • Keyboard Shortcuts
      • Tmux Shortcuts
  • 🪟Windows
    • System Ops
      • Transcripts
      • Help
      • System Info
        • One-liners
        • Date/Time
        • System Details
        • Hotfixes
        • Domain or Workgroup
        • Data Execution Prevention
        • Variables
        • Hardware & Resources
      • Filesystem
        • Traverse & Enumerate
        • Drives & Partitions
        • Installed Software
        • Drivers
        • Shares
      • Registry
        • Enumerate
        • Modify
        • Forensically Relevant Keys
      • Users & Groups
        • Enumerate
        • Modify
      • Network
        • Enumerate
        • Modify
      • Scheduled Tasks
      • Processes
        • Enumerate
        • Modify
      • Services
        • Enumerate
        • Modify
      • Autorun / Startup
        • Enumerate
        • Modify
      • Security
        • Permissions
          • Enumerate
          • Page
        • Antivirus
        • Firewall
          • Enumerate
          • Modify
        • Audit Policies
        • Remoting
          • Enumerate
          • Modify
          • Registry Locations
        • Stored Credentials
      • Remote Command Execution
      • Active Directory
        • Enumerate
        • Modify
      • History & Logs
        • History
        • Logs
      • PowerShell Config
      • Scripting
      • WMIC Notes
    • File Ops
      • Search
        • Filename
        • Time
        • Size
        • Permissions
        • Attributes
        • Wildcarding
      • Enumerate Metadata
        • One Liners
        • Users (Owners)
        • Timestamps
        • Size
        • Permissions
        • Attributes
      • Modify Metadata
        • Change Owner
        • Timestamps
        • Size
        • Attributes
      • Read Content
      • Modify Content
        • Overwrite
        • Insert
        • Append
        • Replace / Remove
        • Convert Case
        • Alternate Data Streams
      • Extract Content
      • Sort / Compare / Count
        • Sort
        • Count
        • Compare
      • Move
      • Copy
      • Execute
      • Hash
      • Encode/Decode
      • Compress/Decompress
      • Working With Weird Filenames
      • Output Formatting / Filtering
      • File Formatting
      • Operators
  • ⛓️Network
    • Traffic Manipulation
      • iptables
        • Option List
        • General Commands
        • Filter Tables
        • NAT
        • Mangle
        • Filter for SSH Traffic (Example)
      • nftables
    • Packet Capture
      • Syntax
      • TCPDump Examples
    • Packet Analysis
      • Wireshark
  • 🚗Maneuver
    • SSH
    • Control Sockets
    • RDP
    • Windows Port Proxy
  • 🛩️Data Transfer
    • SCP
    • FTP
    • Netcat
      • Netcat Relays
    • Server Interactions
    • Alternate Methods
  • 🪄REGEX
    • Examples
Powered by GitBook
On this page
  • Commands
  • Basic Query
  • Querying a Specific Value
  • Searching for a Value
  • Searching Recursively
  • Comparing Values in Two Keys
  • Exporting a Key to a File
  • Remote

Was this helpful?

  1. Windows
  2. System Ops
  3. Registry

Enumerate

Commands

regedit

GUI

reg query HKLM\Software

Lists all subkeys and values

reg query HKCU

Lists subkeys and values under the HKCU registry hive.

reg export HKLM\Software filename.reg

Exports to a .reg file.

Get-ChildItem -Path Registry::HKEY_LOCAL_MACHINE\Software

Enumerates registry keys and values under HKLM in PowerShell.

(Get-Item -Path Registry::HKEY_LOCAL_MACHINE\Software).Property

Lists all value names under a registry key in PowerShell.

Get-ItemProperty -Path Registry::HKEY_LOCAL_MACHINE\Software

Retrieves properties (values) of the Run key in PowerShell.

Basic Query

Displays values and data for keys under the "Run" key:

reg query HKLM\Software\Microsoft\Windows\CurrentVersion\Run

Querying a Specific Value

reg query HKCU\Control Panel\Desktop /v Wallpaper

Shows the current desktop wallpaper path.

Replace "Wallpaper" with the name of the desired value.

Searching for a Value

reg query HKLM /f "Chrome" /t REG_SZ

Searches all keys under HKLM (local machine hive) for values containing "Chrome" of type REG_SZ (string).

Searching Recursively

reg query HKLM /s /f "Explorer" /t REG_DWORD

Searches all subkeys under HKLM for values containing "Explorer" of type REG_DWORD (32-bit integer).

Comparing Values in Two Keys

reg query HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon /v Shell /ve

Displays only empty values for the "Shell" value.

Exporting a Key to a File

reg export HKCU\Software\MyApp C:\Backup\MyAppSettings.reg

Exports the "MyApp" key and its subkeys to a .reg file for backup or transfer.

Remote

Remote registry: Use \ComputerName\ before the root key to query a remote computer's registry.

PreviousRegistryNextModify

Last updated 1 year ago

Was this helpful?

🪟