3252. [bug] When master zones using inline-signing were

updated while the server was offline, the source
			zone could fall out of sync with the signed
			copy. They can now resynchronize. [RT #26676]
This commit is contained in:
Evan Hunt
2011-12-22 07:32:41 +00:00
parent dd0d54ff01
commit f30785f506
23 changed files with 558 additions and 201 deletions

View File

@@ -14,7 +14,7 @@
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
# $Id: tests.sh,v 1.8 2011/12/08 16:07:20 each Exp $
# $Id: tests.sh,v 1.9 2011/12/22 07:32:40 each Exp $
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
@@ -28,11 +28,24 @@ israw () {
rawversion () {
perl -e '$input = <STDIN>;
if (length($input) < 2) { print "not raw\n"; exit 0; };
if (length($input) < 8) { print "not raw\n"; exit 0; };
($style, $version) = unpack("NN", $input);
print ($style == 2 ? "$version\n" : "not raw\n");' < $1
}
sourceserial () {
perl -e '$input = <STDIN>;
if (length($input) < 20) { print "UNSET\n"; exit; };
($format, $version, $dumptime, $flags, $sourceserial) =
unpack("NNNNN", $input);
if ($format != 2 || $version < 1) { print "UNSET\n"; exit; };
if ($flags & 02) {
print $sourceserial . "\n";
} else {
print "UNSET\n";
}' < $1
}
DIGOPTS="+tcp +noauth +noadd +nosea +nostat +noquest +nocomm +nocmd"
status=0
@@ -62,6 +75,13 @@ israw ns1/example.db.compat || ret=1
[ $ret -eq 0 ] || echo "I:failed"
status=`expr $status + $ret`
echo "I:checking source serial numbers"
ret=0
[ "`sourceserial ns1/example.db.raw`" = "UNSET" ] || ret=1
[ "`sourceserial ns1/example.db.serial.raw`" = "3333" ] || ret=1
[ $ret -eq 0 ] || echo "I:failed"
status=`expr $status + $ret`
echo "I:waiting for transfers to complete"
sleep 1