coredns-umbrella

CoreDNS-Umbrella is a CoreDNS plugin for forwarding client identity information
to Cisco Umbrella. It adds Cisco's EDNS0 options to a query.
Corefile
. {
umbrella organization_id 12345678 device_id 0123456789abcdef
forward . 208.67.222.222 208.67.220.220
}
Cisco Umbrella wire-format documentation
The option payload is 28 bytes for an IPv4 client and 40 bytes for an IPv6
client:
| Bytes |
Meaning |
4f 44 4e 53 |
Magic value ODNS |
01 |
Version |
00 |
Flags |
00 08 + 4 bytes |
Organization ID, unsigned and big-endian |
00 10 + 4 bytes |
Client IPv4 address, for an IPv4 client |
00 20 + 16 bytes |
Client IPv6 address, for an IPv6 client |
00 40 + 8 bytes |
8-byte device ID |
Each payload contains exactly one client address field matching the connecting
client's address family.
Register plugin
Add the following entry before forward in CoreDNS's plugin.cfg:
umbrella:github.com/xdkr/coredns-umbrella
forward:forward
Build locally:
make build
Testing
Run the Go test suite:
make test
Run the IPv4 and IPv6 end-to-end profiles. Each uses a DNS client, this plugin
compiled into CoreDNS, and a validating fake Cisco receiver:
make test-e2e
Run either profile separately with make test-e2e-ipv4 or
make test-e2e-ipv6.
See e2e/README.md for the validations performed by the
Docker harness.
License
MIT