corda / net.corda.core.crypto / X509Utilities / createSelfSignedCACert

# createSelfSignedCACert

`fun createSelfSignedCACert(myLegalName: String): CACertAndKey`

Create a de novo root self-signed X509 v3 CA cert and KeyPair.

### Parameters

`domain` - The Common (CN) field of the cert Subject will be populated with the domain string

Return
A data class is returned containing the new root CA Cert and its KeyPair for signing downstream certificates. Note the generated certificate tree is capped at max depth of 2 to be in line with commercially available certificates