Miek Gieben
6ee0baab56
anything escaped in domain name is legal
...
Allow all character after a \ in a domainname. It's escaped, it's
legal.
2013-06-13 19:41:37 +01:00
Miek Gieben
b35306b755
Created two new types: Type and Class
...
Actually just go with Robert's suggestion as this seems the
cleanest way to do it. Also saves me from thinking about could
names for the new functions.
2013-06-08 14:09:37 +01:00
Miek Gieben
c72535f2d6
Add TypeToTypeString and ClassToClassString
...
After some discussion with Robert Edmonds, these helper functions
seems in order. It is not what he requested (that was an RRType
and RRClass as new types), but is does make sense to add some
convience functions to save some typing. The dns package itself
also used these function (4 times). So clearly there is a need.
I'm not completely sold about the names.
2013-06-08 13:59:49 +01:00
Miek Gieben
e8e8e84200
remove println
2013-06-05 22:33:15 +01:00
Miek Gieben
f6c697f52b
Fix IsDomainName
...
Make \.. legal (as it should be) and don't allocate a new var byte c
and every loop.
2013-06-05 22:06:02 +01:00
Miek Gieben
81941d4422
Update all copyright notices
2013-05-12 16:15:52 +02:00
Miek Gieben
d53d9eab81
gofmt
2013-05-05 20:30:44 +02:00
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
d758825590
more documentation
2012-12-02 10:14:53 +01:00
Miek Gieben
d618b07666
documentation
2012-12-02 09:15:10 +01:00
Miek Gieben
fa55001b4c
Add tests and fix bug in the parser
...
torc wasn't set in some part resulting in parsing a 'A' while
in fact the parsed record type should have been returned.
2012-11-22 11:54:46 +01:00
Miek Gieben
ac39024a25
gofmt
2012-11-21 23:20:56 +01:00
Miek Gieben
aba66ed110
beter
2012-11-21 16:27:36 +01:00
Miek Gieben
37d3009cec
Add escaped @ is ok
2012-11-21 15:59:00 +01:00
Miek Gieben
0351cc0ded
Merge branch 'master' of github.com:miekg/dns
2012-09-07 20:38:30 +02:00
Miek Gieben
cacd7c4dcd
fix merge
2012-09-07 20:37:45 +02:00
Miek Gieben
09e07339e6
struct embedding
2012-09-05 16:31:13 +02:00
Miek Gieben
a2d98be202
lowercase the names
2012-09-04 20:08:55 +02:00
Miek Gieben
07c4f74d85
don't assume there is a question section
...
closes #24
2012-09-03 07:40:16 +02:00
Miek Gieben
eaaef0af9d
Merge branch 'master' of github.com:miekg/dns
2012-08-25 22:08:22 +02:00
Miek Gieben
68961f2f5b
Make the IsTsig and IsEdn0 more usefull by returning the record
2012-08-25 11:24:01 +02:00
Miek Gieben
d6238e8649
do I really need all those function -- no
2012-08-25 10:01:54 +02:00
Miek Gieben
9abebc170f
Dont set the auth bit
2012-08-25 09:59:49 +02:00
Miek Gieben
6f7aad15d8
documenation
2012-08-21 17:36:58 +02:00
Miek Gieben
b720003623
make api smaller
2012-08-17 08:31:38 +02:00
Miek Gieben
1dffbeeee1
Fix IsSubDomain
2012-08-08 15:16:22 +02:00
Miek Gieben
5e5d1228a0
Return the msg you work on in the Set* methods
2012-08-07 08:09:30 +02:00
Miek Gieben
963fb55991
Fix some faults
2012-08-04 14:16:29 -07:00
Miek Gieben
af2f485c8e
Fix IsSubDomain
2012-07-16 19:16:36 +02:00
Miek Gieben
69344eee5f
Add ReverseAddr functie
2012-07-04 09:48:59 +02:00
Miek Gieben
de95ac0bb3
gofmt
2012-06-01 13:35:52 +02:00
Miek Gieben
2827f497aa
Add documentation for edns0
2012-06-01 13:11:17 +02:00
Miek Gieben
88a2d13a8f
Remove NewUpdate, we already have the simpler SetUpdate
2012-05-26 14:56:23 +02:00
Miek Gieben
7a3af5b729
Support $GENERATE (the bind extension).
...
It is even better than the bind one, because all records are
supported (as long as the output is valid)
2012-05-20 15:28:27 +02:00
Miek Gieben
983d979698
Some documentation fixes and origid is not needed in tsig
2012-05-18 19:59:07 +02:00
Miek Gieben
4f61f8621b
More server side TSIG stuff - does not validate (yet)
2012-03-04 22:32:23 +01:00
Miek Gieben
c53cddf38c
TSIG overhauled
...
This lead to some changes in the Write() function. Both
server side and client side are now more similar.
2012-03-04 21:00:09 +01:00
Miek Gieben
4f7000d1f6
Update the readme
2012-03-04 16:35:21 +01:00
Miek Gieben
99a7a57713
Upgrade the definition of domain name
2012-02-28 20:47:25 +01:00
Miek Gieben
89c05b4f74
gofmt
2012-02-23 19:37:08 +01:00
Miek Gieben
dc64d717eb
Remove the in-bailiwick comment line
...
in-bailiwick involves talk about delegation/glue 'n stuff.
Just leave it out.
2012-02-15 11:31:44 +01:00
Miek Gieben
63639e33f8
Add and test IsSubDomain function
2012-02-15 10:22:52 +01:00
Miek Gieben
cb1d41c607
First stab for IsSubDomain
2012-02-14 22:55:14 +01:00
Miek Gieben
6470b8335d
All numeric is OK too nowadays
2012-02-13 17:58:43 +01:00
Miek Gieben
2f64868d3c
Add quotes to the parsing engine.
...
Support:
TXT
NAPTR
And other record that we may use.
2012-02-13 13:19:37 +01:00
Miek Gieben
974f4214a2
More documentation updates
2012-02-12 11:37:52 +01:00
Miek Gieben
77b60231e7
If we add a dot to a name, be sure to remove one from the length
2012-02-05 11:33:55 +01:00
Miek Gieben
ed61734c89
Optimize the RR reading further
...
remove len(strings) from the code. 16% increase
in speed. Getting about 35K RR/s
2012-01-30 21:26:29 +01:00
Miek Gieben
be7100cb02
add a dot
2012-01-26 22:47:54 +01:00
Miek Gieben
5917838cbb
gofmt
2012-01-20 12:24:20 +01:00
Miek Gieben
3124872aec
Doesnt return anything
2012-01-15 16:20:25 +01:00
Miek Gieben
0351073d8e
Shorter function for SetUpdate and doc
2012-01-15 16:13:20 +01:00
Miek Gieben
d2acd22822
Add label functions and tests
2012-01-10 15:55:52 +01:00
Miek Gieben
973c5f3e1a
Add a splitlabels
2012-01-09 11:02:45 +01:00
Miek Gieben
cd266d5f0f
Its a uint8
2012-01-08 15:56:19 +01:00
Miek Gieben
ecfd5451a9
Remove the Labels() function.
...
This is now handled inside IsDomainName, which really parses
the name and then (also) returns the number of labels found.
2012-01-08 15:54:33 +01:00
Miek Gieben
b417c42bc2
Fix handling of dnames
...
Add support for escaped dots. Only thing to fix is the
fqdn-ness of user defined names.
2012-01-08 14:53:55 +01:00
Miek Gieben
0322d3a9da
Fix $ORIGIN in zonefiles
...
also check if a dname isn't fq, and add $ORIGIN is not.
2012-01-08 14:06:58 +01:00
Miek Gieben
f1ff334ab1
Rename DefaultTTL to DefaulTtl
...
This is more inline with the rest
2011-12-14 08:42:53 +01:00
Taral
c1889c778d
gofmt (excluding _examples)
2011-11-27 21:03:21 -08:00
Miek Gieben
7d73d6e9e1
Make opcode public and fix the IsEdns0
2011-09-19 13:34:16 +02:00
Miek Gieben
1f03789dcb
edns0 helper funtions
2011-09-11 13:01:18 +02:00
Miek Gieben
5352363707
SetEdns0 helper function
2011-09-11 12:57:06 +02: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
3be73fcea9
Tsig fixes
...
make tsig easier to use and even transparant when using the API
2011-09-11 01:10:47 +02:00
Miek Gieben
6e72207318
Simplify tsig
...
Add a couple of errors, and make the function signature
of the tis function more inline with the dnssec ones.
2011-09-10 16:50:27 +02:00
Miek Gieben
fa34fe67ca
move around the get/set methods
2011-09-02 14:28:40 +02:00
Miek Gieben
6eb42504c4
typo
2011-08-22 13:06:34 +02:00
Miek Gieben
3ce319eb8b
Add IsQuestion
2011-08-22 12:52:13 +02:00
Miek Gieben
aaf4af6401
add: setUpdate to create update packets
2011-08-22 10:29:39 +02:00
Miek Gieben
66ea81043c
Implement fully featured nameserver.
...
Currently:
* does positive DNSSEC (no NXDOMAIN)
* does plain NXDOMAIN
* Name error
* reasonable fast: 7000+ qps
2011-07-29 16:14:04 +02:00
Miek Gieben
5087f5a993
SMall fixes
2011-07-26 21:41:24 +02:00
Miek Gieben
47cc5b3e77
Fixes
2011-07-26 19:16:28 +02:00
Miek Gieben
96ddebf335
add miek.nl.signed as a test zone
...
Add support for more RRs - I can now parse my own zone
2011-07-24 22:21:48 +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
a0b011799e
documentation
2011-07-23 23:32:42 +02:00
Miek Gieben
f53ca4bfc3
add TSIG axfr test, still needs work though
2011-07-05 20:52:35 +02:00
Miek Gieben
5de08ff3dc
Update doc and set recursion = true in SetQuestion
2011-07-04 21:28:30 +02:00
Miek Gieben
3343234bf2
comment
2011-06-14 08:32:03 +02:00
Miek Gieben
19bfc93c5a
remove config.go
2011-04-18 22:08:12 +02:00
Miek Gieben
05a6852663
port tcp read
2011-04-18 18:27:59 +02:00
Miek Gieben
36aa317315
Create SetQuestion function
2011-04-14 22:22:24 +02:00
Miek Gieben
15d84f0d7d
Fix xfrprg -- needs testing
2011-03-30 17:50:07 +02:00
Miek Gieben
0449ff62a2
seeing some light in the query API
...
global channels look to be helpfull
2011-03-30 11:14:36 +02:00
Miek Gieben
4029c4153c
Use defaulTTL, more Go like
2011-03-25 17:47:35 +01:00
Miek Gieben
9ac4df6b1d
add a IsUpdate function
2011-03-25 10:16:55 +01:00
Miek Gieben
cef7dc4a31
documentation
2011-03-24 14:29:23 +01:00
Miek Gieben
f44bf2d656
Formatting
2011-03-24 09:24:24 +01:00
Miek Gieben
8b2882673f
Create xfr proxy
2011-03-23 10:48:21 +01:00
Miek Gieben
8b70e31c41
Fix examples and API additions
2011-03-23 09:50:38 +01:00
Miek Gieben
bac16eb644
Port to new api
2011-03-22 20:12:36 +01:00
Miek Gieben
a7a8b616f0
fix reflect
2011-03-21 22:53:15 +01:00
Miek Gieben
b1f63f57c4
Read/Write works, but axfr still fails
2011-03-20 19:58:55 +01:00
Miek Gieben
d728de7088
nicer api
2011-03-16 17:28:35 +01:00
Miek Gieben
a5f78d235c
Add defaults.go for easy pkt making
2011-03-16 12:19:15 +01:00