[git] GnuPG - branch, master, updated. post-nuke-of-trailing-ws-149-g14e4fdc
by Werner Koch
cvs at cvs.gnupg.org
Wed Dec 7 11:59:22 CET 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".
The branch, master has been updated
via 14e4fdc9f97d6f12bf563adfff1e3157305d7795 (commit)
via cd3732841de32ce5c7841e6e158df3a5f1102f86 (commit)
via 596b84a4de58def2155d3fe56462f6607f135b69 (commit)
from 5cdad8ff000152b4bd01953646bb87fe8703c70d (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 14e4fdc9f97d6f12bf563adfff1e3157305d7795
Author: Werner Koch <wk at gnupg.org>
Date: Wed Dec 7 11:07:21 2011 +0100
Correct punctuation in the ChangeLog summary line.
* Makefile.am (gen-ChangeLog): Supply --append-dot.
diff --git a/Makefile.am b/Makefile.am
index 292748a..5f9bf2e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -116,6 +116,7 @@ gen-ChangeLog:
if test -d $(top_srcdir)/.git; then \
(cd $(top_srcdir) && \
./scripts/gitlog-to-changelog \
+ --append-dot \
--amend=scripts/git-log-fix \
--since=$(gen_start_date) ) > $(distdir)/cl-t; \
cat $(top_srcdir)/scripts/git-log-footer >> $(distdir)/cl-t; \
commit cd3732841de32ce5c7841e6e158df3a5f1102f86
Author: Werner Koch <wk at gnupg.org>
Date: Wed Dec 7 11:01:39 2011 +0100
Allow comments which will not show up in the ChangeLog
* scripts/gitlog-to-changelog: Ignore lines after a "--" line.
--
The first line with two dashes at the start of a line (optionally
followed by white space) stops copying the commit log lines to the
ChangeLog entry in "make dist". This is useful to allow adding
comments to the log which are not useful in a ChangeLog.
diff --git a/scripts/gitlog-to-changelog b/scripts/gitlog-to-changelog
index 40a8035..a7ea194 100755
--- a/scripts/gitlog-to-changelog
+++ b/scripts/gitlog-to-changelog
@@ -281,6 +281,15 @@ sub parse_amend_file($)
@line = grep !/^Signed-off-by: .*>$/, @line;
@line = grep !/^Co-authored-by: /, @line;
+ # Remove everything after a line with 2 dashes at the beginning.
+ my @tmpline;
+ foreach (@line)
+ {
+ last if /^--\s*$/;
+ push @tmpline,$_;
+ }
+ @line = @tmpline;
+
# Remove leading and trailing blank lines.
if (@line)
{
commit 596b84a4de58def2155d3fe56462f6607f135b69
Author: Werner Koch <wk at gnupg.org>
Date: Tue Dec 6 21:43:18 2011 +0100
gpgsm: Allow specification of an AuthorityKeyIdentifier.
* sm/certreqgen.c (pAUTHKEYID): New.
(read_parameters): Add keyword Authority-Key-Id.
(proc_parameters): Check its value.
(create_request): Insert an Authority-Key-Id.
diff --git a/sm/certreqgen.c b/sm/certreqgen.c
index 15fc7a2..de7c39c 100644
--- a/sm/certreqgen.c
+++ b/sm/certreqgen.c
@@ -85,6 +85,7 @@ enum para_name
pNOTAFTER,
pSIGNINGKEY,
pHASHALGO,
+ pAUTHKEYID,
pSUBJKEYID,
pEXTENSION
};
@@ -107,6 +108,7 @@ struct reqgen_ctrl_s
};
+static const char oidstr_authorityKeyIdentifier[] = "2.5.29.35";
static const char oidstr_subjectKeyIdentifier[] = "2.5.29.14";
static const char oidstr_keyUsage[] = "2.5.29.15";
static const char oidstr_basicConstraints[] = "2.5.29.19";
@@ -247,6 +249,7 @@ read_parameters (ctrl_t ctrl, estream_t fp, estream_t out_fp)
{ "Not-After", pNOTAFTER },
{ "Signing-Key", pSIGNINGKEY },
{ "Hash-Algo", pHASHALGO },
+ { "Authority-Key-Id", pAUTHKEYID },
{ "Subject-Key-Id", pSUBJKEYID },
{ "Extension", pEXTENSION, 1 },
{ NULL, 0 }
@@ -618,6 +621,21 @@ proc_parameters (ctrl_t ctrl, struct para_data_s *para,
}
}
+ /* Check the optional AuthorityKeyId. */
+ string = get_parameter_value (para, pAUTHKEYID, 0);
+ if (string)
+ {
+ for (s=string, i=0; hexdigitp (s); s++, i++)
+ ;
+ if (*s || (i&1))
+ {
+ r = get_parameter (para, pAUTHKEYID, 0);
+ log_error (_("line %d: invalid authority-key-id\n"), r->lnr);
+ xfree (cardkeyid);
+ return gpg_error (GPG_ERR_INV_PARAMETER);
+ }
+ }
+
/* Check the optional SubjectKeyId. */
string = get_parameter_value (para, pSUBJKEYID, 0);
if (string)
@@ -1095,6 +1113,44 @@ create_request (ctrl_t ctrl,
}
}
+ /* Insert the AuthorityKeyId. */
+ string = get_parameter_value (para, pAUTHKEYID, 0);
+ if (string)
+ {
+ char *hexbuf;
+
+ /* Allocate a buffer for in-place conversion. We also add 4
+ extra bytes space for the tags and lengths fields. */
+ hexbuf = xtrymalloc (4 + strlen (string) + 1);
+ if (!hexbuf)
+ {
+ err = gpg_error_from_syserror ();
+ goto leave;
+ }
+ strcpy (hexbuf+4, string);
+ for (p=hexbuf+4, len=0; p[0] && p[1]; p += 2)
+ ((unsigned char*)hexbuf)[4+len++] = xtoi_2 (p);
+ if (len > 125)
+ {
+ err = gpg_error (GPG_ERR_TOO_LARGE);
+ xfree (hexbuf);
+ goto leave;
+ }
+ hexbuf[0] = 0x30; /* Tag for a Sequence. */
+ hexbuf[1] = len+2;
+ hexbuf[2] = 0x80; /* Context tag for an implicit Octet string. */
+ hexbuf[3] = len;
+ err = ksba_certreq_add_extension (cr, oidstr_authorityKeyIdentifier,
+ 0,
+ hexbuf, 4+len);
+ xfree (hexbuf);
+ if (err)
+ {
+ log_error ("error setting the authority-key-id: %s\n",
+ gpg_strerror (err));
+ goto leave;
+ }
+ }
/* Insert the SubjectKeyId. */
string = get_parameter_value (para, pSUBJKEYID, 0);
-----------------------------------------------------------------------
Summary of changes:
Makefile.am | 1 +
scripts/gitlog-to-changelog | 9 +++++++
sm/certreqgen.c | 56 +++++++++++++++++++++++++++++++++++++++++++
3 files changed, 66 insertions(+), 0 deletions(-)
hooks/post-receive
--
The GNU Privacy Guard
http://git.gnupg.org
More information about the Gnupg-commits
mailing list