Safe Haskell | None |
---|---|
Language | Haskell2010 |
Network.DNS.IO
- receive :: Socket -> IO DNSMessage
- receiveVC :: Socket -> IO DNSMessage
- send :: Socket -> ByteString -> IO ()
- sendVC :: Socket -> ByteString -> IO ()
- encodeQuestions :: Identifier -> [Question] -> [ResourceRecord] -> Bool -> ByteString
- composeQuery :: Identifier -> [Question] -> ByteString
- composeQueryAD :: Identifier -> [Question] -> ByteString
- responseA :: Identifier -> Question -> [IPv4] -> DNSMessage
- responseAAAA :: Identifier -> Question -> [IPv6] -> DNSMessage
Receiving from socket
receiveVC :: Socket -> IO DNSMessage Source #
Receive and parse a single virtual-circuit (TCP) query or response. It is up to the caller to implement any desired timeout.
Sending to socket
sendVC :: Socket -> ByteString -> IO () Source #
Sending composed query or response to a single virtual-circuit (TCP).
Creating Query
Arguments
:: Identifier | |
-> [Question] | |
-> [ResourceRecord] | Additional RRs for EDNS. |
-> Bool | Authentication |
-> ByteString |
Creating query.
composeQuery :: Identifier -> [Question] -> ByteString Source #
Deprecated: Use encodeQuestions instead
Composing query without EDNS0.
composeQueryAD :: Identifier -> [Question] -> ByteString Source #
Deprecated: Use encodeQuestions instead
Composing query with authentic data flag set without EDNS0.
Creating Response
responseA :: Identifier -> Question -> [IPv4] -> DNSMessage Source #
Composing a response from IPv4 addresses
responseAAAA :: Identifier -> Question -> [IPv6] -> DNSMessage Source #
Composing a response from IPv6 addresses