Safe Haskell | None |
---|---|
Language | Haskell2010 |
Network.DNS.Decode
- decode :: ByteString -> Either String DNSMessage
- decodeMany :: ByteString -> Either String ([DNSMessage], ByteString)
- receive :: Socket -> IO DNSMessage
- receiveVC :: Socket -> IO DNSMessage
Documentation
decode :: ByteString -> Either String DNSMessage Source #
Parsing DNS data.
decodeMany :: ByteString -> Either String ([DNSMessage], ByteString) Source #
Parse many length-encoded DNS records, for example, from TCP traffic.
receive :: Socket -> IO DNSMessage Source #
Receiving DNS data from Socket
and parse it.
receiveVC :: Socket -> IO DNSMessage Source #
Receive and parse a single virtual-circuit (TCP) response. It is up to the caller to implement any desired timeout. This (and the other response decoding functions) may throw ParseError when the server response is incomplete or malformed.