Class CertificatePolicy
- java.lang.Object
-
- com.azure.security.keyvault.certificates.models.CertificatePolicy
-
public final class CertificatePolicy extends Object
The Certificate Management policy for thecertificate.
-
-
Constructor Summary
Constructors Constructor Description CertificatePolicy(String issuerName, SubjectAlternativeNames subjectAlternativeNames)Creates certificate policy.CertificatePolicy(String issuerName, String subject)Creates certificate policy.CertificatePolicy(String issuerName, String subject, SubjectAlternativeNames subjectAlternativeNames)Creates certificate policy.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetCertificateType()Get the certificate type.CertificateContentTypegetContentType()Get the content type.OffsetDateTimegetCreatedOn()Get the the UTC time at which certificate policy was created.static CertificatePolicygetDefault()Get the default certificate policy.List<String>getEnhancedKeyUsage()Get the enhanced key usage.StringgetIssuerName()Get the issuer name.CertificateKeyCurveNamegetKeyCurveName()Get the key curve.IntegergetKeySize()Get the key size.CertificateKeyTypegetKeyType()Get the key type.List<CertificateKeyUsage>getKeyUsage()Get the key usage.List<LifetimeAction>getLifetimeActions()Get the lifetime actionsStringgetSubject()Get the subject.SubjectAlternativeNamesgetSubjectAlternativeNames()Get the subjectAlternativeNames.OffsetDateTimegetUpdatedOn()Get the UTC time at which certificate policy was last updated.IntegergetValidityInMonths()Get the validity in months.BooleanisCertificateTransparent()Get the certificate transparency status.BooleanisEnabled()Get the enabled status.BooleanisExportable()Get the exportable.BooleanisKeyReusable()Get the key reuse status.CertificatePolicysetCertificateTransparent(Boolean certificateTransparent)Set the certificate transparency status.CertificatePolicysetCertificateType(String certificateType)Set the certificate type to request from the issuer.CertificatePolicysetContentType(CertificateContentType contentType)Set the content type.CertificatePolicysetEnabled(Boolean enabled)Set the enabled status.CertificatePolicysetEnhancedKeyUsage(List<String> ekus)Set the enhanced key usage.CertificatePolicysetExportable(Boolean exportable)Set the exportable value.CertificatePolicysetKeyCurveName(CertificateKeyCurveName keyCurveName)Set the key curve.CertificatePolicysetKeyReusable(Boolean keyReusable)Set the reuse key value.CertificatePolicysetKeySize(Integer keySize)Set the key size.CertificatePolicysetKeyType(CertificateKeyType keyType)Get the key type.CertificatePolicysetKeyUsage(CertificateKeyUsage... keyUsage)Set the key usage.CertificatePolicysetLifetimeActions(LifetimeAction... actions)Set the lifetime actionsCertificatePolicysetSubject(String subject)Set the subject Name.CertificatePolicysetSubjectAlternativeNames(SubjectAlternativeNames subjectAlternativeNames)Set the subjectAlternativeNames.CertificatePolicysetValidityInMonths(Integer validityInMonths)Set the validity in months.
-
-
-
Constructor Detail
-
CertificatePolicy
public CertificatePolicy(String issuerName, String subject)
Creates certificate policy.- Parameters:
issuerName- The issuer name to set.subject- The subject name to set.
-
CertificatePolicy
public CertificatePolicy(String issuerName, SubjectAlternativeNames subjectAlternativeNames)
Creates certificate policy.- Parameters:
issuerName- The issuer name to set.subjectAlternativeNames- The subject alternative names to set.
-
CertificatePolicy
public CertificatePolicy(String issuerName, String subject, SubjectAlternativeNames subjectAlternativeNames)
Creates certificate policy.- Parameters:
issuerName- The issuer name to set.subject- The subject name to set.subjectAlternativeNames- The subject alternative names to set.
-
-
Method Detail
-
getKeyUsage
public List<CertificateKeyUsage> getKeyUsage()
Get the key usage.- Returns:
- the key usage
-
setKeyUsage
public CertificatePolicy setKeyUsage(CertificateKeyUsage... keyUsage)
Set the key usage.- Parameters:
keyUsage- the key usage value to set- Returns:
- the updated CertificatePolicy object itself.
-
getEnhancedKeyUsage
public List<String> getEnhancedKeyUsage()
Get the enhanced key usage.- Returns:
- the enhanced key usage
-
setEnhancedKeyUsage
public CertificatePolicy setEnhancedKeyUsage(List<String> ekus)
Set the enhanced key usage.- Parameters:
ekus- the ekus value to set- Returns:
- the updated CertificatePolicy object itself.
-
isExportable
public Boolean isExportable()
Get the exportable.- Returns:
- the exportable value
-
setExportable
public CertificatePolicy setExportable(Boolean exportable)
Set the exportable value.- Parameters:
exportable- the exportable value to set- Returns:
- the updated CertificatePolicy object itself.
-
getKeyType
public CertificateKeyType getKeyType()
Get the key type.- Returns:
- the key type value
-
setKeyType
public CertificatePolicy setKeyType(CertificateKeyType keyType)
Get the key type.- Parameters:
keyType- the key type- Returns:
- the key type
-
getKeySize
public Integer getKeySize()
Get the key size.- Returns:
- the key size
-
isKeyReusable
public Boolean isKeyReusable()
Get the key reuse status.- Returns:
- the key reuse status
-
setKeyReusable
public CertificatePolicy setKeyReusable(Boolean keyReusable)
Set the reuse key value.- Parameters:
keyReusable- the reuseKey value to set- Returns:
- the updated CertificatePolicy object itself.
-
getKeyCurveName
public CertificateKeyCurveName getKeyCurveName()
Get the key curve.- Returns:
- the curve value
-
getCreatedOn
public OffsetDateTime getCreatedOn()
Get the the UTC time at which certificate policy was created.- Returns:
- the created UTC time.
-
getUpdatedOn
public OffsetDateTime getUpdatedOn()
Get the UTC time at which certificate policy was last updated.- Returns:
- the last updated UTC time.
-
isEnabled
public Boolean isEnabled()
Get the enabled status.- Returns:
- the enabled status
-
setEnabled
public CertificatePolicy setEnabled(Boolean enabled)
Set the enabled status.- Parameters:
enabled- The enabled status to set.- Returns:
- the updated CertificatePolicy object itself.
-
getContentType
public CertificateContentType getContentType()
Get the content type.- Returns:
- the content type
-
setContentType
public CertificatePolicy setContentType(CertificateContentType contentType)
Set the content type.- Parameters:
contentType- the content type value to set- Returns:
- the updated CertificatePolicy object itself.
-
getSubjectAlternativeNames
public SubjectAlternativeNames getSubjectAlternativeNames()
Get the subjectAlternativeNames.- Returns:
- the subjectAlternativeNames.
-
setSubjectAlternativeNames
public CertificatePolicy setSubjectAlternativeNames(SubjectAlternativeNames subjectAlternativeNames)
Set the subjectAlternativeNames.- Parameters:
subjectAlternativeNames- the subjectAlternativeNames to set- Returns:
- the updated CertificatePolicy object itself.
-
setSubject
public CertificatePolicy setSubject(String subject)
Set the subject Name.- Parameters:
subject- the subject Name to set- Returns:
- the updated CertificatePolicy object itself.
-
setValidityInMonths
public CertificatePolicy setValidityInMonths(Integer validityInMonths)
Set the validity in months.- Parameters:
validityInMonths- the validityInMonths value to set- Returns:
- the updated CertificatePolicy object itself.
-
setKeySize
public CertificatePolicy setKeySize(Integer keySize)
Set the key size.- Parameters:
keySize- the key size value to set- Returns:
- the updated CertificatePolicy object itself.
-
setKeyCurveName
public CertificatePolicy setKeyCurveName(CertificateKeyCurveName keyCurveName)
Set the key curve.- Parameters:
keyCurveName- the key curve value to set- Returns:
- the updated CertificatePolicy object itself.
-
setCertificateType
public CertificatePolicy setCertificateType(String certificateType)
Set the certificate type to request from the issuer.- Parameters:
certificateType- the certificateType to request from issuer.- Returns:
- the updated CertificatePolicy object itself.
-
setCertificateTransparent
public CertificatePolicy setCertificateTransparent(Boolean certificateTransparent)
Set the certificate transparency status.- Parameters:
certificateTransparent- the certificateTransparency status to set- Returns:
- the updated CertificatePolicy object itself.
-
getSubject
public String getSubject()
Get the subject.- Returns:
- the subject
-
getValidityInMonths
public Integer getValidityInMonths()
Get the validity in months.- Returns:
- the validity in months
-
getIssuerName
public String getIssuerName()
Get the issuer name.- Returns:
- the issuer name.
-
getCertificateType
public String getCertificateType()
Get the certificate type.- Returns:
- the certificate type
-
isCertificateTransparent
public Boolean isCertificateTransparent()
Get the certificate transparency status.- Returns:
- the certificate transparency status
-
setLifetimeActions
public CertificatePolicy setLifetimeActions(LifetimeAction... actions)
Set the lifetime actions- Parameters:
actions- the lifetime actions to set.- Returns:
- the updated certificate policy object itself.
-
getLifetimeActions
public List<LifetimeAction> getLifetimeActions()
Get the lifetime actions- Returns:
- the lifetime actions
-
getDefault
public static CertificatePolicy getDefault()
Get the default certificate policy.- Returns:
- the default certificate policy.
-
-