* APL record: add structure and code point
* APL record: add wire format support
* APL record: add presentation format support
* APL record: add isDuplicate implementation
* APL record: add copy implementation
* APL record: add len implementation
* APL record: run go generate
* APL record: fix condition checking for equality
* APL record: use switches to map family to address length
* APL record: check bounds of individual fields rather than whole header
* APL record: stylistic changes
* APL record: remove APLPrefix methods from public interface
* APL record: update README
* APL record: additional cleanup for code review
* APL record: change return type from pointer to struct
* APL record: refactor of pack and unpack to eliminate extra variables
* Support the zero length EDNS0 EXPIRE option
* EDNS0 EXPIRE: Just reference the RFC, don't link to it
Co-Authored-By: Miek Gieben <miek@miek.nl>
Co-authored-by: Miek Gieben <miek@miek.nl>
* doc: fix xfr example.
The currently example code has a data race, put in the proper code.
Fixes: #1061
Signed-off-by: Miek Gieben <miek@miek.nl>
* Feedback
Signed-off-by: Miek Gieben <miek@miek.nl>
* Doc fixes
Polish the docs a bit; fix a link to miek.nl, remove edns0client subnet
draft link and point to the RFC. Some layout fixes and pull GOPATH from
the readme as we do go modules now.
Signed-off-by: Miek Gieben <miek@miek.nl>
* review comments
Signed-off-by: Miek Gieben <miek@miek.nl>
This license file is not being recognized by Github, nor by the new
google golang thingy recently launched. Don't remove those lines just
yet, but put them at the bottom
Signed-off-by: Miek Gieben <miek@miek.nl>
git shows:
git shortlog -sne | head
3311 Miek Gieben <miek@miek.nl>
157 Tom Thorogood <me+github@tomthorogood.co.uk>
39 Alex Sergeyev <asergeyev@dyn.com>
37 Andrew Tunnell-Jones <andrew@tj.id.au>
34 Filippo Valsorda <filippo@cloudflare.com>
21 Rafael Dantas Justo <rafael@registro.br>
19 Michael Haro <mharo@google.com>
14 Alex Sergeyev <abc@alexsergeyev.com>
13 chantra <chantra@users.noreply.github.com>
11 Alex Ciuba <alexciuba@gmail.com>
I took the top 2, but happy to extend this obvs.
Signed-off-by: Miek Gieben <miek@miek.nl>
Replace all the private methods in the EDNS0 with public methods.
Additionally, as suggested in issue #857, made Pack receive a
pre-allocated byte array, introduce a Len method, and have Pack
and Unpack return the number of octets written and read (respectively)
if there was no error.
Closes#857
* change NextLabel and PrevLabel to be faster
This reduces readability, but they are in the hot path of coredns.
* @redyeti pointed out, that my implementation disregarded triple backslashes
* add synthetic benchmark-tests for PrevLabel and NextLabel
* rename ii -> j
* invert compare
* PrevLabel: add empty string check + test case
* NextLabel: fix and add testcase for NextLabel("", offset>0)
While the range number of GENERATE is now limited, one can pass
a line with 2 $GENERATE directive that will exponentially increase the
time spent generating RRs.
Limit to only one per line.
Fixes#1020
* Limit $GENERATE range to 65535 steps
Having these checks means all test in TestCrasherString() are not
reached because we bail out earlier - removed that test all together.
Fixes#1019
Signed-off-by: Miek Gieben <miek@miek.nl>
* bring back testcase
Signed-off-by: Miek Gieben <miek@miek.nl>
* bring back crash test
Signed-off-by: Miek Gieben <miek@miek.nl>
* [scan] fix crashers when parsing comment
When dealing with comments the parsers was potentially incrementing comi
variable twice. During the second access to com[], comi was possibly
longer than maxTok, causing an out of bound error:
panic: runtime error: index out of range [2048] with length 2048
* * Keep only 1 crasher test string.
* move tests from scan_test.go to fuzz_test.go
* [fuzz] Fix crashes when parsing GENERATE
Running the fuzzer on NewRR, some crashes came up that could be
prevented by checking that the token after the range is a Blank.
This diff checks that and return an error when the blank is not found.
* * s/Expect blank /garbage /
* get rid of if/else
One of the test from DNS Compliance testing validates that if the opcode
is not supported, a NOTIMPL rcode is returned.
e0884144dd/genreport.c (L293)
This diff makes the default acceptfunc support this case and reply with
NOTIMPL instead of FORMERR.