Fix dkimverify verbose option so it works and add documentation, thanks to Uwe Kleine-König for the patch (Debian: #1075791), bump version to 1.1.9
This commit is contained in:
@@ -1,6 +1,10 @@
|
|||||||
|
UNRELEASED Version 1.1.9
|
||||||
|
- Fix dkimverify verbose option so it works and add documentation, thanks
|
||||||
|
to Uwe Kleine-König for the patch (Debian: #1075791)
|
||||||
|
|
||||||
2024-07-04 Version 1.1.8
|
2024-07-04 Version 1.1.8
|
||||||
- Correctly handle verification of signatures without t= (timestamp) and
|
- Correctly handle verification of signatures without t= (timestamp) and
|
||||||
with x= (expiration); both are optional (LP: 2071892)
|
with x= (expiration); both are optional (LP: #2071892)
|
||||||
|
|
||||||
2024-06-23 Version 1.1.7
|
2024-06-23 Version 1.1.7
|
||||||
- Fix error in validate_signature_fields which prevented signature
|
- Fix error in validate_signature_fields which prevented signature
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ https://tools.ietf.org/html/rfc6376
|
|||||||
|
|
||||||
# VERSION
|
# VERSION
|
||||||
|
|
||||||
This is dkimpy 1.1.8.
|
This is dkimpy 1.1.9.
|
||||||
|
|
||||||
# REQUIREMENTS
|
# REQUIREMENTS
|
||||||
|
|
||||||
|
|||||||
+4
-1
@@ -34,15 +34,18 @@ def main():
|
|||||||
epilog="message to be verified follows commands on stdin")
|
epilog="message to be verified follows commands on stdin")
|
||||||
parser.add_argument('--index', metavar='N', type=int, default=0,
|
parser.add_argument('--index', metavar='N', type=int, default=0,
|
||||||
help='Index of DKIM signature header to verify: default=0')
|
help='Index of DKIM signature header to verify: default=0')
|
||||||
|
parser.add_argument('-v', '--verbose', default=False, action='store_true',
|
||||||
|
help='Add some debugging output')
|
||||||
args=parser.parse_args()
|
args=parser.parse_args()
|
||||||
if sys.version_info[0] >= 3:
|
if sys.version_info[0] >= 3:
|
||||||
# Make sys.stdin a binary stream.
|
# Make sys.stdin a binary stream.
|
||||||
sys.stdin = sys.stdin.detach()
|
sys.stdin = sys.stdin.detach()
|
||||||
|
|
||||||
message = sys.stdin.read()
|
message = sys.stdin.read()
|
||||||
verbose = '-v' in sys.argv
|
verbose = args.verbose
|
||||||
if verbose:
|
if verbose:
|
||||||
import logging
|
import logging
|
||||||
|
logging.basicConfig(level=logging.DEBUG)
|
||||||
d = dkim.DKIM(message, logger=logging)
|
d = dkim.DKIM(message, logger=logging)
|
||||||
else:
|
else:
|
||||||
d = dkim.DKIM(message)
|
d = dkim.DKIM(message)
|
||||||
|
|||||||
+2
-1
@@ -142,11 +142,12 @@ code 0 if the signature verifies successfully. Otherwise, it returns with exit
|
|||||||
code 1.
|
code 1.
|
||||||
|
|
||||||
.SH "USAGE"
|
.SH "USAGE"
|
||||||
usage: dkimverify.py [\-h] [\-\-index N] <message
|
usage: dkimverify.py [\-h] [\-\-index N] [\-\-verbose] <message
|
||||||
|
|
||||||
optional arguments:
|
optional arguments:
|
||||||
\-h, \-\-help show this help message and exit
|
\-h, \-\-help show this help message and exit
|
||||||
\-\-index N Index of DKIM signature header to verify: default=0
|
\-\-index N Index of DKIM signature header to verify: default=0
|
||||||
|
\-\-verbose Emit diagnostic output
|
||||||
|
|
||||||
.SH "AUTHORS"
|
.SH "AUTHORS"
|
||||||
This version of \fBdkimverify\fR was written by Greg Hewgill <greg@hewgill.com>.
|
This version of \fBdkimverify\fR was written by Greg Hewgill <greg@hewgill.com>.
|
||||||
|
|||||||
Reference in New Issue
Block a user