GithubHelp home page GithubHelp logo

dns-zone's People

Contributors

ahukkanen avatar dwradcliffe avatar lantins avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

dns-zone's Issues

New maintainer needed?

I opened some pull requests two months ago, no reaction yet. Last commit almost 3 years ago.

So, is this project abandoned? New maintainer needed? @lantins

I'd like to avoid forking and publishing under a different name on Rubygems. But I don't see much other options when I need some fixes or features. (Note that specifying a Github repo as dependency is not possible in a gemspec file.)

Example in README does not work

Updating the SOA in the example does not actually work!

zone.soa.nameserver = 'ns0.lividpenguin.com.'

The SOA is just another RR and is treated the same, the exception is it must be the first RR and you can only have one of them.

So the 'short hand' syntax makes sense, this should be supported.

MX server wuldn't be domain name

Hi, i have problem with loading MX records, where server si not domain name, but just "mail".
For example:

                        MX      10 mail               
mail                    A       some_ip

It's valid record, but you don't load it because you expect full domain name like mail.example.com.

Lower-/mixed-case keywords causing failure

It appears that zonefiles that use lowercase class and RR type keywords are causing DNS::Zone.load to choke and throw an exception:

#! /usr/bin/ruby
require('rubygems')
require('dns/zone')

zdata = <<EOT
$ttl 3600
$origin dnszone.example.com.
@               in soa      ns1.example.com. hostmaster.dnszone.example.com. (
                            2012052400  ; serial
                            345600      ; refresh
                            3600        ; retry
                            604800      ; expire
                            3600        ; ttl
)
EOT

DNS::Zone.load(zdata)
=> RuntimeError: Unknown or unsupported RR Type
	from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone/rr.rb:56:in `load'
	from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:105:in `block in load'
	from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:91:in `each'
	from /usr/local/share/gems/gems/dns-zone-0.3.1/lib/dns/zone.rb:91:in `load'

There is no requirement that the keywords be uppercase.

I'll see if I can work up a patch for this.

Zone files with multiple $ORIGINs produce incorrect labels

Zone files with more than one $ORIGIN will produce incorrect (repeating) labels for records with later $ORIGINs that don't explicitly set their name to either '@' or some other name.

For example:

$ORIGIN example.com.
@   3600    SOA     ns1.example.com. (
                        hostmaster.example.com.
                        42
                        3600
                        600
                        86400
                        300
                        )

$ORIGIN sub.example.com.
@   3600    CNAME   sub2.example.com.
    3600    MX      10 mail.example.com.

will produce:

> zone = DNS::Zone::load(File.read('test.zone'))
> zone.records.each{ |r| puts r.label }
  @
  sub
  sub.sub

where the third label should be 'sub'.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.