Class CertificateAuthority.Builder

  • All Implemented Interfaces:
    com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, CertificateAuthorityOrBuilder, java.lang.Cloneable
    Enclosing class:
    CertificateAuthority

    public static final class CertificateAuthority.Builder
    extends com.google.protobuf.GeneratedMessage.Builder<CertificateAuthority.Builder>
    implements CertificateAuthorityOrBuilder
     CertificateAuthority enlists the information required to identify which
     CA to use and perform signature verification.
     
    Protobuf type dev.sigstore.trustroot.v1.CertificateAuthority
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<CertificateAuthority.Builder>
      • clear

        public CertificateAuthority.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessage.Builder<CertificateAuthority.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<CertificateAuthority.Builder>
      • getDefaultInstanceForType

        public CertificateAuthority getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public CertificateAuthority build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public CertificateAuthority buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessage.Builder<CertificateAuthority.Builder>
      • mergeFrom

        public CertificateAuthority.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                               throws java.io.IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<CertificateAuthority.Builder>
        Throws:
        java.io.IOException
      • hasSubject

        public boolean hasSubject()
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
        Specified by:
        hasSubject in interface CertificateAuthorityOrBuilder
        Returns:
        Whether the subject field is set.
      • getSubject

        public DistinguishedName getSubject()
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
        Specified by:
        getSubject in interface CertificateAuthorityOrBuilder
        Returns:
        The subject.
      • setSubject

        public CertificateAuthority.Builder setSubject​(DistinguishedName value)
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
      • mergeSubject

        public CertificateAuthority.Builder mergeSubject​(DistinguishedName value)
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
      • clearSubject

        public CertificateAuthority.Builder clearSubject()
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
      • getSubjectBuilder

        public DistinguishedName.Builder getSubjectBuilder()
         The root certificate MUST be self-signed, and so the subject and
         issuer are the same.
         
        .dev.sigstore.common.v1.DistinguishedName subject = 1;
      • getUri

        public java.lang.String getUri()
         The URI identifies the certificate authority.
        
         It is RECOMMENDED that the URI is the base URL for the certificate
         authority, that can be provided to any SDK/client provided
         by the certificate authority to interact with the certificate
         authority.
         
        string uri = 2;
        Specified by:
        getUri in interface CertificateAuthorityOrBuilder
        Returns:
        The uri.
      • getUriBytes

        public com.google.protobuf.ByteString getUriBytes()
         The URI identifies the certificate authority.
        
         It is RECOMMENDED that the URI is the base URL for the certificate
         authority, that can be provided to any SDK/client provided
         by the certificate authority to interact with the certificate
         authority.
         
        string uri = 2;
        Specified by:
        getUriBytes in interface CertificateAuthorityOrBuilder
        Returns:
        The bytes for uri.
      • setUri

        public CertificateAuthority.Builder setUri​(java.lang.String value)
         The URI identifies the certificate authority.
        
         It is RECOMMENDED that the URI is the base URL for the certificate
         authority, that can be provided to any SDK/client provided
         by the certificate authority to interact with the certificate
         authority.
         
        string uri = 2;
        Parameters:
        value - The uri to set.
        Returns:
        This builder for chaining.
      • clearUri

        public CertificateAuthority.Builder clearUri()
         The URI identifies the certificate authority.
        
         It is RECOMMENDED that the URI is the base URL for the certificate
         authority, that can be provided to any SDK/client provided
         by the certificate authority to interact with the certificate
         authority.
         
        string uri = 2;
        Returns:
        This builder for chaining.
      • setUriBytes

        public CertificateAuthority.Builder setUriBytes​(com.google.protobuf.ByteString value)
         The URI identifies the certificate authority.
        
         It is RECOMMENDED that the URI is the base URL for the certificate
         authority, that can be provided to any SDK/client provided
         by the certificate authority to interact with the certificate
         authority.
         
        string uri = 2;
        Parameters:
        value - The bytes for uri to set.
        Returns:
        This builder for chaining.
      • hasCertChain

        public boolean hasCertChain()
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
        Specified by:
        hasCertChain in interface CertificateAuthorityOrBuilder
        Returns:
        Whether the certChain field is set.
      • getCertChain

        public X509CertificateChain getCertChain()
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
        Specified by:
        getCertChain in interface CertificateAuthorityOrBuilder
        Returns:
        The certChain.
      • setCertChain

        public CertificateAuthority.Builder setCertChain​(X509CertificateChain value)
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
      • setCertChain

        public CertificateAuthority.Builder setCertChain​(X509CertificateChain.Builder builderForValue)
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
      • mergeCertChain

        public CertificateAuthority.Builder mergeCertChain​(X509CertificateChain value)
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
      • clearCertChain

        public CertificateAuthority.Builder clearCertChain()
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
      • getCertChainBuilder

        public X509CertificateChain.Builder getCertChainBuilder()
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
      • getCertChainOrBuilder

        public X509CertificateChainOrBuilder getCertChainOrBuilder()
         The certificate chain for this CA. The last certificate in the chain
         MUST be the trust anchor. The trust anchor MAY be a self-signed root
         CA certificate or MAY be an intermediate CA certificate.
         
        .dev.sigstore.common.v1.X509CertificateChain cert_chain = 3;
        Specified by:
        getCertChainOrBuilder in interface CertificateAuthorityOrBuilder
      • hasValidFor

        public boolean hasValidFor()
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
        Specified by:
        hasValidFor in interface CertificateAuthorityOrBuilder
        Returns:
        Whether the validFor field is set.
      • getValidFor

        public TimeRange getValidFor()
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
        Specified by:
        getValidFor in interface CertificateAuthorityOrBuilder
        Returns:
        The validFor.
      • setValidFor

        public CertificateAuthority.Builder setValidFor​(TimeRange value)
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
      • setValidFor

        public CertificateAuthority.Builder setValidFor​(TimeRange.Builder builderForValue)
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
      • mergeValidFor

        public CertificateAuthority.Builder mergeValidFor​(TimeRange value)
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
      • clearValidFor

        public CertificateAuthority.Builder clearValidFor()
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
      • getValidForBuilder

        public TimeRange.Builder getValidForBuilder()
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
      • getValidForOrBuilder

        public TimeRangeOrBuilder getValidForOrBuilder()
         The time the *entire* chain was valid. This is at max the
         longest interval when *all* certificates in the chain were valid,
         but it MAY be shorter. Clients MUST check timestamps against *both*
         the `valid_for` time range *and* the entire certificate chain.
        
         The TimeRange should be considered valid *inclusive* of the
         endpoints.
         
        .dev.sigstore.common.v1.TimeRange valid_for = 4;
        Specified by:
        getValidForOrBuilder in interface CertificateAuthorityOrBuilder