|
| 1 | +# Infrastrukturhelden Script Collection |
| 2 | + |
| 3 | +PowerShell- und Infrastruktur-Hilfsskripte von Fabian Niesen. |
| 4 | + |
| 5 | +- Sprachversionen: [English](README.md) | [Deutsch](README.de.md) | [Español](README.es.md) | [Français](README.fr.md) |
| 6 | + |
| 7 | +> **Hinweis zur Übersetzung** |
| 8 | +> Die nicht-englischen README-Dateien wurden mit KI-Unterstützung erstellt, um die Nutzung zu erleichtern. Bei Unklarheiten gilt `README.md` als maßgebliche Version. |
| 9 | +
|
| 10 | +- Deutscher Blog: [https://www.infrastrukturhelden.de](https://www.infrastrukturhelden.de) |
| 11 | +- Englischer Blog: [https://www.infrastructureheroes.org/](https://www.infrastructureheroes.org/) |
| 12 | + |
| 13 | +> **Haftungsausschluss** |
| 14 | +> Dieses Repository und alle enthaltenen Skripte werden „wie besehen“ bereitgestellt – ohne ausdrückliche oder stillschweigende Gewährleistungen, einschließlich (aber nicht beschränkt auf) Marktgängigkeit, Eignung für einen bestimmten Zweck und Nichtverletzung von Rechten. |
| 15 | +> Sie sind allein dafür verantwortlich, jedes Skript vor der Nutzung zu prüfen, zu testen und zu validieren. Der Autor und Mitwirkende haften nicht für direkte, indirekte, zufällige, Folge- oder besondere Schäden, die aus der Nutzung oder Fehlanwendung dieser Skripte entstehen. |
| 16 | +
|
| 17 | +## Repository-Überblick |
| 18 | + |
| 19 | +Dieses Repository enthält Administrationsskripte für: |
| 20 | + |
| 21 | +- Active Directory- und Identitätsoperationen |
| 22 | +- BitLocker- und Endpunktverschlüsselung |
| 23 | +- Gruppenrichtlinien (GPO) |
| 24 | +- WSUS-Betrieb und Integritätsprüfungen |
| 25 | +- Intune-Paketierung und Fehleranalyse |
| 26 | +- Azure-Tooling-Setup |
| 27 | +- Netzwerkdiagnose und Clientkonfiguration |
| 28 | +- Exchange-Wartungsaufgaben |
| 29 | +- Benutzerlebenszyklus-Automatisierung |
| 30 | +- Windows-Härtung und Bereinigung |
| 31 | +- Linux/Squid-Allowlists für Enterprise-Proxy-Umgebungen |
| 32 | + |
| 33 | +## Inhaltsverzeichnis |
| 34 | + |
| 35 | +- [Repository-Überblick](#repository-überblick) |
| 36 | +- [Skriptübersicht (aus dem Repository gescannt)](#skriptübersicht-aus-dem-repository-gescannt) |
| 37 | + - [Hauptskripte](#hauptskripte) |
| 38 | + - [ActiveDirectory](#activedirectory) |
| 39 | + - [Azure](#azure) |
| 40 | + - [BitLocker](#bitlocker) |
| 41 | + - [Exchange](#exchange) |
| 42 | + - [GPO](#gpo) |
| 43 | + - [Intune](#intune) |
| 44 | + - [Linux-Files](#linux-files) |
| 45 | + - [Network](#network) |
| 46 | + - [User](#user) |
| 47 | + - [Windows](#windows) |
| 48 | + - [WSUS](#wsus) |
| 49 | +- [Zusätzliche Dateien](#zusätzliche-dateien) |
| 50 | +- [Notes](#notes) |
| 51 | + |
| 52 | + |
| 53 | +## Skriptübersicht (aus dem Repository gescannt) |
| 54 | + |
| 55 | +Die Beschreibungen basieren – sofern vorhanden – auf `.SYNOPSIS` / `.DESCRIPTION`; andernfalls wurden sie aus Skriptnamen und Inhalt abgeleitet. |
| 56 | + |
| 57 | +> **Hinweise zu Version/Lizenz** |
| 58 | +> - **Version**: wird in dieser Reihenfolge bestimmt: Variable `$ScriptVersion` im Skript, dann `$script:BuildVer`, dann `Version :` im Header, sonst `n/a`. |
| 59 | +> - **Lizenz**: wird aus der Header-Sektion `.NOTES` aus der Zeile `License :` gelesen; falls nicht vorhanden, `Not specified`. |
| 60 | +
|
| 61 | +### Hauptskripte |
| 62 | + |
| 63 | +| Datei | Zweck | Version | Lizenz | |
| 64 | +|---|---|---|---| |
| 65 | +| `Set-WinRelease.ps1` | Set registry keys to keep Windows 10 on a specific release. | 1.1 | The MIT License (MIT) | |
| 66 | +| `Get-WindowsSid.ps1` | Collect Windows SIDs from online AD computers via Sysinternals PSGetSid. | 1.2 | The MIT License (MIT) | |
| 67 | +| `install-greenshot.ps1` | Install the ZIP version of Greenshot and create Start Menu entries. | 1.1 | The MIT License (MIT) | |
| 68 | +| `Set-Network.ps1` | Apply common network settings (DNS domain, NetBIOS, IPv6). | 1.2 | The MIT License (MIT) | |
| 69 | +| `New-DokuwikiAnimal.ps1` | Create a DokuWiki "animal" structure with matching AD groups and shares. | 0.1 | The MIT License (MIT) | |
| 70 | +| `send-files.ps1` | Send files from a directory via email. | 1.3 | The MIT License (MIT) | |
| 71 | +| `generate-hosts.ps1` | Generate a hosts file based on Active Directory. | 1.1 | The MIT License (MIT) | |
| 72 | + |
| 73 | +### ActiveDirectory |
| 74 | + |
| 75 | +| Datei | Zweck | Version | Lizenz | |
| 76 | +|---|---|---|---| |
| 77 | +| `ActiveDirectory/Configure-AD.ps1` | Configure an AD domain (e.g., recycle bin, gMSA prep, central store, password policies, OU structure). | 0.2 | Not specified | |
| 78 | +| `ActiveDirectory/Get-ADPermissionsReport.ps1` | Export CSV report of Active Directory permissions. | 0.2 | Not specified | |
| 79 | +| `ActiveDirectory/Get-LAPSAuditReport.ps1` | Query security events for Microsoft LAPS-related audit activity. | n/a | Not specified | |
| 80 | +| `ActiveDirectory/Get-LocalNTLMlogs.ps1` | Analyze local `Microsoft-Windows-NTLM/Operational` events with classification. | 1.0 | GNU General Public License v3 (GPLv3) | |
| 81 | +| `ActiveDirectory/Get-NTLMLogons.ps1` | Analyze security logs for NTLM logons and authentication usage. | 1.3 | GNU General Public License v3 (GPLv3) | |
| 82 | +| `ActiveDirectory/Get-PKICertlist.ps1` | Enumerate certificates/templates from AD CS / PKI context. | n/a | Not specified | |
| 83 | +| `ActiveDirectory/Locate-46xx.ps1` | Locate AD lockout-related events (46xx security events). | 1.0 | Not specified | |
| 84 | +| `ActiveDirectory/Locate-ADLockout.ps1` | Locate user lockout sources in Active Directory. | 1.0 | Not specified | |
| 85 | +| `ActiveDirectory/Repair-DFSR.ps1` | Repair DFS-R replication (including SYSVOL) on domain controllers. | 0.1 | Not specified | |
| 86 | +| `ActiveDirectory/Reset-DSRM.ps1` | Reset DSRM password on a domain controller. | 0.3 | GNU General Public License v3 (GPLv3) | |
| 87 | +| `ActiveDirectory/execute-RemoteScriptWithLAPS.ps1` | Run remote scripts with local admin credentials managed by Microsoft LAPS. | 1.1 | Not specified | |
| 88 | +| `ActiveDirectory/get-CVE20201472Events.ps1` | Check domain controllers for Netlogon CVE-2020-1472-related event IDs (5827-5829). | 1.0 | Not specified | |
| 89 | +| `ActiveDirectory/get-adinfo.ps1` | Collect core AD forest/domain information and report details. | 0.5 | Not specified | |
| 90 | +| `ActiveDirectory/install-AD.ps1` | Install and bootstrap a new Active Directory domain. | 0.1 | Not specified | |
| 91 | +| `ActiveDirectory/install-DC.ps1` | Install/promote an additional domain controller. | 0.1 | Not specified | |
| 92 | +| `ActiveDirectory/move-FSMO.ps1` | Move FSMO roles to a new domain controller. | 0.1 | Not specified | |
| 93 | +| `ActiveDirectory/set-BSI-TR-02102-2.ps1` | Configure Windows cryptographic settings according to BSI TR-02102-2 (TLS/cipher hardening). | 0.2 | GNU General Public License v3 (GPLv3) | |
| 94 | + |
| 95 | +### Azure |
| 96 | + |
| 97 | +| Datei | Zweck | Version | Lizenz | |
| 98 | +|---|---|---|---| |
| 99 | +| `Azure/Install-AzCopy.ps1` | Download and install the latest AzCopy for the current user. | 1.0 | Not specified | |
| 100 | +| `Azure/Install-AzModule.ps1` | Install/update Azure PowerShell modules (`Az`). | n/a | Not specified | |
| 101 | + |
| 102 | +### BitLocker |
| 103 | + |
| 104 | +| Datei | Zweck | Version | Lizenz | |
| 105 | +|---|---|---|---| |
| 106 | +| `BitLocker/List-BitLockerrecoveryKeys.ps1` | List BitLocker recovery keys stored in Active Directory. | n/a | Not specified | |
| 107 | +| `BitLocker/Start-Bitlocker.ps1` | Start BitLocker encryption with predefined settings (including PIN workflows). | n/a | Not specified | |
| 108 | +| `BitLocker/Update-BitLockerRecovery.ps1` | Upload missing BitLocker recovery information to Active Directory. | 1.2 | The MIT License (MIT) | |
| 109 | + |
| 110 | +### Exchange |
| 111 | + |
| 112 | +| Datei | Zweck | Version | Lizenz | |
| 113 | +|---|---|---|---| |
| 114 | +| `Exchange/Set-MaintananceMode.ps1` | Put an Exchange 2013 DAG node into maintenance mode. | 0.2 | Not specified | |
| 115 | +| `Exchange/Set-Ex2013Vdir.ps1` | Configure Exchange 2013 virtual directories/URLs. | 0.1 | Not specified | |
| 116 | + |
| 117 | +### GPO |
| 118 | + |
| 119 | +| Datei | Zweck | Version | Lizenz | |
| 120 | +|---|---|---|---| |
| 121 | +| `GPO/Check-LocalGroupPolicy.ps1` | Detect and fix local Group Policy processing issues based on event logs. | 0.4 | The MIT License (MIT) | |
| 122 | +| `GPO/get-GPOBackup.ps1` | Create timestamped GPO backups including HTML reports. | 1.8 | The MIT License (MIT) | |
| 123 | +| `GPO/get-GPOreport.ps1` | Export/report GPO links and metadata for documentation. | n/a | Not specified | |
| 124 | +| `GPO/invoke-GPupdateDomain.ps1` | Trigger remote GPUpdate for computers in an OU (or wider scope). | 1.1 | The MIT License (MIT) | |
| 125 | + |
| 126 | +### Intune |
| 127 | + |
| 128 | +| Datei | Zweck | Version | Lizenz | |
| 129 | +|---|---|---|---| |
| 130 | +| `Intune/create-package.ps1` | Build `.intunewin` packages from source folders. | 1.0 | Not specified | |
| 131 | +| `Intune/get-AutopilotLogs.ps1` | Collect logs and diagnostics for Autopilot pre-provisioning. | 1.0.2 | Not specified | |
| 132 | + |
| 133 | +### Linux-Files |
| 134 | + |
| 135 | +| Datei | Zweck | Version | Lizenz | |
| 136 | +|---|---|---|---| |
| 137 | +| `Linux-Files/allow_windowsupdate.squid` | Squid ACL allowlist for Windows Update endpoints. | n/a | Not specified | |
| 138 | +| `Linux-Files/allow_psgallery.squid` | Squid ACL allowlist for PowerShell Gallery / NuGet endpoints. | n/a | Not specified | |
| 139 | +| `Linux-Files/allow_github.squid` | Squid ACL allowlist for GitHub endpoints. | n/a | Not specified | |
| 140 | +| `Linux-Files/allow_vscode.squid` | Squid ACL allowlist for Visual Studio Code endpoints. | n/a | Not specified | |
| 141 | + |
| 142 | +### Network |
| 143 | + |
| 144 | +| Datei | Zweck | Version | Lizenz | |
| 145 | +|---|---|---|---| |
| 146 | +| `Network/Check-Network.ps1` | Validate client network connectivity and configuration. | 0.6 | Except for the LDAP Test Code, witch is licensed by Evotec under MIT License | |
| 147 | +| `Network/disable-NetBios.ps1` | Disable NetBIOS over TCP/IP on active adapters. | n/a | Not specified | |
| 148 | + |
| 149 | +### User |
| 150 | + |
| 151 | +| Datei | Zweck | Version | Lizenz | |
| 152 | +|---|---|---|---| |
| 153 | +| `User/create-user.ps1` | Create AD users (including Microsoft 365 onboarding patterns). | 0.3 | The MIT License (MIT) | |
| 154 | +| `User/Get-LastLogonOU.ps1` | Report last logon values for users in an OU (AD + Exchange context). | 0.2 FN 03.12.2025 Changed License to MIT, housekeeping Header | The MIT License (MIT) | |
| 155 | + |
| 156 | +### Windows |
| 157 | + |
| 158 | +| Datei | Zweck | Version | Lizenz | |
| 159 | +|---|---|---|---| |
| 160 | +| `Windows/set-cert4rdp.ps1` | Bind/set the RDP certificate from a specific issuing CA. | 0.2 | The MIT License (MIT) | |
| 161 | +| `Windows/Remove-AzureArc.ps1` | Remove Azure Arc agent/components and reboot automatically if required. | 1.1 | The MIT License (MIT) | |
| 162 | + |
| 163 | +### WSUS |
| 164 | + |
| 165 | +| Datei | Zweck | Version | Lizenz | |
| 166 | +|---|---|---|---| |
| 167 | +| `WSUS/decline-WSUSUpdatesTypes.ps1` | Decline selected update classifications/products in WSUS. | 1.8 | The MIT License (MIT) | |
| 168 | +| `WSUS/Reset-WSUSClient.cmd` | Reset WSUS client configuration and detection state. | n/a | Not specified | |
| 169 | +| `WSUS/start-WsusServerSync.ps1` | Start WSUS synchronization (supports recursive upstream/downstream and email logging). | n/a | Not specified | |
| 170 | +| `WSUS/Get-WsusHealth.ps1` | Run comprehensive WSUS health checks and generate diagnostic output. | 1.3 | Except for the LDAP Test Code, witch is licensed by Evotec under MIT License | |
| 171 | + |
| 172 | +## Zusätzliche Dateien |
| 173 | + |
| 174 | +- `Intune/Readme.md` – Intune-spezifische Hinweise (auf Deutsch). |
| 175 | +- `Dokumente/Zertifizierungsstellen mit Windows Server 2012R2.pdf` – PKI/CA documentation PDF. |
| 176 | + |
| 177 | +## Hinweise |
| 178 | + |
| 179 | +- Einige Skripte sind ausgereift und versioniert. |
| 180 | +- Andere sind schnelle operative Helfer für den Administrationsalltag. |
| 181 | +- Skripte vor dem produktiven Einsatz immer in einer Testumgebung prüfen. |
0 commit comments