path: root/gpg-interface.h
diff options
authorbrian m. carlson <>2015-06-21 23:14:38 (GMT)
committerJunio C Hamano <>2015-06-22 21:20:45 (GMT)
commita4cc18f2934b8d2f00c7c3e11107acb6bfafe2c6 (patch)
treed01e654e36d66e2abfb3513d9c716be752a22451 /gpg-interface.h
parentd66aeff21e8ce92d742aa04c5e59ca3eee5e39d8 (diff)
verify-tag: share code with verify-commit
verify-tag was executing an entirely different codepath than verify-commit, except for the underlying verify_signed_buffer. Move much of the code from check_commit_signature to a generic check_signature function and adjust both codepaths to call it. Update verify-tag to explicitly output the signature text, as we now call verify_signed_buffer with strbufs to catch the output, which prevents it from being printed automatically. Signed-off-by: brian m. carlson <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'gpg-interface.h')
1 files changed, 2 insertions, 0 deletions
diff --git a/gpg-interface.h b/gpg-interface.h
index 87a4f2e..043bcaa 100644
--- a/gpg-interface.h
+++ b/gpg-interface.h
@@ -27,5 +27,7 @@ extern int verify_signed_buffer(const char *payload, size_t payload_size, const
extern int git_gpg_config(const char *, const char *, void *);
extern void set_signing_key(const char *);
extern const char *get_signing_key(void);
+extern void check_signature(const char *payload, size_t plen,
+ const char *signature, size_t slen, struct signature_check *sigc);