Re: [PATCH] t/t5534: do not unset GIT_COMMITTER_EMAIL for other tests

2018-07-20 Thread Henning Schild
Am Thu, 19 Jul 2018 15:27:56 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Looking at "what is cooking" i assume i should not add/fold this > > to/in the serien anymore. So it comes as a separate patch on top. > > Thanks. I only said: >

[PATCH v6 7/7] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-20 Thread Henning Schild
). Several of the testcases build on top of existing gpg testcases. The commit ships a self-signed key for commit...@example.com and configures gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 28 +++- t/lib-gpg/gpgsm-gen-key.in | 8 ++ t

Re: [PATCH] t/t5534: do not unset GIT_COMMITTER_EMAIL for other tests

2018-07-19 Thread Henning Schild
Looking at "what is cooking" i assume i should not add/fold this to/in the serien anymore. So it comes as a separate patch on top. Henning Am Thu, 19 Jul 2018 14:14:09 +0200 schrieb Henning Schild : > Unsetting the varibale for good can have unwanted effects for new > tests add

[PATCH] t/t5534: do not unset GIT_COMMITTER_EMAIL for other tests

2018-07-19 Thread Henning Schild
ing test_config just like GPGSM. Signed-off-by: Henning Schild --- t/t5534-push-signed.sh | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/t/t5534-push-signed.sh b/t/t5534-push-signed.sh index 0cb88aa6f..f6d674156 100755 --- a/t/t5534-push-signed.sh +++ b/t/

Re: [PATCH v4 7/7] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-18 Thread Henning Schild
Am Tue, 17 Jul 2018 14:31:36 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > diff --git a/t/lib-gpg.sh b/t/lib-gpg.sh > > index a5d3b2cba..3fe02876c 100755 > > --- a/t/lib-gpg.sh > > +++ b/t/lib-gpg.sh > > @@ -38,7 +38,33 @@ then > >

Re: [PATCH v4 2/7] t/t7510: check the validation of the new config gpg.format

2018-07-18 Thread Henning Schild
Am Tue, 17 Jul 2018 14:31:56 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Test setting gpg.format to both invalid and valid values. > > > > Signed-off-by: Henning Schild > > --- > > t/t7510-signed-commit.sh | 9 + > > 1 file c

[PATCH v5 7/7] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-18 Thread Henning Schild
). Several of the testcases build on top of existing gpg testcases. The commit ships a self-signed key for commit...@example.com and configures gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 28 - t/lib-gpg/gpgsm-gen-key.in | 8

[PATCH v5 2/7] t/t7510: check the validation of the new config gpg.format

2018-07-18 Thread Henning Schild
Test setting gpg.format to both invalid and valid values. Signed-off-by: Henning Schild --- t/t7510-signed-commit.sh | 7 +++ 1 file changed, 7 insertions(+) diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh index 6e2015ed9..4e37ff8f1 100755 --- a/t/t7510-signed-commit.sh

[PATCH v4 6/7] gpg-interface: introduce new signature format "x509" using gpgsm

2018-07-17 Thread Henning Schild
This commit allows git to create and check x509 type signatures using gpgsm. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 +++-- gpg-interface.c | 15 +++ 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/Documentation/config.txt b

[PATCH v4 7/7] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-17 Thread Henning Schild
). Several of the testcases build on top of existing gpg testcases. The commit ships a self-signed key for commit...@example.com and configures gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 28 +++- t/lib-gpg/gpgsm-gen-key.in | 8

[PATCH v4 3/7] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-17 Thread Henning Schild
Create a struct that holds the format details for the supported formats. At the moment that is still just "openpgp". This commit prepares for the introduction of more formats, that might use other programs and match other signatures. Signed-off-by: Henning Schild --- gpg-interf

Re: [PATCH v3 1/7] gpg-interface: add new config to select how to sign a commit

2018-07-17 Thread Henning Schild
Am Mon, 16 Jul 2018 13:14:34 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Add "gpg.format" where the user can specify which type of signature > > to use for commits. At the moment only "openpgp" is supported and > > the value is n

[PATCH v4 1/7] gpg-interface: add new config to select how to sign a commit

2018-07-17 Thread Henning Schild
Add "gpg.format" where the user can specify which type of signature to use for commits. At the moment only "openpgp" is supported and the value is not even used. This commit prepares for a new types of signatures. Signed-off-by: Henning Schild --- Documentation/confi

[PATCH v4 5/7] gpg-interface: introduce new config to select per gpg format program

2018-07-17 Thread Henning Schild
Supporting multiple signing formats we will have the need to configure a custom program each. Add a new config value to cater for that. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 + gpg-interface.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff

[PATCH v4 0/7] X509 (gpgsm) commit signing support

2018-07-17 Thread Henning Schild
ries aimed at being generic for any sort of signing tool, while this series just introduced the X509 variant of gpg. (gpgsm) I collected authors and reviewers of that first series and already put them on cc. [1] https://public-inbox.org/git/20180409204129.43537-1-mastahy...@gmail.com/ Henning Sc

Re: [PATCH v3 5/7] gpg-interface: introduce new config to select per gpg format program

2018-07-17 Thread Henning Schild
Am Mon, 16 Jul 2018 13:45:40 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > +gpg..program:: > > + Use this to customize the program used for the signing > > format you > > + chose. (see gpg.program) gpg.openpgp.program is a synonym > >

[PATCH v4 4/7] gpg-interface: do not hardcode the key string len anymore

2018-07-17 Thread Henning Schild
will be ignored now, before we jumped to found+17 which might have been behind the end of an unexpected string. Signed-off-by: Henning Schild --- gpg-interface.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gpg-interface.c b/gpg-interface.c index a02db7658..51cad9081

[PATCH v4 2/7] t/t7510: check the validation of the new config gpg.format

2018-07-17 Thread Henning Schild
Test setting gpg.format to both invalid and valid values. Signed-off-by: Henning Schild --- t/t7510-signed-commit.sh | 9 + 1 file changed, 9 insertions(+) diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh index 6e2015ed9..7bdad570c 100755 --- a/t/t7510-signed-commit.sh

Re: [PATCH v3 3/7] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-17 Thread Henning Schild
Am Mon, 16 Jul 2018 13:40:32 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Create a struct that holds the format details for the supported > > formats. At the moment that is still just "openpgp". This commit > > prepares for the introduction of

[PATCH v3 5/7] gpg-interface: introduce new config to select per gpg format program

2018-07-13 Thread Henning Schild
Supporting multiple signing formats we will have the need to configure a custom program each. Add a new config value to cater for that. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 + gpg-interface.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff

[PATCH v3 6/7] gpg-interface: introduce new signature format "x509" using gpgsm

2018-07-13 Thread Henning Schild
This commit allows git to create and check x509 type signatures using gpgsm. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 +++-- gpg-interface.c | 9 + 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/Documentation/config.txt b/Documentation

[PATCH v3 3/7] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-13 Thread Henning Schild
Create a struct that holds the format details for the supported formats. At the moment that is still just "openpgp". This commit prepares for the introduction of more formats, that might use other programs and match other signatures. Signed-off-by: Henning Schild --- gpg-interf

[PATCH v3 4/7] gpg-interface: do not hardcode the key string len anymore

2018-07-13 Thread Henning Schild
will be ignored now, before we jumped to found+17 which might have been behind the end of an unexpected string. Signed-off-by: Henning Schild --- gpg-interface.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gpg-interface.c b/gpg-interface.c index 699651fd9..93bd0fb32

[PATCH v3 0/7] X509 (gpgsm) commit signing support

2018-07-13 Thread Henning Schild
of gpg. (gpgsm) I collected authors and reviewers of that first series and already put them on cc. [1] https://public-inbox.org/git/20180409204129.43537-1-mastahy...@gmail.com/ Henning Schild (7): gpg-interface: add new config to select how to sign a commit t/t7510: check the validation of the

[PATCH v3 7/7] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-13 Thread Henning Schild
). Several of the testcases build on top of existing gpg testcases. The commit ships a self-signed key for commit...@example.com and configures gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 28 +++- t/lib-gpg/gpgsm-gen-key.in | 8

Re: [PATCH v2 5/9] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-13 Thread Henning Schild
Am Tue, 10 Jul 2018 12:23:32 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:27AM +0200, Henning Schild wrote: > > > Create a struct that holds the format details for the supported > > formats. At the moment that is still just "openpgp". This commit >

[PATCH v3 1/7] gpg-interface: add new config to select how to sign a commit

2018-07-13 Thread Henning Schild
Add "gpg.format" where the user can specify which type of signature to use for commits. At the moment only "openpgp" is supported and the value is not even used. This commit prepares for a new types of signatures. Signed-off-by: Henning Schild --- Documentation/conf

[PATCH v3 2/7] t/t7510: check the validation of the new config gpg.format

2018-07-13 Thread Henning Schild
Test setting gpg.format to both invalid and valid values. Signed-off-by: Henning Schild --- t/t7510-signed-commit.sh | 9 + 1 file changed, 9 insertions(+) diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh index 6e2015ed9..1b6a1dd90 100755 --- a/t/t7510-signed-commit.sh

Re: [PATCH v2 7/9] gpg-interface: introduce new config to select per gpg format program

2018-07-13 Thread Henning Schild
Replies to this one have been ignored for v3. I do not know how to proceed here. Henning Am Tue, 10 Jul 2018 10:52:29 +0200 schrieb Henning Schild : > Supporting multiple signing formats we will have the need to > configure a custom program each. Add a new config value to

Re: [PATCH v2 5/9] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-13 Thread Henning Schild
Am Tue, 10 Jul 2018 10:16:39 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Create a struct that holds the format details for the supported > > formats. At the moment that is still just "openpgp". This commit > > prepares for the introduction of

Re: [PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-11 Thread Henning Schild
Am Wed, 11 Jul 2018 10:33:52 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:31AM +0200, Henning Schild wrote: > > > diff --git a/t/lib-gpg.sh b/t/lib-gpg.sh > > index a5d3b2cba..9dcb4e990 100755 > > --- a/t/lib-gpg.sh > > +++ b/t/

Re: [PATCH v2 6/9] gpg-interface: do not hardcode the key string len anymore

2018-07-11 Thread Henning Schild
Am Wed, 11 Jul 2018 10:27:52 -0400 schrieb Jeff King : > On Wed, Jul 11, 2018 at 03:46:19PM +0200, Henning Schild wrote: > > > > I think it's worth addressing in the near term, if only because > > > this kind of off-by-one is quite subtle, and I don't want

Re: [PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-11 Thread Henning Schild
Am Wed, 11 Jul 2018 10:35:54 -0400 schrieb Jeff King : > On Wed, Jul 11, 2018 at 03:40:19PM +0200, Henning Schild wrote: > > > > So it may be simplest to just run most of the tests twice, once > > > with gpg and once with gpgsm. I kind of wonder if all of t7510 &g

Re: [PATCH v2 6/9] gpg-interface: do not hardcode the key string len anymore

2018-07-11 Thread Henning Schild
Am Wed, 11 Jul 2018 08:34:25 -0400 schrieb Jeff King : > On Wed, Jul 11, 2018 at 10:54:59AM +0200, Henning Schild wrote: > > > > In the general case you need: > > > > > > found = *next ? next + 1 : next; > > > > > > or similar. In this cas

Re: [PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-11 Thread Henning Schild
Am Wed, 11 Jul 2018 08:51:10 -0400 schrieb Jeff King : > On Wed, Jul 11, 2018 at 12:38:24PM +0200, Henning Schild wrote: > > > > Can we save a dummy generated key and just import it? That's what > > > we do for the regular gpg case. > > > > I will look int

Re: [PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 14:12:57 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Add test cases to cover the new X509/gpgsm support. Most of them > > resemble existing ones. They just switch the format to x509 and set > > the signingkey when creatin

Re: [PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 13:09:01 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:31AM +0200, Henning Schild wrote: > > > diff --git a/t/lib-gpg.sh b/t/lib-gpg.sh > > index a5d3b2cba..9dcb4e990 100755 > > --- a/t/lib-gpg.sh > > +++ b/t/

Re: [PATCH v2 8/9] gpg-interface: introduce new signature format "x509" using gpgsm

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 13:01:10 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:30AM +0200, Henning Schild wrote: > > > diff --git a/Documentation/config.txt b/Documentation/config.txt > > index c0bd80954..b6f9b47d5 100644 > > --- a/Documentation/config.txt

Re: [PATCH v2 6/9] gpg-interface: do not hardcode the key string len anymore

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 11:49:31 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:28AM +0200, Henning Schild wrote: > > > gnupg does print the keyid followed by a space and the signer comes > > next. The same pattern is also used in gpgsm, but there the key > > le

Re: [PATCH v2 4/9] t/t7510: check the validation of the new config gpg.format

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 09:54:59 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Test setting gpg.format to both invalid and valid values. > > > > Signed-off-by: Henning Schild > > --- > > t/t7510-signed-commit.sh | 10 ++ > > 1 f

Re: [PATCH v2 2/9] gpg-interface: make parse_gpg_output static and remove from interface header

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 09:47:26 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > This commit turns parse_gpg_output into an internal function, the > > only outside user was migrated in an earlier commit. > > It is not too big a deal but as we prefer

[PATCH 2/2] gpg-interface: make parse_gpg_output static and remove from interface header

2018-07-11 Thread Henning Schild
Turn parse_gpg_output into a static function, the only outside user was migrated in an earlier commit. Signed-off-by: Henning Schild --- gpg-interface.c | 2 +- gpg-interface.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/gpg-interface.c b/gpg-interface.c index

[PATCH 1/2] builtin/receive-pack: use check_signature from gpg-interface

2018-07-11 Thread Henning Schild
The combination of verify_signed_buffer followed by parse_gpg_output is available as check_signature. Use that instead of implementing it again. Signed-off-by: Henning Schild --- builtin/receive-pack.c | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git

Re: [PATCH v2 4/9] t/t7510: check the validation of the new config gpg.format

2018-07-11 Thread Henning Schild
Am Tue, 10 Jul 2018 11:55:36 -0400 schrieb Jeff King : > On Tue, Jul 10, 2018 at 10:52:26AM +0200, Henning Schild wrote: > > > diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh > > index 6e2015ed9..7e1e9caf4 100755 > > --- a/t/t7510-signed-commit.sh

[PATCH v2 3/9] gpg-interface: add new config to select how to sign a commit

2018-07-10 Thread Henning Schild
Add "gpg.format" where the user can specify which type of signature to use for commits. At the moment only "openpgp" is supported and the value is not even used. This commit prepares for a new types of signatures. Signed-off-by: Henning Schild --- Documentation/conf

[PATCH v2 9/9] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-10 Thread Henning Schild
). We generate a self-signed key for commit...@example.com and configure gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 9 ++- t/lib-gpg/gpgsm-gen-key.in | 6 + t/t4202-log.sh | 66 ++ t/t5534

[PATCH v2 2/9] gpg-interface: make parse_gpg_output static and remove from interface header

2018-07-10 Thread Henning Schild
This commit turns parse_gpg_output into an internal function, the only outside user was migrated in an earlier commit. Signed-off-by: Henning Schild --- gpg-interface.c | 2 +- gpg-interface.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/gpg-interface.c b/gpg

[PATCH v2 5/9] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-10 Thread Henning Schild
Create a struct that holds the format details for the supported formats. At the moment that is still just "openpgp". This commit prepares for the introduction of more formats, that might use other programs and match other signatures. Signed-off-by: Henning Schild --- gpg-interf

[PATCH v2 4/9] t/t7510: check the validation of the new config gpg.format

2018-07-10 Thread Henning Schild
Test setting gpg.format to both invalid and valid values. Signed-off-by: Henning Schild --- t/t7510-signed-commit.sh | 10 ++ 1 file changed, 10 insertions(+) diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh index 6e2015ed9..7e1e9caf4 100755 --- a/t/t7510-signed

[PATCH v2 1/9] builtin/receive-pack: use check_signature from gpg-interface

2018-07-10 Thread Henning Schild
The combination of verify_signed_buffer followed by parse_gpg_output is available as check_signature. Use that instead of implementing it again. Signed-off-by: Henning Schild --- builtin/receive-pack.c | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git

[PATCH v2 0/9] X509 (gpgsm) commit signing support

2018-07-10 Thread Henning Schild
ile this series just introduced the X509 variant of gpg. (gpgsm) I collected authors and reviewers of that first series and already put them on cc. [1] https://public-inbox.org/git/20180409204129.43537-1-mastahy...@gmail.com/ Henning Schild (9): builtin/receive-pack: use check_signature

[PATCH v2 8/9] gpg-interface: introduce new signature format "x509" using gpgsm

2018-07-10 Thread Henning Schild
This commit allows git to create and check x509 type signatures using gpgsm. Signed-off-by: Henning Schild --- Documentation/config.txt | 2 +- gpg-interface.c | 10 +- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Documentation/config.txt b/Documentation

[PATCH v2 7/9] gpg-interface: introduce new config to select per gpg format program

2018-07-10 Thread Henning Schild
Supporting multiple signing formats we will have the need to configure a custom program each. Add a new config value to cater for that. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 + gpg-interface.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff

Re: [PATCH 5/8] t/t7510: check the validation of the new config gpg.format

2018-07-09 Thread Henning Schild
Am Fri, 6 Jul 2018 13:21:10 -0700 schrieb Junio C Hamano : > Henning Schild writes: > > > Valid values are already covered by all tests that use GPG, now also > > test what happens if we go for an invalid one. > > > > Signed-off-by: Henning Schild > > --

Re: [PATCH 4/8] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-09 Thread Henning Schild
Am Fri, 6 Jul 2018 10:24:58 -0700 schrieb Junio C Hamano : > Martin Ågren writes: > > >> +enum gpgformats { PGP_FMT }; > >> +struct gpg_format_data gpg_formats[] = { > >> + { .format = "PGP", .program = "gpg", > >> + .extra_args_verify = { "--keyid-format=long", }, > >> +

Re: [PATCH 1/8] builtin/receive-pack: use check_signature from gpg-interface

2018-07-09 Thread Henning Schild
Am Fri, 6 Jul 2018 14:35:29 -0700 schrieb Junio C Hamano : > Junio C Hamano writes: > > > Henning Schild writes: > > > >> The combination of verify_signed_buffer followed by > >> parse_gpg_output is available as check_signature. Use that i

Re: [PATCH 3/8] gpg-interface: add new config to select how to sign a commit

2018-07-06 Thread Henning Schild
Am Fri, 6 Jul 2018 01:01:48 + schrieb "brian m. carlson" : > On Tue, Jul 03, 2018 at 02:38:15PM +0200, Henning Schild wrote: > > Add "gpg.format" where the user can specify which type of signature > > to use for commits. At the moment only "PGP" is

Re: [PATCH 8/8] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-06 Thread Henning Schild
Am Fri, 6 Jul 2018 01:14:47 + schrieb "brian m. carlson" : > On Tue, Jul 03, 2018 at 02:38:20PM +0200, Henning Schild wrote: > > Add test cases to cover the new X509/gpgsm support. Most of them > > resemble existing ones. They just switch the format to X509 and se

Re: [PATCH 0/8] X509 (gpgsm) commit signing support

2018-07-06 Thread Henning Schild
Am Fri, 6 Jul 2018 01:18:35 + schrieb "brian m. carlson" : > On Tue, Jul 03, 2018 at 02:38:12PM +0200, Henning Schild wrote: > > This series adds support for signing commits with gpgsm. > > > > The first two patches are cleanups of gpg-interface,

Re: [PATCH 7/8] gpg-interface: introduce new signature format "X509" using gpgsm

2018-07-06 Thread Henning Schild
Am Fri, 6 Jul 2018 01:10:13 + schrieb "brian m. carlson" : > On Tue, Jul 03, 2018 at 02:38:19PM +0200, Henning Schild wrote: > > This commit allows git to create and check X509 type signatures > > using gpgsm. > > > > Signed-off-by: Henning Schild >

Re: [PATCH 4/8] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-05 Thread Henning Schild
Am Wed, 4 Jul 2018 09:10:17 +0200 schrieb Martin Ågren : > Hi Henning, > > On 3 July 2018 at 14:38, Henning Schild > wrote: > > Create a struct that holds the format details for the supported > > formats. At the moment that is still just "PGP". This commit

[PATCH 8/8] gpg-interface t: extend the existing GPG tests with GPGSM

2018-07-03 Thread Henning Schild
). We generate a self-signed key for commit...@example.com and configure gpgsm to trust it. Signed-off-by: Henning Schild --- t/lib-gpg.sh | 9 ++- t/lib-gpg/gpgsm-gen-key.in | 6 + t/t4202-log.sh | 66 ++ t/t5534

[PATCH 4/8] gpg-interface: introduce an abstraction for multiple gpg formats

2018-07-03 Thread Henning Schild
Create a struct that holds the format details for the supported formats. At the moment that is still just "PGP". This commit prepares for the introduction of more formats, that might use other programs and match other signatures. Signed-off-by: Henning Schild --- gpg-interf

[PATCH 3/8] gpg-interface: add new config to select how to sign a commit

2018-07-03 Thread Henning Schild
Add "gpg.format" where the user can specify which type of signature to use for commits. At the moment only "PGP" is supported and the value is not even used. This commit prepares for a new types of signatures. Signed-off-by: Henning Schild --- Documentation/config.txt | 4 +

[PATCH 7/8] gpg-interface: introduce new signature format "X509" using gpgsm

2018-07-03 Thread Henning Schild
This commit allows git to create and check X509 type signatures using gpgsm. Signed-off-by: Henning Schild --- Documentation/config.txt | 5 - gpg-interface.c | 10 +- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/Documentation/config.txt b/Documentation

[PATCH 6/8] gpg-interface: do not hardcode the key string len anymore

2018-07-03 Thread Henning Schild
gnupg does print the keyid followed by a space and the signer comes next. The same pattern is also used in gpgsm, but there the key length would be 40 instead of 16. Instead of hardcoding the expected length, find the first space and calculate it. Signed-off-by: Henning Schild --- gpg

[PATCH 1/8] builtin/receive-pack: use check_signature from gpg-interface

2018-07-03 Thread Henning Schild
The combination of verify_signed_buffer followed by parse_gpg_output is available as check_signature. Use that instead of implementing it again. Signed-off-by: Henning Schild --- builtin/receive-pack.c | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git

[PATCH 2/8] gpg-interface: make parse_gpg_output static and remove from interface header

2018-07-03 Thread Henning Schild
This commit turns parse_gpg_output into an internal function, the only outside user was migrated in an earlier commit. Signed-off-by: Henning Schild --- gpg-interface.c | 2 +- gpg-interface.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/gpg-interface.c b/gpg

[PATCH 5/8] t/t7510: check the validation of the new config gpg.format

2018-07-03 Thread Henning Schild
Valid values are already covered by all tests that use GPG, now also test what happens if we go for an invalid one. Signed-off-by: Henning Schild --- t/t7510-signed-commit.sh | 10 ++ 1 file changed, 10 insertions(+) diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh

[PATCH 0/8] X509 (gpgsm) commit signing support

2018-07-03 Thread Henning Schild
ant of gpg. (gpgsm) I collected authors and reviewers of that first series and already put them on cc. [1] https://public-inbox.org/git/20180409204129.43537-1-mastahy...@gmail.com/ Henning Schild (8): builtin/receive-pack: use check_signature from gpg-interface gpg-interface: make parse_gpg_out