aboutsummaryrefslogtreecommitdiff
path: root/gpg-interface.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-08-03 11:01:12 -0700
committerJunio C Hamano <gitster@pobox.com>2015-08-03 11:01:12 -0700
commitba12cb299f831f29c256c644b01108710c2629e6 (patch)
tree9887b1a34695488488f7ea86f9906c93e2164543 /gpg-interface.h
parente7cf4b257179b4683fa32beb51f949666d36fe9c (diff)
parente18443ece711564145d545b650851c4615717128 (diff)
downloadgit-ba12cb299f831f29c256c644b01108710c2629e6.tar.gz
git-ba12cb299f831f29c256c644b01108710c2629e6.tar.xz
Merge branch 'bc/gpg-verify-raw'
"git verify-tag" and "git verify-commit" have been taught to share more code, and then learned to optionally show the verification message from the underlying GPG implementation. * bc/gpg-verify-raw: verify-tag: add option to print raw gpg status information verify-commit: add option to print raw gpg status information gpg: centralize printing signature buffers gpg: centralize signature check verify-commit: add test for exit status on untrusted signature verify-tag: share code with verify-commit verify-tag: add tests
Diffstat (limited to 'gpg-interface.h')
-rw-r--r--gpg-interface.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/gpg-interface.h b/gpg-interface.h
index 87a4f2e3f..ea68885ad 100644
--- a/gpg-interface.h
+++ b/gpg-interface.h
@@ -1,6 +1,9 @@
#ifndef GPG_INTERFACE_H
#define GPG_INTERFACE_H
+#define GPG_VERIFY_VERBOSE 1
+#define GPG_VERIFY_RAW 2
+
struct signature_check {
char *payload;
char *gpg_output;
@@ -27,5 +30,8 @@ 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 int check_signature(const char *payload, size_t plen,
+ const char *signature, size_t slen, struct signature_check *sigc);
+void print_signature_buffer(const struct signature_check *sigc, unsigned flags);
#endif