Skip to content

Commit

Permalink
ASCII armoring should not require the CRC line
Browse files Browse the repository at this point in the history
  • Loading branch information
dkg committed Nov 16, 2022
1 parent 23aac81 commit 8ad6e98
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pgpy/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ class Armorable(six.with_metaclass(abc.ABCMeta)):
# capture all lines of the body, up to 76 characters long,
# including the newline, and the pad character(s)
(?P<body>([A-Za-z0-9+/]{1,76}={,2}(?:\r?\n))+)
# capture the armored CRC24 value
^=(?P<crc>[A-Za-z0-9+/]{4})(?:\r?\n)
# optionally capture the armored CRC24 value
(?:^=(?P<crc>[A-Za-z0-9+/]{4})(?:\r?\n))?
# finally, capture the armor tail line, which must match the armor header line
^-{5}END\ PGP\ (?P=magic)-{5}(?:\r?\n)?
""", flags=re.MULTILINE | re.VERBOSE)
Expand Down

0 comments on commit 8ad6e98

Please sign in to comment.