I’ve found this great function written by Thomas Maurer on his blog. It’s really usefull to automate MySQL queries.
Installs a .pfx file
Unzip compressed files (without any external tool)
This one is really usefull. Open a ssh session and run commands from PowerShell with PLink… Love it!
Get the localhost uptime, in days
Configure and enable a proxy server
Read some registry keys to check if the Windows 2003 server is hardened or not
Read the registry to determine which .NET Framework version(s) is/are installed
Send an email, uses Net.Mail.SmtpClient
Test if an IP address has a valid format, IPv4 or IPv6
Create a (really) random password
Prompt the user for ‘Yes’ or ‘No’.
Check if a value is numeric or not.