Miek Gieben
235e892dfc
Rename the RR types drop the RR_ prefix
...
This is also done in the official Go library. It also make the
code shorter.
2012-12-09 19:23:25 +01:00
Miek Gieben
2a3b818b95
Use much more descriptive names for the maps
...
Alg_str -> AlgorithmToString
Rr_str -> TypeToString
And for the reverse maps also.
2012-12-02 09:29:54 +01:00
Miek Gieben
48434502f4
layout tweaks in the source file
2012-11-30 14:05:08 +01:00
Miek Gieben
7298fe690c
tweak layout
2012-11-30 13:25:55 +01:00
Miek Gieben
7bd7a65e4d
Add CAA
2012-11-20 16:53:58 +01:00
Miek Gieben
67343920d5
Add CDS type
2012-11-20 16:52:18 +01:00
Miek Gieben
4737bfa319
Add the all important RKEY
2012-11-20 16:48:28 +01:00
Miek Gieben
3686d24ca7
Add NINFO record
2012-11-20 16:42:16 +01:00
Miek Gieben
f7956a96e6
ATMA
2012-11-20 14:32:06 +01:00
Miek Gieben
d34c05f4fc
Add def. of SIDN RR
2012-11-20 14:14:00 +01:00
Miek Gieben
f6896bea4f
Add X25 Resource Record
2012-11-20 14:07:16 +01:00
Miek Gieben
314a0eebcc
Add support for L32, NID, L64 and LP records
2012-11-18 10:29:05 +01:00
Miek Gieben
a95de22bc3
Pref -> Preference for all types that have one
2012-11-18 09:13:43 +01:00
Miek Gieben
5afca3330b
Add tests and uppercase output of L64
2012-11-18 09:10:28 +01:00
Miek Gieben
85366b595b
Fix presentation format
2012-11-17 23:01:35 +01:00
Miek Gieben
e2bc22cb43
Add LP record
2012-11-17 21:43:09 +01:00
Miek Gieben
a509e3af80
Add L64
2012-11-17 21:37:15 +01:00
Miek Gieben
4aea3d193b
Add L32 record
2012-11-17 21:32:02 +01:00
Miek Gieben
0c3a90193a
Add the NID record
2012-11-17 21:26:48 +01:00
Miek Gieben
1751b8d753
more stuff
2012-09-11 22:00:19 +02:00
Miek Gieben
f7f4aa7886
add more time functions
2012-09-11 21:54:07 +02:00
Miek Gieben
915781ea86
Better naming
2012-09-11 21:45:21 +02:00
Miek Gieben
3a6edfa2c9
fmt
2012-09-10 20:51:19 +02:00
Miek Gieben
6e9317868b
doc tweaks
2012-09-01 17:06:24 +02:00
Miek Gieben
e4fb00c34d
Fix handling of non fully qualified domain names
...
When PackDomain sees such a name it calls panic.
All panic now use the prefix 'dns:'
2012-08-28 18:21:23 +02:00
Miek Gieben
80038f2230
docs
2012-08-26 22:40:00 +02:00
Miek Gieben
73b6d37885
cleanup api, dont export Year68
2012-08-17 08:29:45 +02:00
Miek Gieben
a9126f1b54
Add RT type
2012-08-10 09:22:50 +02:00
Miek Gieben
ff707cf2c0
revert this too
2012-06-30 14:49:37 +02:00
Miek Gieben
f570d79c08
Export rr_mk (Rr_mk)
2012-06-30 13:16:38 +02:00
Miek Gieben
e6fca0be3f
Actually copy the RR for DNSSEC validation.
...
This is needed because we need to fiddle with the TTL and sometimes
even need to lowercase the rdata. We dont want this to propagate
to the original RRs
2012-06-20 19:16:54 +02:00
Miek Gieben
01442e58af
more Copy() functions
2012-06-20 17:44:18 +02:00
Miek Gieben
4177512abe
More Copy() methods
2012-06-20 17:12:10 +02:00
Miek Gieben
a6f42f338a
more copys
2012-06-20 14:32:23 +02:00
Miek Gieben
331276b2b1
add more Copy functions
2012-06-20 13:00:12 +02:00
Miek Gieben
f48dba4ad1
Add Copy to all RRs
2012-06-20 11:56:25 +02:00
Miek Gieben
89ec077d8f
Support the WKS record
2012-06-02 17:33:49 +02:00
Miek Gieben
fb0623fbb2
change comments
2012-06-01 22:23:21 +02:00
Miek Gieben
b2f459b7fa
fixes
2012-06-01 18:29:07 +02:00
Miek Gieben
de95ac0bb3
gofmt
2012-06-01 13:35:52 +02:00
Miek Gieben
e747b8f46e
Add AFSDB
2012-06-01 13:34:14 +02:00
Miek Gieben
969ce4371d
Add support for MD and MF
2012-06-01 13:25:54 +02:00
Miek Gieben
f3bb703019
gofmt
2012-05-22 08:48:26 +02:00
Miek Gieben
6b28ef1353
remove the TODO
2012-05-15 12:27:40 +02:00
Miek Gieben
f0154aa0c2
Fix and test rfc 1982 arithmetic
2012-05-15 12:24:57 +02:00
Miek Gieben
8c74494576
Call all preferences Pref, like MX
2012-05-06 20:59:44 +02:00
Miek Gieben
d3171d4f71
Also parse the RP record (wire + zone)
2012-05-01 22:57:22 +02:00
Miek Gieben
d30dcf93e0
Doesnt parse from string - otherwise it works
2012-04-30 23:59:15 +02:00
Miek Gieben
d85d8f9fe9
Start adding LOC tests
2012-04-30 21:42:58 +02:00
Miek Gieben
b50e3f690e
First chunk in parsing LOC RRs
2012-04-30 16:54:02 +02:00
Miek Gieben
2d231ae3b3
Fix LOC string output
2012-04-30 15:36:04 +02:00
Miek Gieben
60f368ba5b
Almost there in printing the LOC record
2012-04-30 14:50:52 +02:00
Miek Gieben
1948cd2a90
Use go vetted struct tags
...
They had the form: "domain-name", now they are key value pairs (key is
always dns: `dns:"domain-name"`
2012-04-29 21:55:29 +02:00
Miek Gieben
a3befb0651
typecode assigned
2012-04-14 10:44:32 +02:00
Miek Gieben
edf4b3d11b
Test signing with ecdsa
2012-04-11 15:13:17 +02:00
Miek Gieben
9cbe439ce3
Fix tsig 48 bits timer
2012-03-02 23:12:23 +01:00
Miek Gieben
e1873c28bc
move tsig to tsig.go just as RR_OPT
2012-03-02 23:07:25 +01:00
Miek Gieben
c5465127f3
Fix non tsig queries
2012-03-02 21:19:37 +01:00
Miek Gieben
3232814d1b
Fix client side TSIG
...
Redesign of TSIG. Validation is on the TOOD - this can be
done in the same way as in the server.
2012-03-01 22:40:34 +01:00
Miek Gieben
8220a1b148
use maximum bitmap length
2012-02-28 21:06:11 +01:00
Miek Gieben
a38a7311a0
NSEC3 bitmap length is still todo
2012-02-28 21:00:22 +01:00
Miek Gieben
ef2e12b0dd
Validation fixes, still not perfect, but much nicer
2012-02-25 22:04:29 +01:00
Miek Gieben
76d4547fbf
Rename Cname to Target in RR_CNAME
2012-02-25 22:01:49 +01:00
Miek Gieben
4ee6d26106
correctly quote txt
2012-02-23 13:34:46 +01:00
Miek Gieben
9c5c2ee96f
Fix very large SOA/TTL values
2012-02-19 18:36:59 +01:00
Miek Gieben
c82a1af1e3
HIP unpack support -- not tested
2012-02-19 15:33:12 +01:00
Miek Gieben
f45d4d933d
Add length for base64 encodings
2012-02-19 15:24:26 +01:00
Miek Gieben
73f11ddf6b
add URI record
2012-02-18 21:49:12 +01:00
Miek Gieben
9180a06d7c
base16 is hex
2012-02-18 20:22:06 +01:00
Miek Gieben
8a619fd289
Some HIP stuff
2012-02-18 20:07:25 +01:00
Miek Gieben
8ff38fb8c1
Allow parsing of TLSA
2012-02-18 19:08:39 +01:00
Miek Gieben
70122e69d5
Add SPF record
2012-02-18 18:59:19 +01:00
Miek Gieben
30d6def515
Add support for IPSECKEY; no wirefmt conversion as of yet
2012-02-16 23:59:44 +01:00
Miek Gieben
5dbfc48a5e
start fixing for unknown rrs parsing/printing
2012-02-13 21:12:14 +01:00
Miek Gieben
d235bf4c2e
Remove debugging stuff
2012-02-13 16:18:42 +01:00
Miek Gieben
c30821fece
Fix TXT packing and unpacking
2012-02-13 16:12:26 +01:00
Miek Gieben
2c44133163
Fixes for the new presentation of txt records
2012-02-13 15:59:40 +01:00
Miek Gieben
6ddb9ab88b
Txt record parsing works -- need to look at the on-the-wire stuff
2012-02-12 21:50:02 +01:00
Miek Gieben
53dcc5a425
update the todo
2012-02-12 13:06:47 +01:00
Miek Gieben
4e397e31ec
Add tlsa
2012-01-16 10:11:05 +01:00
Miek Gieben
9432a7deed
Add TSLA type - no type code yet
2012-01-16 10:06:21 +01:00
Miek Gieben
eb12c526f2
Add more tests
2012-01-11 21:03:47 +01:00
Miek Gieben
13f1f5b066
Question is compressible IMO
2012-01-11 16:22:58 +01:00
Miek Gieben
6d95911558
Dont allow the question section to be compressed
2012-01-11 16:16:09 +01:00
Miek Gieben
f39d939f52
Fix compression
...
The compression was fixed. Also the packing of message is been speed
up, by a facter of 3. Now the packing happens once, instead of
3 times.
Two tests still fail. atm
2012-01-11 16:04:52 +01:00
Miek Gieben
3fae586071
update all the lengths
2012-01-11 14:36:48 +01:00
Miek Gieben
b5d73f1eff
Implement compressible domain names
2012-01-11 11:19:07 +01:00
Miek Gieben
15d82f0b34
Fix the size -- was counting the labels, not the bytes
2012-01-10 13:47:34 +01:00
Miek Gieben
bacfa5a80c
A Len() to RR interface
...
This isn't yet finished, but it helps in asserting the amount of
space to alloc when packing a message
2012-01-10 10:43:28 +01:00
Miek Gieben
d6b1d886d1
Funkensturm updates
2011-12-20 12:53:47 +01:00
Miek Gieben
59a200131a
Fix sig incep/expir rfc1982 calc. needs to be done
2011-12-17 13:05:44 +01:00
Miek Gieben
ef7b6f525f
gofmt
2011-12-16 14:48:30 +01:00
Miek Gieben
081166db5e
Fix the tests (Again) + NewRR(str)
...
Parse tests start to get working again
NewRR reads a string and is the easiest way to get an RR
in your code.
2011-12-15 17:37:07 +01:00
Miek Gieben
b73eaf020b
Fix incep,expir date representation in rrsigs
2011-12-15 12:41:24 +01:00
Miek Gieben
32a879d970
New parsing works, but a lot of stuff needs to be fixed:
...
* Parsing the different records
* Parsing private key files (trivial, but needs to be done)
2011-12-14 11:30:29 +01:00
Miek Gieben
131f6962d1
gofmt
2011-12-09 21:45:57 +01:00
Miek Gieben
17d3f12d31
Fix NSEC presentation
2011-12-09 16:11:37 +01:00
Miek Gieben
e115e5da6e
Update to the latest weekly: weekly/weekly.2011-12-06
...
The new time API must still be used. But for now it compiles.
All DNSSEC/TSIG timing is probably broken
2011-12-09 11:16:49 +01:00
Miek Gieben
22a467e718
Fixes the latest weekly
2011-11-02 23:06:54 +01:00
Miek Gieben
f252e2f3f0
Add documentation and fix the tests for TSIG
...
Everything is working, I get a complete TSIG verified AXFR from
miek.nl.
2011-09-11 01:37:06 +02:00
Miek Gieben
31b2aec24e
Parse differently
...
Returned each parsed RR on a channel and let the caller decide what
to do with it.
Ragel is still broken, so this is non tested code.
2011-09-02 13:44:35 +02:00
Miek Gieben
8c5049bd06
Add actual type any as RR_ANY
2011-08-22 14:13:43 +02:00
Miek Gieben
18596dd3f8
Use typeANY, not typeALL
2011-08-22 14:11:41 +02:00
Miek Gieben
0d917b3c92
accept an uint16, not an int
2011-08-08 10:35:16 +02:00
Miek Gieben
27948bb9f9
Use uint16 instead of int
2011-08-04 15:13:10 +02:00
Miek Gieben
b2a6356596
Fix opt pseudo section stuff
2011-07-25 11:24:26 +02:00
Miek Gieben
282feff62e
add NSEC3PARAM
2011-07-24 21:40:04 +02:00
Miek Gieben
00f8254ae1
Fix parsing of RRSIGs
2011-07-24 21:29:16 +02:00
Miek Gieben
4671072027
Error handling
...
Handle semantic errors in the input stream.
Try to use Ragel's error handling when seeing a non-supported
class. This does not work yet.
2011-07-24 17:08:33 +02:00
Miek Gieben
da0603089a
gofmt -w
2011-07-23 23:43:43 +02:00
Miek Gieben
9b1e7b4b3d
documentation
...
make Str_rr and Str_class private, prolly only needed
for parsing
2011-07-23 23:15:40 +02:00
Miek Gieben
0dcfa0b427
Kill SetString
...
Create a NewRR that creates a new RR from a string.
FIx the tests to relfect this
2011-07-23 22:26:50 +02:00
Miek Gieben
31ab707ea6
make it simpler
2011-07-23 09:21:24 +02:00
Miek Gieben
2a8d7f9694
Make the API more Go like
2011-07-22 23:28:04 +02:00
Miek Gieben
b03994e257
NSEC and NSEC3 parsing support
...
Needs some work, but it is working
2011-07-22 20:23:36 +02:00
Miek Gieben
7c716e66c0
Parsing zone files - does not work (yet)
2011-07-18 20:47:03 +02:00
Miek Gieben
e50100848c
Fix parsing of AAAA records
2011-07-18 17:40:55 +02:00
Miek Gieben
91b41d02bb
SetString for DNSKEY and RRSIG
2011-07-18 15:49:20 +02:00
Miek Gieben
2eecc66477
SetString() for a bunch of RR - to be extended
2011-07-18 15:19:47 +02:00
Miek Gieben
4c55428a6e
add ClassNONE (254)
2011-03-25 11:49:52 +01:00
Miek Gieben
8aa88a0bd3
normalize errors
2011-03-25 11:19:35 +01:00
Miek Gieben
9bc0f3ed6b
More TSIG stuff
2011-03-21 10:51:28 +01:00
Miek Gieben
0a742210ca
Add DHCID record
2011-03-13 13:11:11 +01:00
Miek Gieben
e585cbf8f4
Add KX record
2011-03-13 13:04:54 +01:00
Miek Gieben
94b98a5766
Add nsec3 hashing (non working atm)
2011-03-07 22:47:20 +01:00
Miek Gieben
8495bccee4
Fix printing of unknown rrs
2011-03-04 17:30:29 +01:00
Miek Gieben
5c6f9f613e
implement parsing of longer (>255) txt records
2011-02-28 10:28:07 +01:00
Miek Gieben
98e4b33cb5
formatting and documentation
2011-02-24 16:22:14 +01:00
Miek Gieben
77348913dd
Update the documentation
2011-02-24 16:13:23 +01:00
Miek Gieben
266ed16e72
refactor the rrset to signedata function
2011-02-24 15:29:36 +01:00
Miek Gieben
b19fa97c1d
Add URI RR type - type just got allocated number 256
2011-02-23 09:11:03 +01:00
Miek Gieben
839f6bf901
Unknown rrs in type bitmap for nsec3
2011-02-21 16:21:16 +01:00
Miek Gieben
d127ce7931
Unknown rrs in type bitmap for nsec
2011-02-21 16:20:24 +01:00
Miek Gieben
a90533a13f
implement unknown RRs
...
RFC3597 - unknown rr are implemented. Currently Go dns
needs to now the type code, but must lack the actual implementation
of that type.
See IPSECKEY as an example.
2011-02-21 15:57:15 +01:00
Miek Gieben
f082cd36ca
unknown dns as type
2011-02-21 15:19:52 +01:00
Miek Gieben
1743555d07
add TALINK
2011-02-21 13:24:45 +01:00
Miek Gieben
65c4282944
add TA and DLV records
2011-02-21 13:16:07 +01:00
Miek Gieben
d87e7eff86
support nsec3 and nsec3param
2011-02-03 20:39:43 +01:00
Miek Gieben
d9dfd913a7
documentation updates
2011-01-27 09:29:11 +01:00
Miek Gieben
bdde78ff2f
TSIG works
2011-01-26 15:13:06 +01:00
Miek Gieben
3699c21a53
added SPF
2011-01-25 14:07:01 +01:00
Miek Gieben
7e1f9490f2
Cert RR added
...
PubKey is named PublicKey in the RR_DNSKEY
2011-01-25 13:57:54 +01:00
Miek Gieben
2431b84a3c
added DNAME
2011-01-25 13:47:12 +01:00
Miek Gieben
9eea4682fd
Fix documentation
2011-01-17 21:10:48 +01:00
Miek Gieben
d2d1d2e533
LOC record is awfull
2011-01-17 16:22:02 +01:00
Miek Gieben
0f364d638e
No space after the header in String()
2011-01-17 16:03:06 +01:00
Miek Gieben
74796c8672
Add SRV and NAPTR record support
2011-01-17 10:30:20 +01:00
Miek Gieben
222d01625c
Fix presentation for NSEC3
2011-01-10 16:18:01 +01:00
Miek Gieben
69f9bc6ecd
Start packing nsec/nsec3 typeBitMap
2011-01-09 22:51:36 +01:00
Miek Gieben
7da3d0bcb7
Fix the NSEC(3) bitmap
2011-01-09 22:02:25 +01:00
Miek Gieben
15fedf72e7
nsec type list must be uint16
2011-01-09 20:46:21 +01:00
Miek Gieben
42ce4d3085
Fix tsig -- needs testing
2011-01-09 15:54:23 +01:00
Miek Gieben
a6fee19f4c
Fix tsig by making timeSigned a 64 bit int
...
only use the lower 48 bits to make it all work
2011-01-09 15:30:45 +01:00
Miek Gieben
19edd05274
Fold dnssec back into dns
...
It is more natural. Otherwise tsig and tkey needed to be
put in their own packages
2011-01-09 10:31:23 +01:00
Miek Gieben
ac687f284a
Tsig
...
* add some testcases for tsig
* add unpack/pack stuff -- doesn't work correctly yet
2011-01-09 00:11:22 +01:00
Miek Gieben
1b39853f03
tsig generation; first stab
2011-01-08 22:39:15 +01:00
Miek Gieben
b2e9fc8d84
Added TSIG
...
By defining a new struct I can re-use all the nice
stuff in msg.go
2011-01-08 21:51:20 +01:00
Miek Gieben
fc8e6345af
Fix examples and add notify prog
...
Show how simple a dns-notify becomes.
2011-01-08 13:46:51 +01:00
Miek Gieben
d4059485d5
Add even more rcodes
2011-01-03 10:44:00 +01:00
Miek Gieben
aeb1ce8d9c
Fix the constnames
2011-01-01 20:51:34 +01:00
Miek Gieben
10bfb3d036
Complete the list of DNS q opcodes
2011-01-01 19:51:25 +01:00
Miek Gieben
7c2de14b8d
add TKEY and finalize TSIG
...
No crypto validation ofcourse... only the definition of the RRs
2011-01-01 19:26:08 +01:00
Miek Gieben
82c954bead
Rename the TSIG error codes
2010-12-31 15:20:56 +01:00
Miek Gieben
9155d632f5
add TSIG as a type
2010-12-31 15:10:42 +01:00
Miek Gieben
0dcdbe4361
Fix DNS over TCP
...
Actually send the 2 bytes length and also be prepared
to receive them.
2010-12-31 14:11:52 +01:00
Miek Gieben
cc66917658
Add basic support for the LOC record
2010-12-30 20:55:25 +01:00
Miek Gieben
2decd91cb4
Add the NAPTR record
2010-12-30 20:50:31 +01:00
Miek Gieben
9d1d7444a3
Some fixes from creating a dig-like program
2010-12-30 16:38:16 +01:00
Miek Gieben
bcf320aad4
rename the examples dir
...
Make it *not* show up in godoc
2010-12-30 14:13:28 +01:00
Miek Gieben
15dd65171b
Split the package in multiple packages
...
dns - the standard rrtypes and such
dnssec - validation, keytag calculation, etc
resolver - for talking to servers
2010-12-30 13:42:52 +01:00
Miek Gieben
de5b30f781
zo dan
2010-12-29 16:11:23 +01:00
Miek Gieben
5ced9e2152
almost ready for DNSSEC validation
...
only need call the crypto/rsa func
2010-12-28 14:57:30 +01:00
Miek Gieben
4ed14b9785
More cleansup and robustness
...
* make the resolver more robust
* more dnssec functions
2010-12-28 09:41:54 +01:00
Miek Gieben
73cc848e00
remove these files, stay lean and mean
2010-12-28 08:29:17 +01:00
Miek Gieben
8dbefdd3f1
Add key2ds conversion
...
More DNSSEC pieces are coming together
2010-12-27 13:56:58 +01:00
Miek Gieben
830b2eae29
add hex encoding for DS record
...
* some more edns finishing touches
2010-12-27 09:58:45 +01:00
Miek Gieben
65caf6f891
Documentation!
...
Make the packet documentation much nicer.
2010-12-25 11:14:11 +01:00
Miek Gieben
fd9afcb44d
Add signature helper function
...
Do this in dnssec.go so that all DNSSEC stuff in contained
in that file.
Add testing too
2010-12-24 11:50:42 +01:00
Miek Gieben
26f62197ba
Types should be usable with the Go type system
2010-12-23 17:16:28 +01:00
Miek Gieben
04a18e9937
Define NSEC3 and NSEC and NSEC3PARAM RRs
...
Those come with new rdata-types that still needs to be impl.
2010-12-23 16:37:54 +01:00
Miek Gieben
e5a394b97e
more printing tweaks for OPT
2010-12-23 14:43:26 +01:00
Miek Gieben
8302d19b42
At least it gives formerr now
2010-12-23 11:02:01 +01:00
Miek Gieben
1a50861b43
another stab at edns0
2010-12-22 23:05:21 +01:00
Miek Gieben
4ce23b71cf
Fix the encoding a EDNS RR
...
Still need to handle the domain name packer, so that we can
detect we have an OPT RR, with the different encoding
2010-12-22 20:53:18 +01:00
Miek Gieben
0f05a2f434
Make a stab for EDNS
2010-12-22 12:26:50 +01:00
Miek Gieben
e650aae18b
EDNS impl.
...
Needs more work, especially in the handling of the
RR.Hdr which is diff. for EDNS rrs
2010-12-22 10:30:41 +01:00
Miek Gieben
63c4d10ed0
Add stuff for EDNS
2010-12-21 21:12:43 +01:00
Miek Gieben
b8c9280cc4
add the remaining flags in the DNS headers
...
Next up: EDNS
2010-12-21 14:41:48 +01:00
Miek Gieben
392f418a0e
Fix the inception printing
...
Still need to add serial arithmetic to the calculations
2010-12-20 22:44:50 +01:00
Miek Gieben
0ed946d772
commit other changes too
2010-12-20 22:20:13 +01:00
Miek Gieben
0e00511c31
Make the resolver a goroutine
...
Fits more nicely with DNS, async. for free
Renamed the files: dropped the dns prefix
2010-12-18 20:31:26 +01:00