Skip to content

Add support to export Cert as Base64 with CredentialExport #267

@ghost

Description

Problem description

I would like to have the ability to export a credential with DSC in base64 format. I can do this with the GUI on windows cert store but not with the DSC code.

Thanks

image

Verbose logs

No logs

DSC configuration

#This produces a cert in the DER encoding.  I would like the option for Base64
CertificateExport RootCertPem {
      Type         = 'CERT'
      FriendlyName = 'Root CA'
      Subject      = '%DN%'
      Path         = "C:\rootCert.cer"
    }

Suggested solution

N/A

Operating system the target node is running

OsName               : Microsoft Windows Server 2019 Datacenter
OsOperatingSystemSKU : DatacenterServerEdition
OsArchitecture       : 64-bit
WindowsVersion       : 1809
WindowsBuildLabEx    : 17763.1.amd64fre.rs5_release.180914-1434
OsLanguage           : en-US
OsMuiLanguages       : {en-US}

PowerShell version and build the target node is running

Name                           Value
----                           -----
PSVersion                      5.1.17763.2867
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.17763.2867
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

CertificateDsc version

Name           Version Path
----           ------- ----
CertificateDsc 5.1.0   C:\Program Files\WindowsPowerShell\Modules\CertificateDsc\5.1.0\CertificateDsc.psd1

Metadata

Metadata

Assignees

Labels

enhancementThe issue is an enhancement request.in progressThe issue is being actively worked on by someone.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions