auth_badzone.feature 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. Feature: Authoritative DNS server with a bad zone
  2. This feature set is for testing the execution of the b10-auth
  3. component when one zone is broken, whereas others are fine. In this
  4. case, b10-auth should not reject the data source, but reject the bad
  5. zone only (with SERVFAIL) and serve the good zones anyway.
  6. Scenario: Bad zone
  7. Given I have bind10 running with configuration auth/auth_badzone.config
  8. # loading example.com, example.net and example.info zones fail.
  9. # Note: wait for these messages right away as otherwise they
  10. # will be logged and we cannot use the 'new' keyword to wait for
  11. # 3 different log messages. *There could still be a race here if
  12. # auth starts very quickly.*
  13. And wait for new bind10 stderr message DATASRC_LOAD_ZONE_ERROR
  14. And wait for new bind10 stderr message DATASRC_LOAD_ZONE_ERROR
  15. And wait for new bind10 stderr message DATASRC_LOAD_ZONE_ERROR
  16. And wait for bind10 stderr message BIND10_STARTED_CC
  17. And wait for bind10 stderr message CMDCTL_STARTED
  18. And wait for bind10 stderr message AUTH_SERVER_STARTED
  19. bind10 module Auth should be running
  20. And bind10 module Resolver should not be running
  21. A query for www.example.org should have rcode NOERROR
  22. The last query response should have flags qr aa rd
  23. The last query response should have ancount 1
  24. The last query response should have nscount 2
  25. The last query response should have adcount 2
  26. The answer section of the last query response should be
  27. """
  28. www.example.org. 3600 IN A 192.0.2.1
  29. """
  30. The authority section of the last query response should be
  31. """
  32. example.org. 3600 IN NS ns1.example.org.
  33. example.org. 3600 IN NS ns2.example.org.
  34. """
  35. The additional section of the last query response should be
  36. """
  37. ns1.example.org. 3600 IN A 192.0.2.3
  38. ns2.example.org. 3600 IN A 192.0.2.4
  39. """
  40. A query for www.example.com should have rcode SERVFAIL
  41. A query for www.example.net should have rcode SERVFAIL
  42. A query for www.example.info should have rcode SERVFAIL