summaryrefslogtreecommitdiffstats
path: root/openpgp/src/parse.rs
diff options
context:
space:
mode:
Diffstat (limited to 'openpgp/src/parse.rs')
-rw-r--r--openpgp/src/parse.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/openpgp/src/parse.rs b/openpgp/src/parse.rs
index d414cbe4..2dc9fad5 100644
--- a/openpgp/src/parse.rs
+++ b/openpgp/src/parse.rs
@@ -6491,4 +6491,15 @@ zXvj
-----END PGP SIGNATURE-----
");
}
+
+ /// Tests issue 957.
+ #[test]
+ fn panic_on_malformed_armor() {
+ parse_message("-----BEGIN PGP MESSAGE-----
+
+heLBX8Pq0kUBwQz2iFAzRwOdgTBvH5KsDU9lmE
+
+-----END PGP MESSAGE-----
+");
+ }
}