1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>Information about a delegation signer (DS) record that was created in the registry by <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_domains_AssociateDelegationSignerToDomain.html">AssociateDelegationSignerToDomain</a>.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DnssecSigningAttributes {
/// <p>Algorithm which was used to generate the digest from the public key.</p>
pub algorithm: ::std::option::Option<i32>,
/// <p>Defines the type of key. It can be either a KSK (key-signing-key, value 257) or ZSK (zone-signing-key, value 256). Using KSK is always encouraged. Only use ZSK if your DNS provider isn't Route 53 and you don’t have KSK available.</p>
/// <p>If you have KSK and ZSK keys, always use KSK to create a delegations signer (DS) record. If you have ZSK keys only – use ZSK to create a DS record.</p>
pub flags: ::std::option::Option<i32>,
/// <p>The base64-encoded public key part of the key pair that is passed to the registry.</p>
pub public_key: ::std::option::Option<::std::string::String>,
}
impl DnssecSigningAttributes {
/// <p>Algorithm which was used to generate the digest from the public key.</p>
pub fn algorithm(&self) -> ::std::option::Option<i32> {
self.algorithm
}
/// <p>Defines the type of key. It can be either a KSK (key-signing-key, value 257) or ZSK (zone-signing-key, value 256). Using KSK is always encouraged. Only use ZSK if your DNS provider isn't Route 53 and you don’t have KSK available.</p>
/// <p>If you have KSK and ZSK keys, always use KSK to create a delegations signer (DS) record. If you have ZSK keys only – use ZSK to create a DS record.</p>
pub fn flags(&self) -> ::std::option::Option<i32> {
self.flags
}
/// <p>The base64-encoded public key part of the key pair that is passed to the registry.</p>
pub fn public_key(&self) -> ::std::option::Option<&str> {
self.public_key.as_deref()
}
}
impl DnssecSigningAttributes {
/// Creates a new builder-style object to manufacture [`DnssecSigningAttributes`](crate::types::DnssecSigningAttributes).
pub fn builder() -> crate::types::builders::DnssecSigningAttributesBuilder {
crate::types::builders::DnssecSigningAttributesBuilder::default()
}
}
/// A builder for [`DnssecSigningAttributes`](crate::types::DnssecSigningAttributes).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct DnssecSigningAttributesBuilder {
pub(crate) algorithm: ::std::option::Option<i32>,
pub(crate) flags: ::std::option::Option<i32>,
pub(crate) public_key: ::std::option::Option<::std::string::String>,
}
impl DnssecSigningAttributesBuilder {
/// <p>Algorithm which was used to generate the digest from the public key.</p>
pub fn algorithm(mut self, input: i32) -> Self {
self.algorithm = ::std::option::Option::Some(input);
self
}
/// <p>Algorithm which was used to generate the digest from the public key.</p>
pub fn set_algorithm(mut self, input: ::std::option::Option<i32>) -> Self {
self.algorithm = input;
self
}
/// <p>Algorithm which was used to generate the digest from the public key.</p>
pub fn get_algorithm(&self) -> &::std::option::Option<i32> {
&self.algorithm
}
/// <p>Defines the type of key. It can be either a KSK (key-signing-key, value 257) or ZSK (zone-signing-key, value 256). Using KSK is always encouraged. Only use ZSK if your DNS provider isn't Route 53 and you don’t have KSK available.</p>
/// <p>If you have KSK and ZSK keys, always use KSK to create a delegations signer (DS) record. If you have ZSK keys only – use ZSK to create a DS record.</p>
pub fn flags(mut self, input: i32) -> Self {
self.flags = ::std::option::Option::Some(input);
self
}
/// <p>Defines the type of key. It can be either a KSK (key-signing-key, value 257) or ZSK (zone-signing-key, value 256). Using KSK is always encouraged. Only use ZSK if your DNS provider isn't Route 53 and you don’t have KSK available.</p>
/// <p>If you have KSK and ZSK keys, always use KSK to create a delegations signer (DS) record. If you have ZSK keys only – use ZSK to create a DS record.</p>
pub fn set_flags(mut self, input: ::std::option::Option<i32>) -> Self {
self.flags = input;
self
}
/// <p>Defines the type of key. It can be either a KSK (key-signing-key, value 257) or ZSK (zone-signing-key, value 256). Using KSK is always encouraged. Only use ZSK if your DNS provider isn't Route 53 and you don’t have KSK available.</p>
/// <p>If you have KSK and ZSK keys, always use KSK to create a delegations signer (DS) record. If you have ZSK keys only – use ZSK to create a DS record.</p>
pub fn get_flags(&self) -> &::std::option::Option<i32> {
&self.flags
}
/// <p>The base64-encoded public key part of the key pair that is passed to the registry.</p>
pub fn public_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.public_key = ::std::option::Option::Some(input.into());
self
}
/// <p>The base64-encoded public key part of the key pair that is passed to the registry.</p>
pub fn set_public_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.public_key = input;
self
}
/// <p>The base64-encoded public key part of the key pair that is passed to the registry.</p>
pub fn get_public_key(&self) -> &::std::option::Option<::std::string::String> {
&self.public_key
}
/// Consumes the builder and constructs a [`DnssecSigningAttributes`](crate::types::DnssecSigningAttributes).
pub fn build(self) -> crate::types::DnssecSigningAttributes {
crate::types::DnssecSigningAttributes {
algorithm: self.algorithm,
flags: self.flags,
public_key: self.public_key,
}
}
}