Registry / networking / dns-parser

dns-parser

JSON →
library0.8.0rscratesunverified

Pure-rust DNS protocol parser library. Does not support network, only raw protocol parsing.

# Cargo.toml [dependencies] dns-parser = "0.8.0"
INSTALL
IMPORT
SIG · DNS-PARSER
D
dns-parser
networkingrustv0.8.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Packet
use dns_parser::Packet;

Parse a raw DNS packet into a structured representation.

use dns_parser::Packet; let data = b"..."; // raw DNS packet bytes let packet = Packet::parse(data).unwrap(); println!("Questions: {:?}", packet.questions);
Debug
Known issues
gotchaDoes not handle network I/O; only parses raw bytes.
fix
Use a networking library (e.g., tokio) to send/receive DNS packets separately.
affects: >=0.8.0
Upgrade
Version history
0.8.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
16 hits · last 30 days
node
14
Amazon
1
OpenAI (training)
1
Resources
dns-parser — cargo add dns-parser · libregistry