danog/libdns-json

Encoder/decoder for google's JSON DNS message format based on libdns

0.2.0 2022-12-05 21:13 UTC

This package is auto-updated.

Last update: 2024-11-06 01:17:55 UTC


README

Build Status License

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