# Certificate Authority Service V1beta1 API - Class Google::Cloud::Security::PrivateCA::V1beta1::CertificateDescription::SubjectDescription (v0.18.0)

0.18.0 (latest) 0.17.1 0.16.0 0.15.1 0.14.0 0.13.0 0.12.1 0.11.0 0.10.0 0.9.1 0.8.2 0.7.0 0.6.1 0.5.0 0.4.0 0.3.6 Reference documentation and code samples for the Certificate Authority Service V1beta1 API class Google::Cloud::Security::PrivateCA::V1beta1::CertificateDescription::SubjectDescription.

These values describe fields in an issued X.509 certificate such as the
distinguished name, subject alternative names, serial number, and lifetime.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #common_name

    def common_name() -> ::String

**Returns**

- (::String) --- The "common name" of the distinguished name.

### #common_name=

    def common_name=(value) -> ::String

**Parameter**

- **value** (::String) --- The "common name" of the distinguished name.
**Returns**

- (::String) --- The "common name" of the distinguished name.

### #hex_serial_number

    def hex_serial_number() -> ::String

**Returns**

- (::String) --- The serial number encoded in lowercase hexadecimal.

### #hex_serial_number=

    def hex_serial_number=(value) -> ::String

**Parameter**

- **value** (::String) --- The serial number encoded in lowercase hexadecimal.
**Returns**

- (::String) --- The serial number encoded in lowercase hexadecimal.

### #lifetime

    def lifetime() -> ::Google::Protobuf::Duration

**Returns**

- ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Duration)) --- For convenience, the actual lifetime of an issued certificate. Corresponds to 'not_after_time' - 'not_before_time'.

### #lifetime=

    def lifetime=(value) -> ::Google::Protobuf::Duration

**Parameter**

- **value** ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Duration)) --- For convenience, the actual lifetime of an issued certificate. Corresponds to 'not_after_time' - 'not_before_time'.
**Returns**

- ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Duration)) --- For convenience, the actual lifetime of an issued certificate. Corresponds to 'not_after_time' - 'not_before_time'.

### #not_after_time

    def not_after_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate expires.

### #not_after_time=

    def not_after_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate expires.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate expires.

### #not_before_time

    def not_before_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate becomes valid.

### #not_before_time=

    def not_before_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate becomes valid.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Protobuf-Timestamp)) --- The time at which the certificate becomes valid.

### #subject

    def subject() -> ::Google::Cloud::Security::PrivateCA::V1beta1::Subject

**Returns**

- ([::Google::Cloud::Security::PrivateCA::V1beta1::Subject](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-Subject)) --- Contains distinguished name fields such as the location and organization.

### #subject=

    def subject=(value) -> ::Google::Cloud::Security::PrivateCA::V1beta1::Subject

**Parameter**

- **value** ([::Google::Cloud::Security::PrivateCA::V1beta1::Subject](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-Subject)) --- Contains distinguished name fields such as the location and organization.
**Returns**

- ([::Google::Cloud::Security::PrivateCA::V1beta1::Subject](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-Subject)) --- Contains distinguished name fields such as the location and organization.

### #subject_alt_name

    def subject_alt_name() -> ::Google::Cloud::Security::PrivateCA::V1beta1::SubjectAltNames

**Returns**

- ([::Google::Cloud::Security::PrivateCA::V1beta1::SubjectAltNames](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-SubjectAltNames)) --- The subject alternative name fields.

### #subject_alt_name=

    def subject_alt_name=(value) -> ::Google::Cloud::Security::PrivateCA::V1beta1::SubjectAltNames

**Parameter**

- **value** ([::Google::Cloud::Security::PrivateCA::V1beta1::SubjectAltNames](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-SubjectAltNames)) --- The subject alternative name fields.
**Returns**

- ([::Google::Cloud::Security::PrivateCA::V1beta1::SubjectAltNames](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-security-private_ca-v1beta1/latest/Google-Cloud-Security-PrivateCA-V1beta1-SubjectAltNames)) --- The subject alternative name fields.