The New-RdpSpnAuditPlan command is used to identify potential issues with Remote Desktop Services (RDS) SPNs in Active Directory. This command helps organizations ensure that their RDS infrastructure is properly configured and compliant with security best practices.
Key stakeholders who use this command include:
- IT administrators responsible for RDS deployments
- Security teams tasked with ensuring compliance with organization-wide security policies
Potential risks associated with misconfigured RDS SPNs include:
- Compromised security posture due to weak or missing credentials
- Inability to troubleshoot issues related to RDS connectivity and performance
Managers typically care about the output of this command when it indicates potential security vulnerabilities or compliance issues that require immediate attention.
To use New-RdpSpnAuditPlan, follow these steps:
- Ensure you have a valid connection to Active Directory using the
Connect-ADcmdlet. - Run
Get-RdpSpnCandidateto retrieve the expected set of TERMSRV SPNs for your organization. - Use
New-RdpSpnAuditPlanwith the output from step 2 as input, specifying any additional parameters as needed (e.g.,-ComputerName,-Credential).
Example code:
$expectedSPNs = Get-RdpSpnCandidate -Verbose
$result = New-RdpSpnAuditPlan -Candidate $expectedSPNs
$result | Export-Csv -Path "C:\AuditResults.csv" -NoTypeInformationWatchpoints:
- Verify that your AD connection is established and functioning correctly before running the command.
- Use caution when modifying or deleting existing SPNs, as this can impact RDS connectivity.
New-RdpSpnAuditPlan is a PowerShell cmdlet used to compare actual TERMSRV SPNs in Active Directory against expected values. This helps ensure that RDS services are properly configured and secure.
To use this command:
- Get the list of expected TERMSRV SPNs using
Get-RdpSpnCandidate. - Compare these expected values against the actual SPNs in AD.
- Identify any missing or orphaned SPNs, which may indicate security vulnerabilities.
If you’re stuck, try:
- Verifying your AD connection and configuration
- Reviewing the command’s output to understand potential issues
| Field | Value |
|---|---|
| Vendor | Detent Point LLC |
| Product | SpnManager 0.4.0 |
| Licence | Proprietary - licensed, not sold. See LICENSE. |
| Operational impact | Read-only. Queries Active Directory and reports findings; changes nothing. |
| Rights required | Directory read access. Some providers additionally need rights to read delegation and encryption-type attributes. |
| Providers covered | AD.RDP |
| Approval recommendation | Approve for general operational use. It cannot alter directory state. |
Licence terms are proprietary and are supplied with the purchase, subscription or evaluation agreement. No open-source licence is granted.
| What | Why |
|---|---|
| Windows PowerShell 5.1 or later | Declared by the module manifest. |
| ActiveDirectory 1.0.0.0 | Required module. Ships with RSAT; install the Active Directory PowerShell feature. |
| A reachable domain controller | Every provider reads from Active Directory. |
| An account with directory read access | Needed to enumerate accounts and their SPNs. |
The New-RdpSpnAuditPlan command adheres to standard data-handling best practices, including:
- Secure transit: Data is transmitted securely using established AD connections.
- At-rest security: SPN data is stored securely in Active Directory.
- Audit trail: Command output provides a clear audit trail of potential issues.
Compliance requirements for this command include adherence to organization-wide security policies and regulations related to RDS deployments.
This is the plan step. It turns a candidate into a plan showing what is missing; nothing is changed. Its output is normally piped into Test-SpnAuditPlan. Providers: AD.RDP.
Example 1
Get-RdpSpnCandidate -TargetComputer 'srv01' | New-RdpSpnAuditPlanAlso uses: Get-RdpSpnCandidate (Sense).
Example 2
New-RdpSpnAuditPlan -Candidate $candidateExample 3
Get-RdpSpnCandidate -TargetComputer 'srv01' | New-RdpSpnAuditPlan | Test-SpnAuditPlanAlso uses: Get-RdpSpnCandidate (Sense), Test-SpnAuditPlan (Test).