A powershell function to make using Powershell a lot more fun!
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
Hardcore Powershell.ps1


Ainsey11's Hardcore Powershell Function

This awesome bit of code makes using powershell more hardcore, if you get a command wrong it can do two things.

  1. Lock your AD Account
  2. Disable your AD Account


you can add it to your global profile in powershell or run it when you want to, it's up to you! when using the function run it as so:

Start-HardcoreMode -Hardcoreness

the levels are :

1 - locks AD account 2 - Disables AD account

The initial idea came from a colleague and friend (jfrmilner) who suggested that I made the code from here : http://deploymentresearch.com/Research/Post/390/Enabling-PowerShell-Hardcore-Mode lock or disable AD Accounts. I took the idea and made this glorious function! you can see his blog over at : https://jfrmilner.wordpress.com/


I have created this script for people to have a laugh and challenge themselves. I will not be held responsible for any data loss or damage caused by this script.Always test scrips in a non-production environment and make sure that you're happy before running on a live system. This is a standard disclaimer I use on all my code.