danog / libdns-json
Encoder/decoder for google's JSON DNS message format based on libdns
Installs: 542 411
Dependents: 1
Suggesters: 0
Security: 0
Stars: 4
Watchers: 1
Forks: 0
Open Issues: 0
Requires
- php: >=8.1
- ext-json: *
- daverandom/libdns: ^2.0.1
Requires (Dev)
- amphp/php-cs-fixer-config: v2.x-dev
- phpunit/phpunit: ^9
- psalm/phar: ^5.1
This package is auto-updated.
Last update: 2024-12-02 16:41:29 UTC
README
Encoder/decoder for google's JSON DNS message format based on libdns.
The API consists of a QueryEncoderFactory
that creates QueryEncoder
objects, that can encode libdns Message
objects to a query string that can be used both with google's and cloudflare's DNS-over-HTTPS APIs (for cloudflare, using directly UDP wireformat with libdns
's Encoder
is recommended).
The JsonDecoderFactory
creates JsonDecoder
objects, that accept JSON strings and decode them back to Message
objects.
Installation
composer require danog/libdns-json