This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-AdObject -Filter 'IsDeleted -eq $True' -IncludeDeletedObjects -Properties * | Out-GridView -OutputMode Single | Remove-ADObject |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check enrollment URLs at | |
# https://intune.microsoft.com/#view/Microsoft_AAD_IAM/MdmConfiguration.ReactView/appId/0000000a-0000-0000-c000-000000000000/appName/Microsoft.Intune | |
# Set MDM Enrollment URLs | |
$joinedTenantKey = (Get-ChildItem 'HKLM:\SYSTEM\CurrentControlSet\Control\CloudDomainJoin\TenantInfo') | |
$joinedTenantKey | New-ItemProperty -Name 'MdmTermsOfUseUrl' -Value 'https://portal.manage.microsoft.com/TermsofUse.aspx' -PropertyType String -Force | |
$joinedTenantKey | New-ItemProperty -Name 'MdmEnrollmentUrl' -Value 'https://enrollment.manage.microsoft.com/enrollmentserver/discovery.svc' -PropertyType String -Force | |
$joinedTenantKey | New-ItemProperty -Name 'MdmComplianceUrl' -Value 'https://portal.manage.microsoft.com/?portalAction=Compliance' -PropertyType String -Force |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
Name: Get-DomainMailSetup.ps1 | |
Author: James Schlackman | |
Last Modified: Sep 30 2024 | |
Retrieves an audit of MX, SPF, and DMARC records from public DNS for a given list of domains | |
#> | |
Param( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
Name: Update-VisualStudio.ps1 | |
Author: James Schlackman | |
Last Modified: August 23 2024 | |
Gets details of all current Visual Studio installs on this machine and attempts to run the updater for each installation found. | |
This script can be run using Task Scheduler or an RMM to periodicially check for and apply Visual Studio updates. | |
https://learn.microsoft.com/en-us/visualstudio/install/tools-for-managing-visual-studio-instances |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Name: Get-AzureStorageEncryptionDetails.ps1 | |
# Author: James Schlackman | |
# Last Modified: May 1 2024 | |
# | |
# Lists all storage accounts with their encryption settings. | |
#Requires -Modules Az.Accounts, Az.Storage | |
Param( | |
[Parameter()] [String] $AzTenant, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Name: Update-JiraUsersForSSO.ps1 | |
# Author: James Schlackman | |
# Last Modified: Apr 9 2024 | |
# Searches for and updates Jira users in preparation for SSO by changing their login name to match their email address. | |
#Requires -Modules JiraPS | |
Param( | |
# Jira server to connect to |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ | |
"type": "message", | |
"attachments": [ | |
{{ | |
"contentType": "application/vnd.microsoft.card.adaptive", | |
"contentUrl": null, | |
"content": {{ | |
"type": "AdaptiveCard", | |
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json", | |
"version": "1.4", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Name: Remove-ADUserAdmins.ps1 | |
# Author: James Schlackman | |
# Last Modified: Dec 19 2023 | |
# Clear individual non-local (e.g. AD) users from the local administrators group | |
# Notes: | |
# - Uses CIM to retrieve local group membership as Get-LocalGroupMember does not work without DC connectivity | |
# - Must be run in 64-bit PowerShell Host. The LocalAccounts module is not available in 32-bit PowerShell on a 64-bit system. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Name: Start-ExternalBackup.ps1 | |
# Author: James Schlackman | |
# Last Modified: Nov 11 2023 | |
# Runs an external backup executable, logs output, and sends email notifications. | |
Param( | |
# External backup executable | |
[Parameter()] [String] $BackupExe = "$env:ProgramFiles\FastGlacier\glacier-con.exe", | |
# Backup job arguments to pass to executable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Name: Get-EntraGuestDetails.ps1 | |
# Author: James Schlackman | |
# Last Modified: Oct 27 2023 | |
# | |
# Audits guest users in Entra ID, optionally filtered by start and/or end dates for when users were invited to the directory. | |
# | |
# Last sign in date for Entra requires an Entra ID Premium license. | |
#Requires -Modules Microsoft.Graph.Authentication, Microsoft.Graph.Groups, Microsoft.Graph.Users |
NewerOlder