check for overflowing msg len when unpacking A

unclebadtouches catched this.

closes #141
DNSSEC algorithm and digest types now uint8
Merge pull request #142 from axaxs/master

DNSSEC algorithm and digest types now uint8
Remove ECC which was set as alg 4

There is no alg 4 and ECC is not an algorithm identifier.
Add CDNSKEY support
Merge branch 'master' of github.com:miekg/dns
Fix off-by-one error parsing DSA public key

I ran into a slice bounds out of range panic. Tired so I just rewrote it.
Implement SIG(0) signing and verification

This is based on @miekg's sig0 branch. That branch diverged from master
and I didn't want to wander off on a rebase.

As implemented there's no allowance for multi-envelope (TCP) support.

TODO:

* unpackUint32() could be moved out and used elsewhere
* tests
* multi-envelope support (if useful)
Test SIG(0)

Tests message signing and verification against
itself, that altered messages don't pass and that
expired messages don't pass.

Static samples generated by something else would
be good to add at some point.
Print unknown record type with CLASSX and TYPEX

When printing unknown records it is best to print the entire thing
as unknown, instead of relying on the internal defined type. An
example A record, printed as an unknown one:
    miek.nl.      3600    CLASS1  TYPE1   \# 4 0a000101
Merge pull request #144 from andrewtj/atj-sig0

SIG(0)
Merge branch 'master' of github.com:miekg/dns
Cleanup the identical parsing functions.

Some records are copies from others: DNSKEY, CDNSKEY and KEY are
identical. DS, CDS and DLV are too and even RRSIG and SIG.

The parsing functions and the definition can all be used for parsing
all these identical types.
Documentation cleanups
SIG0 misc - doc, bounds checking, refactor tests

* expand documentation a little and tweak comments
* add bounds checking in Verify()
* refactor tests
There is a copyright file now
Merge branch 'master' of github.com:miekg/dns
Fix package header
Merge branch 'andrewtj-atj-sig0'
fix buffer overrun in unpack()