#!/usr/bin/perl
-# Copyright (c) 2010 Peter Palfrader <peter@palfrader.org>
+# Copyright (c) 2010, 2014, 2015, 2017 Peter Palfrader <peter@palfrader.org>
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
next unless (lc($rr->name) eq lc($zone));
my $tag = $options{'pretty'} ? sprintf("%5d(%d)", $rr->keytag, $rr->algorithm) : $rr->keytag;
+
+ if ($type eq 'DNSKEY' && ($rr->{'flags'} & (1<<(15-8)))) {
+ # key is revoked
+ next;
+ }
+
# for now only handle KSKs, i.e. keys with the SEP flag set
- if ($type eq 'DNSKEY' && !($rr->is_sep)) {
+ if ($type eq 'DNSKEY' && !($rr->sep)) {
push @zsks, $tag;
next;
}