Git Product home page Git Product logo

get-passwdhashes's Introduction

Get-PasswdHashes

NTHash extraction from SAM and SYSTEM. (mounted to registry)

Overview

Extract NTHashes from Windows systems using PowerShell scripts. This script uses information from the SAM and SYSTEM registry keys to collect NTHashes used in Windows systems.

Usage

Run the ps1 file with administrator privileges. ./Get-PasswdHashes.ps1.

Result-Example

(USERNAME):1004:aad3b435b51404eeaad3b435b51404ee:36aa83bdcab3c9fdaf321ca42a31c3fc:::

NThash PlainPassword
36aa83bdcab3c9fdaf321ca42a31c3fc pass

Brief Information

โš ๏ธ This may include a lot of lack of understanding.

In Windows operating systems, user account information and associated password hashes are stored in the SAM (Security Account Manager) database. System configuration information is also stored in the SYSTEM registry key. To extract the NTLM hashes from these data, perform the following steps

  1. Use a PowerShell script to retrieve information from the SAM-database(mounted to registry) and the SYSTEM-registry.
  2. Extract the user name and encrypted NTHash for each user account from the SAM-database.
  3. Retrieve data for each system configuration information from the SYSTEM registry key. This data includes the type of hash function used on each system and the version of the NTLM hash generated by that hash function.
  4. The retrieved information is analyzed and the NTLM hash is extracted in composite form.

See ### SAM Decryption Flow for details.

R. Chandel, "Credential Dumping: SAM - Hacking Articles," Apr. 2020, .

SAM Decryption Flow

SAM Decryption

Notes

This script is based on various existing projects. Thank you!
This script is for research purposes only. All activities conducted using this script must comply with legal and ethical regulations. You must also obtain the explicit permission of the system owner before using this script.

References

The following resources were used as references in the development of this script.

Nishang Lazagne-creddump7

get-passwdhashes's People

Contributors

4na7i1 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.