Skip to main content

DNSSecStore

Struct DNSSecStore 

Source
pub struct DNSSecStore { /* private fields */ }
Expand description

DNSSEC-enabled DNS zone storage

DNSSecStore wraps a regular SqliteStore and adds DNSSEC capabilities, including key management and automatic zone signing. It provides the same storage interface as SqliteStore but returns DNSSEC-enabled zones.

Implementations§

Source§

impl DNSSecStore

Source

pub fn new(catalog: SqliteStore) -> Self

Create a new DNSSEC store from a regular SQLite store

Wraps an existing SqliteStore to provide DNSSEC functionality. The store starts with DNSSEC disabled and no keys configured.

§Arguments
  • catalog - The underlying SQLite store
§Returns

A new DNSSecStore instance

Source

pub fn add_zone_signing_key( &mut self, key: impl Into<Arc<DNSKey>>, ) -> Result<(), DnsSecZoneError>

Add a zone signing key to this store

Adds a DNSSEC key that will be used to sign all zones managed by this store. Multiple keys can be added for key rollover scenarios.

§Arguments
  • key - The DNSSEC key to add
§Returns

Success or an error if the key cannot be added

§Errors

Returns an error if the key is invalid or cannot be processed

Source

pub fn allow_update(&self) -> bool

Check if DNS updates are allowed

Returns whether this store allows DNS UPDATE operations.

§Returns

true if updates are allowed

Source

pub fn set_allow_update(&mut self, allow_update: bool) -> &mut Self

Set whether to allow DNS updates

Enables or disables DNS UPDATE operations for zones managed by this store.

§Arguments
  • allow_update - Whether to allow updates
§Returns

A mutable reference to this store for method chaining

Source

pub fn dnssec_enabled(&self) -> bool

Check if DNSSEC is enabled

Returns whether DNSSEC signing is enabled for zones managed by this store.

§Returns

true if DNSSEC is enabled

Source

pub fn set_dnssec_enabled(&mut self, dnssec_enabled: bool) -> &mut Self

Set whether to enable DNSSEC

Enables or disables DNSSEC signing for zones managed by this store. When enabled, zones will be automatically signed with configured keys.

§Arguments
  • dnssec_enabled - Whether to enable DNSSEC
§Returns

A mutable reference to this store for method chaining

Source

pub fn journal(&self) -> SqliteJournal

Get a journal for recording DNS operations

Returns a journal that can be used to record DNS operations for zones managed by this store.

§Returns

A SqliteJournal instance

Trait Implementations§

Source§

impl CatalogStore<DNSSecZone<Zone>> for DNSSecStore

Source§

fn find<'life0, 'life1, 'async_trait>( &'life0 self, origin: &'life1 LowerName, ) -> Pin<Box<dyn Future<Output = Result<Option<Vec<DNSSecZone<Zone>>>, CatalogError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Find zones by origin name Read more
Source§

fn upsert<'life0, 'life1, 'async_trait>( &'life0 self, name: LowerName, zones: &'life1 [DNSSecZone<Zone>], ) -> Pin<Box<dyn Future<Output = Result<(), CatalogError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Insert or update zones for a given name Read more
Source§

fn list<'life0, 'life1, 'async_trait>( &'life0 self, name: &'life1 LowerName, ) -> Pin<Box<dyn Future<Output = Result<Vec<Name>, CatalogError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

List all zone names in the catalog Read more
Source§

fn remove<'life0, 'life1, 'async_trait>( &'life0 self, name: &'life1 LowerName, ) -> Pin<Box<dyn Future<Output = Result<Option<Vec<DNSSecZone<Zone>>>, CatalogError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Remove a zone from the catalog Read more
Source§

impl Clone for DNSSecStore

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DNSSecStore

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more