I have a third-party issued certificate that I need to ensure is running on all targets in a given domain. Is there a way to ensure this certificate is installed by way of DSC?
There is currently no built-in way to do this in DSC. I wrote a custom resource for my organization that installs a certificate from a PFX. I used the
Import-PfxCertificate cmdlet and secured credentials in DSC (for the PFX password).
This is now live in Microsoft's resources! The
xPfxImport resource is in the
xCertificate module v1.1 (and later presumably).
Thanks again for the encouragement (especially jscott).
How about using group policy to deploy the certificate to the domain? http://technet.microsoft.com/en-us/library/cc770315%28v=ws.10%29.aspx
To deploy a certificate by using Group Policy
Open Group Policy Management Console. Find an existing or create a new GPO to contain the certificate settings. Ensure that the GPO is associated with the domain, site, or organizational unit whose users you want affected by the policy. Right-click the GPO, and then select Edit. Group Policy Management Editor opens, and displays the current contents of the policy object. In the navigation pane, open Computer Configuration\Windows Settings\Security Settings\Public Key Policies\Trusted Publishers. Click the Action menu, and then click Import. Follow the instructions in the Certificate Import Wizard to find and import the certificate. If the certificate is self-signed, and cannot be traced back to a certificate that is in the Trusted Root Certification Authorities certificate store, then you must also copy the certificate to that store. In the navigation pane, click Trusted Root Certification Authorities, and then repeat steps 5 and 6 to install a copy of the certificate to that store.