Commit 6a4d6e33 authored by Evan Hunt's avatar Evan Hunt
Browse files

adapted to the special needs of solaris's really old awk

parent 5d698de5
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE. # PERFORMANCE OF THIS SOFTWARE.
# $Id: tests.sh,v 1.4 2009/12/02 05:42:15 each Exp $ # $Id: tests.sh,v 1.5 2009/12/02 17:54:45 each Exp $
SYSTEMTESTTOP=.. SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh . $SYSTEMTESTTOP/conf.sh
...@@ -43,23 +43,23 @@ echo "I:signing zones" ...@@ -43,23 +43,23 @@ echo "I:signing zones"
$SIGNER -Sg -o $czone $cfile > /dev/null 2>&1 $SIGNER -Sg -o $czone $cfile > /dev/null 2>&1
$SIGNER -Sg -o $pzone $pfile > /dev/null 2>&1 $SIGNER -Sg -o $pzone $pfile > /dev/null 2>&1
awk -v CZ="${czone}." '$2 ~ /RRSIG/ { awk '$2 ~ /RRSIG/ {
type = $3; type = $3;
getline; getline;
id = $2; id = $2;
if ($3 ~ CZ) { if ($3 ~ /'${czone}'/) {
print type, id print type, id
} }
}' < ${cfile}.signed > sigs }' < ${cfile}.signed > sigs
awk '$2 ~ /DNSKEY/ { awk '$2 ~ /DNSKEY/ {
flags = $3; flags = $3;
while ($0 !~ "key id =") while ($0 !~ /key id =/)
getline; getline;
id = $6; id = $6;
print flags, id; print flags, id;
}' < ${cfile}.signed > keys }' < ${cfile}.signed > keys
echo "I:checking that KSK signed DNSKEY only ($n)" echo "I:checking that KSK signed DNSKEY only ($n)"
ret=0 ret=0
grep "DNSKEY $ksk"'$' sigs > /dev/null || ret=1 grep "DNSKEY $ksk"'$' sigs > /dev/null || ret=1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment