An open API service indexing awesome lists of open source software.

https://github.com/centralnicgroup-opensource/net-dns-abstract

Net::DNS interface to several DNS backends via API
https://github.com/centralnicgroup-opensource/net-dns-abstract

Last synced: 4 months ago
JSON representation

Net::DNS interface to several DNS backends via API

Awesome Lists containing this project

README

        

=pod

=encoding UTF-8

=head1 NAME

Net::DNS::Abstract - Net::DNS interface to several DNS backends via API

=head1 VERSION

version 3.3

=head1 SYNOPSIS

Net::DNS is the de-facto standard and battle tested perl DNS
implementation. Unfortunately we don't intercat with DNS via DNS
protocols but via 3rd party abstration layers that have all sorts of
quirks. We try to provide one unified interface here.

=head1 ATTRIBUTES

=head2 debug

=head2 domain

the domain as a punycode string of the underlaying zone (required)

=head2 zone

the Net::DNS::Packet object of the underlaying zone including a subtype
to convert between formats to Net::DNS

=head2 interface

defines the interface plugin to load (required)

=head1 SUBROUTINES/METHODS

=head2 axfr

Do a zone transfer (actually poll a zone from a 3rd party provider) and
return a Net::DNS::Packet objects.

axfr(['ns1.provider.net'])

=head2 update

Update a DNS zone via the respective backend plugin. This function takes
a Net::DNS update object and pushes it through to the backend plugin to
process it.

=head2 create

Create a new zone in a DNS backend

=head2 delete

Delete a zone from a DNS backend

=head2 to_string

Converts a Net::DNS object into a flat zonefile without comments and
empty lines. This is an alternative to calling $nda->string

This function returns a zonefile string

=head2 string_eq

Overloading endpoint for string comparison of two Net::DNS::Abstract
objects

This function returns a zonefile string

=head2 to_hash

Convert a Net::DNS object into our normalized format

Returns: our normalized format as HASHREF or undef on error

=head2 log

print log message to STDERR including this module's name

Returns: nothing

=head2 sanitise_zone

Sanitise a zone. This should always be called explicitly if you think
the zone could contain duplicate records. this is normally not necessary
but converting between formats of zone representations can trigger
unwanted results like multiple NS records.

=head1 AUTHOR

Lenz Gschwendtner

=head1 COPYRIGHT AND LICENSE

This software is copyright (c) 2013 by ideegeo Group Limited.

This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.

=cut