noid-privacy/Modules/DNS/DNS.psm1
NexusOne23 da9f937ee8 release: v2.2.3 - Fix Restore Mode module selection crash
CHANGELOG:
- Fixed: Restore Mode manual module selection crash (Critical)
- Root cause: .Split(',', ';', ' ') triggered wrong .NET overload
- Fix: Replaced with native PowerShell -split '[,; ]' operator
- Reported by: KatCat2

VERSION BUMP: 2.2.2 -> 2.2.3
- Updated 48 files with new version number
- CHANGELOG.md: Added v2.2.3 release notes
- README.md: Updated badge, module table, project status
2026-01-07 18:46:14 +01:00

43 lines
1.2 KiB
PowerShell

#Requires -Version 5.1
#Requires -RunAsAdministrator
<#
.SYNOPSIS
DNS Configuration Module for NoID Privacy
.DESCRIPTION
Provides secure DNS configuration with DNS over HTTPS (DoH) support.
Supports Cloudflare, Quad9, and AdGuard DNS providers with automatic
backup and restore capabilities.
.NOTES
Author: NoID Privacy
Version: 2.2.3
Requires: PowerShell 5.1+, Administrator privileges
#>
# Module-level variables
$script:ModuleName = "DNS"
$script:ModuleRoot = $PSScriptRoot
$PrivatePath = "$PSScriptRoot\Private"
# Get module functions
$Private = @(Get-ChildItem -Path $PrivatePath -Filter "*.ps1" -ErrorAction SilentlyContinue)
$Public = @(Get-ChildItem -Path "$PSScriptRoot\Public" -Filter "*.ps1" -ErrorAction SilentlyContinue)
# Dot source the functions
foreach ($import in @($Private + $Public)) {
try {
. $import.FullName
}
catch {
Write-Host "ERROR: Failed to import function $($import.FullName): $_" -ForegroundColor Red
}
}
# Export public functions
Export-ModuleMember -Function $Public.BaseName
# Alias for naming consistency (non-breaking change)
New-Alias -Name 'Invoke-DNS' -Value 'Invoke-DNSConfiguration' -Force
Export-ModuleMember -Alias 'Invoke-DNS'