Sep 19, 2020

Azure - Manage Secrets

az keyvault create \ --resource-group <your-unique-resource-group-name> \ --location centralus \ --name <your-unique-vault-name> Each secret in a vault has a unique URL, and secret values are retrieved with HTTP GET requests. Add the

Sep 15, 2020

Create shared mailbox & delegate rights.

New-Mailbox –Name "John, Doe" -Shared -PrimarySmtpAddress ***shared-mailbox-email*** Add-MailboxPermission "John, Doe" -User userUPN -AccessRights FullAccess –InheritanceType all Add-RecipientPermission "John, Doe" -Trustee userUPN -AccessRights SendAs -confirm:$False set-mailbox -Identity

Sep 15, 2020

Disable inactive AD accounts

Search-ADAccount -UsersOnly -AccountInactive -SearchBase "OU-disginguishedName" -TimeSpan "30" | Disable-ADAccount Create a scheduled task to run the powershell script... <Exec> <Command>powershell.exe</Command> <

Sep 14, 2020

Monitor server certificate

$servers=((Get-ADForest).Domains | %{ Get-ADDomainController -Filter * -Server $_ }).Name $result=@() foreach ($i in $servers) { $ErrorActionPreference="SilentlyContinue" $a=Invoke-Command -ComputerName $i {Get-ChildItem Cert:\LocalMachine\My -Recurse | Where-Object {$_ -is [System.Security.Cryptography.X509Certificates.X509Certificate2] -and

Sep 14, 2020

(Enable TLS 1.2)

Enables TLS 1.2 on Windows Server 2008 R2 and Windows 7These keys do not exist so they need to be created prior to setting "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\