diff options
author | Junio C Hamano <gitster@pobox.com> | 2014-08-19 13:18:07 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-09-15 13:23:20 -0700 |
commit | d7c67668fe10184736bdfe953ed8dcbfdb57e0c2 (patch) | |
tree | f155fb3d22e7489047a661f16bf22a6da708d6cc /gpg-interface.h | |
parent | a50e7ca3215492b16d96221cf762dbe71ed99722 (diff) | |
download | git-d7c67668fe10184736bdfe953ed8dcbfdb57e0c2.tar.gz |
gpg-interface: move parse_signature() to where it should be
Our signed-tag objects set the standard format used by Git to store
GPG-signed payload (i.e. the payload followed by its detached
signature) [*1*], and it made sense to have a helper to find the
boundary between the payload and its signature in tag.c back then.
Newer code added later to parse other kinds of objects that learned
to use the same format to store GPG-signed payload (e.g. signed
commits), however, kept using the helper from the same location.
Move it to gpg-interface; the helper is no longer about signed tag,
but it is how our code and data interact with GPG.
[Reference]
*1* http://thread.gmane.org/gmane.linux.kernel/297998/focus=1383
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'gpg-interface.h')
-rw-r--r-- | gpg-interface.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gpg-interface.h b/gpg-interface.h index 82493b780f..87a4f2e3fa 100644 --- a/gpg-interface.h +++ b/gpg-interface.h @@ -20,6 +20,7 @@ struct signature_check { }; extern void signature_check_clear(struct signature_check *sigc); +extern size_t parse_signature(const char *buf, unsigned long size); extern void parse_gpg_output(struct signature_check *); extern int sign_buffer(struct strbuf *buffer, struct strbuf *signature, const char *signing_key); extern int verify_signed_buffer(const char *payload, size_t payload_size, const char *signature, size_t signature_size, struct strbuf *gpg_output, struct strbuf *gpg_status); |