Add-DnsServerResourceRecordDnsKey
DNS Cmdlet: Add-DnsServerResourceRecordDnsKey
Syntax:
Add-DnsServerResourceRecordDnsKey [-Name] <String>[-CryptoAlgorithm] <String> [-ZoneName] <String>[-TimeToLive <TimeSpan>][-AgeRecord][-Base64Data] <String> [-KeyProtocol <String>][-ComputerName <String>][-SecureEntryPoint] [-ZoneKey][-PassThru][-ZoneScope <String>][-CimSession <CimSession[]>][-ThrottleLimit <Int32>][-AsJob][-WhatIf][-Confirm][<CommonParameters>]
Parameters and Description:
| Parameters | Description |
|---|---|
| CryptoAlgorithm (Type: String) | Specifies the cryptographic algorithm used by the server to generate keys. |
| TimeToLive (Type: TimeSpan) | Specifies the Time To Live (TTL) value in seconds for a given resource record. The other DNS servers use this time to find out how long to cache a record. |
| AgeRecord (Type: SwitchParameter) | Indicates that a time stamp is used by the DNS server for the resource record added by this cmdlet. |
| KeyProtocol (Type: String) | Represents the key protocol for this resource record. Dnssec is the only value for this parameter |
| SecureEntryPoint (Type: SwitchParameter) | Identifies whether a key is a secure entry point. |
| ComputerName (Type: String) | Enter the IP address, FQDN, NETBIOS name, or host name of the DNS server. |
| CimSession (Type: CimSession [] ) | Runs the cmdlet on a remote computer or session. By default, the cmdlet is run on the local computer in the current session. |
| ThrottleLimit (Type: Int32) | Specifies the number of maximum concurrent operations that can be allowed to run this cmdlet. If its value is 0 or not specified, PowerShell will calculate the right throttle limit automatically. |
For further information on Add-DnsServerResourceRecordDnsKey, please refer to this article.
Purpose of this cmdlet:
The Add-DnsServerResourceRecordDNSKEY cmdlet lets you add DNSKEY resource record to a DNS server. DNSKEY is a DNS Security Extensions element which stores a public key and is commonly used to add DNSKEY records to the TrustAnchors zone.
Example:
$DNSKEYS = Get-DnsServerResourceRecord -RRType DnsKey -ZoneName "abc.com" -ComputerName "dnsserver.abc.com"
$DNSKEYS | %{ $_.RecordData | Add-DnsServerResourceRecordDnsKey -ZoneName "TrustAnchors" -Name "abc.com" -ComputerName "dnsresolver.abc.com" }
The first command gets the DNSKEY resource record and stores it in the $DNSKEYS variable. The second command gets the DNSKEY resource record from $DSNKEYS and stores the resource record in the TrustAnchors zone on dnsresolver.abc.com server.
Did you know that, with ADManager Plus, you can:
- List computer objects that have been modified in the past 'n' days
- Generate a list of domain controllers of any given domain
- Fetch enabled/disabled/ inactive computers in the domain
Download the free 30-day trial to check out the product!
Active Directory Management and Reporting Solution
ADManager Plus is a web-based tool which offers the capability to manage Active Directory attributes in bulk easily using CSV files or templates. Get built-in reports on users and export them in CSV, PDF, HTML and XLSX formats.
Unravel end-to-end Active Directory management with ADManager Plus
-
- ADManager Plus Active Directory Management & Reporting
- ADAudit Plus Hybrid AD, cloud, and file auditing and security
- EventLog Analyzer Real-time Log Analysis & Reporting
- ADSelfService Plus Self-Service Password Management
- AD360 Integrated Identity & Access Management
- Log360 Comprehensive SIEM and UEBA
- AD Free Tools Active Directory FREE Tools
