Lines Matching refs:nta
2312 rndccmd 10.53.0.4 nta -f -l 20s bogus.example 2>&1 | sed 's/^/ns4 /' | cat_i
2313 rndccmd 10.53.0.4 nta badds.example 2>&1 | sed 's/^/ns4 /' | cat_i
2316 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.1
2319 rndccmd 10.53.0.4 nta secure.example 2>&1 | sed 's/^/ns4 /' | cat_i
2320 rndccmd 10.53.0.4 nta fakenode.secure.example 2>&1 | sed 's/^/ns4 /' | cat_i
2323 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.2
2329 if [ "$ret" -ne 0 ]; then echo_i "failed - adding NTA's failed"; fi
2334 # check behavior with NTA's in place
2356 if [ "$ret" -ne 0 ]; then echo_i "failed - with NTA's in place failed"; fi
2360 echo_i "waiting for NTA rechecks/expirations"
2363 # secure.example and badds.example used default nta-duration
2364 # (configured as 12s in ns4/named1.conf), but nta recheck interval
2381 if [ "$ret" -ne 0 ]; then echo_i "failed - checking that default nta's were lifted due to recheck"; fi
2387 # it should still be NTA'd, but badds.example used the default
2392 # check nta table
2393 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n._11
2407 if [ "$ret" -ne 0 ]; then echo_i "failed - checking that default nta's were lifted due to lifetime"; fi
2422 # check nta table has been cleaned up now
2423 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.3
2427 if [ "$ret" -ne 0 ]; then echo_i "failed - checking that all nta's have been lifted"; fi
2431 echo_i "testing NTA removals ($n)"
2432 rndccmd 10.53.0.4 nta badds.example 2>&1 | sed 's/^/ns4 /' | cat_i
2433 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.1
2438 rndccmd 10.53.0.4 nta -remove badds.example >rndc.out.ns4.test$n.2
2440 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.3
2448 echo_i "remove non-existent NTA three times"
2449 rndccmd 10.53.0.4 nta -r foo >rndc.out.ns4.test$n.4 2>&1
2450 rndccmd 10.53.0.4 nta -remove foo >rndc.out.ns4.test$n.5 2>&1
2451 rndccmd 10.53.0.4 nta -r foo >rndc.out.ns4.test$n.6 2>&1
2458 echo_i "testing NTA with bogus lifetimes ($n)"
2459 echo_i "check with no nta lifetime specified"
2460 rndccmd 10.53.0.4 nta -l "" foo >rndc.out.ns4.test$n.1 2>&1 || true
2461 grep "'nta' failed: bad ttl" rndc.out.ns4.test$n.1 >/dev/null || ret=1
2466 echo_i "check with bad nta lifetime"
2467 rndccmd 10.53.0.4 nta -l garbage foo >rndc.out.ns4.test$n.2 2>&1 || true
2468 grep "'nta' failed: bad ttl" rndc.out.ns4.test$n.2 >/dev/null || ret=1
2473 echo_i "check with too long nta lifetime"
2474 rndccmd 10.53.0.4 nta -l 7d1h foo >rndc.out.ns4.test$n.3 2>&1 || true
2475 grep "'nta' failed: out of range" rndc.out.ns4.test$n.3 >/dev/null || ret=1
2481 # check NTA persistence across restarts
2484 echo_i "testing NTA persistence across restarts ($n)"
2485 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.1
2488 rndccmd 10.53.0.4 nta -f -l 30s bogus.example 2>&1 | sed 's/^/ns4 /' | cat_i
2489 rndccmd 10.53.0.4 nta -f -l 10s badds.example 2>&1 | sed 's/^/ns4 /' | cat_i
2490 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.2
2496 if [ "$ret" -ne 0 ]; then echo_i "failed - NTA persistence: adding NTA's failed"; fi
2505 # ns4 has now shutdown. wait until t=14 when badds.example's NTA
2525 # ns4 should be back up now. The NTA for bogus.example should still be
2530 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.3
2539 grep "ignoring expired NTA at badds.example" ns4/named.run >/dev/null || ret=1
2542 rndccmd 10.53.0.4 nta -remove bogus.example >rndc.out.ns4.test$n.6
2544 if [ "$ret" -ne 0 ]; then echo_i "failed - NTA persistence: restoring NTA failed"; fi
2549 # check "regular" attribute in NTA file works as expected at named
2553 echo_i "testing loading regular attribute from NTA file ($n)"
2554 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.1 2>/dev/null
2570 # ns4 has now shutdown. add NTA for secure.example. directly into the
2571 # _default.nta file with the regular attribute and some future timestamp.
2574 echo "secure.example. regular $future" >ns4/_default.nta
2587 # nta-recheck is configured as 9s, so at t=12 the NTAs for
2588 # secure.example. should be lifted as it is not a forced NTA.
2594 # the NTA has been lifted.
2600 rndccmd 10.53.0.4 nta -remove secure.example >rndc.out.ns4.test$n.4 2>/dev/null
2602 if [ "$ret" -ne 0 ]; then echo_i "failed - NTA persistence: loading regular NTAs failed"; fi
2607 # check "forced" attribute in NTA file works as expected at named
2611 echo_i "testing loading forced attribute from NTA file ($n)"
2612 rndccmd 10.53.0.4 nta -d >rndc.out.ns4.test$n.1 2>/dev/null
2628 # ns4 has now shutdown. add NTA for secure.example. directly into the
2629 # _default.nta file with the forced attribute and some future timestamp.
2631 echo "secure.example. forced $future" >ns4/_default.nta
2643 # nta-recheck is configured as 9s, but even at t=12 the NTAs for
2644 # secure.example. should not be lifted as it is a forced NTA.
2650 # as the NTA is still there.
2656 rndccmd 10.53.0.4 nta -remove secure.example >rndc.out.ns4.test$n.4 2>/dev/null
2658 if [ "$ret" -ne 0 ]; then echo_i "failed - NTA persistence: loading forced NTAs failed"; fi
2663 # check that NTA lifetime read from file is clamped to 1 week.
2666 echo_i "testing loading out of bounds lifetime from NTA file ($n)"
2676 # ns4 has now shutdown. add NTA for secure.example. directly into the
2677 # _default.nta file with a lifetime well into the future.
2679 echo "secure.example. forced $future" >ns4/_default.nta
2694 # dump the NTA to a file (omit validate-except entries)
2695 echo_i "testing 'rndc nta -d' with NTA"
2696 rndccmd 10.53.0.4 nta -d | grep -v ": permanent" >rndc.out.ns4.test$n.1 2>/dev/null
2704 # rndc nta outputs localtime, so append the timezone
2713 # diff from $added(now) + 1week to the clamped NTA lifetime should be
2720 echo_i "testing 'rndc nta' lifetime clamping"
2721 rndccmd 10.53.0.4 nta -d | grep ": permanent" >rndc.out.ns4.test$n.1 2>/dev/null
2729 rndccmd 10.53.0.4 nta -remove secure.example >rndc.out.ns4.test$n.3 2>/dev/null
2735 echo_i "testing 'rndc nta -d' displays validate-except entries"
2736 rndccmd 10.53.0.4 nta -d | grep ": permanent" >rndc.out.ns4.test$n.1 2>/dev/null
2746 # Sanity check behavior without an NTA in place.
2751 # Add an NTA, expecting that to cause resolution to succeed.
2752 rndccmd 10.53.0.9 nta badds.example >rndc.out.ns9.test$n.1 2>&1 || ret=1
2757 # Remove the NTA, expecting that to cause resolution to fail again.
2758 rndccmd 10.53.0.9 nta -remove badds.example >rndc.out.ns9.test$n.2 2>&1 || ret=1
2766 echo_i "completed NTA tests"