Questions

Try these questions to test your knowledge of this chapter:

  1. Which function fills in an address needed for socket programming in a portable and protocol-independent way?
  2. Which socket programming function can be used to convert an IP address back into a name?
  3. A DNS query converts a name into an address, and a reverse DNS query converts an address back into a name. If you run a DNS query on a name, and then a reverse DNS query on the resulting address, do you always get back the name you started with?
  4. What are the DNS record types used to return IPv4 and IPv6 addresses for a name?
  5. Which DNS record type stores special information about email servers?
  6. Does getaddrinfo() always return immediately? or can it block?
  7. What happens when a DNS response is too large to fit into a single UDP packet?

The answers are in Appendix A, Answers to Questions.