gnupg/g10 (ChangeLog export.c g10.c import.c options.h)
cvs user dshaw
cvs at cvs.gnupg.org
Fri Nov 26 16:44:41 CET 2004
Date: Friday, November 26, 2004 @ 16:51:37
Author: dshaw
Path: /cvs/gnupg/gnupg/g10
Modified: ChangeLog export.c g10.c import.c options.h
* options.h, export.c (parse_export_options, do_export_stream), import.c
(parse_import_options, import_keys_internal): Make the import-options and
export-options distinct since they can be mixed together as part of
keyserver-options.
-----------+
ChangeLog | 7 +++++++
export.c | 16 ++++++++++------
g10.c | 6 +++---
import.c | 12 +++++++-----
options.h | 10 +++++-----
5 files changed, 32 insertions(+), 19 deletions(-)
Index: gnupg/g10/ChangeLog
diff -u gnupg/g10/ChangeLog:1.643 gnupg/g10/ChangeLog:1.644
--- gnupg/g10/ChangeLog:1.643 Thu Nov 25 04:58:42 2004
+++ gnupg/g10/ChangeLog Fri Nov 26 16:51:37 2004
@@ -1,3 +1,10 @@
+2004-11-26 David Shaw <dshaw at jabberwocky.com>
+
+ * options.h, export.c (parse_export_options, do_export_stream),
+ import.c (parse_import_options, import_keys_internal): Make the
+ import-options and export-options distinct since they can be mixed
+ together as part of keyserver-options.
+
2004-11-24 David Shaw <dshaw at jabberwocky.com>
* options.h, export.c (parse_export_options, do_export_stream):
Index: gnupg/g10/export.c
diff -u gnupg/g10/export.c:1.42 gnupg/g10/export.c:1.43
--- gnupg/g10/export.c:1.42 Thu Nov 25 04:58:42 2004
+++ gnupg/g10/export.c Fri Nov 26 16:51:37 2004
@@ -45,10 +45,14 @@
{
struct parse_options export_opts[]=
{
- {"include-local-sigs",EXPORT_INCLUDE_LOCAL_SIGS,NULL},
- {"include-attributes",EXPORT_INCLUDE_ATTRIBUTES,NULL},
- {"include-sensitive-revkeys",EXPORT_INCLUDE_SENSITIVE_REVKEYS,NULL},
+ {"export-local-sigs",EXPORT_LOCAL_SIGS,NULL},
+ {"export-attributes",EXPORT_ATTRIBUTES,NULL},
+ {"export-sensitive-revkeys",EXPORT_SENSITIVE_REVKEYS,NULL},
{"export-minimal",EXPORT_MINIMAL,NULL},
+ /* Aliases for backward compatibility */
+ {"include-local-sigs",EXPORT_LOCAL_SIGS,NULL},
+ {"include-attributes",EXPORT_ATTRIBUTES,NULL},
+ {"include-sensitive-revkeys",EXPORT_SENSITIVE_REVKEYS,NULL},
{NULL,0,NULL}
/* add tags for include revoked and disabled? */
};
@@ -318,7 +322,7 @@
continue;
/* do not export packets which are marked as not exportable */
- if(!(options&EXPORT_INCLUDE_LOCAL_SIGS)
+ if(!(options&EXPORT_LOCAL_SIGS)
&& !node->pkt->pkt.signature->flags.exportable)
continue; /* not exportable */
@@ -326,7 +330,7 @@
key unless the user wants us to. Note that we do
export these when issuing the actual revocation
(see revoke.c). */
- if(!(options&EXPORT_INCLUDE_SENSITIVE_REVKEYS)
+ if(!(options&EXPORT_SENSITIVE_REVKEYS)
&& node->pkt->pkt.signature->revkey)
{
int i;
@@ -341,7 +345,7 @@
}
/* Don't export attribs? */
- if( !(options&EXPORT_INCLUDE_ATTRIBUTES) &&
+ if( !(options&EXPORT_ATTRIBUTES) &&
node->pkt->pkttype == PKT_USER_ID &&
node->pkt->pkt.user_id->attrib_data ) {
/* Skip until we get to something that is not an attrib
Index: gnupg/g10/g10.c
diff -u gnupg/g10/g10.c:1.289 gnupg/g10/g10.c:1.290
--- gnupg/g10/g10.c:1.289 Thu Nov 18 17:01:08 2004
+++ gnupg/g10/g10.c Fri Nov 26 16:51:37 2004
@@ -1655,9 +1655,9 @@
opt.force_v3_sigs = 1;
opt.escape_from = 1;
opt.import_options=IMPORT_SK2PK;
- opt.export_options=EXPORT_INCLUDE_ATTRIBUTES;
+ opt.export_options=EXPORT_ATTRIBUTES;
opt.keyserver_options.import_options=IMPORT_REPAIR_PKS_SUBKEY_BUG;
- opt.keyserver_options.export_options=EXPORT_INCLUDE_ATTRIBUTES;
+ opt.keyserver_options.export_options=EXPORT_ATTRIBUTES;
opt.keyserver_options.options=
KEYSERVER_INCLUDE_SUBKEYS|KEYSERVER_INCLUDE_REVOKED|KEYSERVER_TRY_DNS_SRV|KEYSERVER_HONOR_KEYSERVER_URL;
opt.verify_options=
@@ -3254,7 +3254,7 @@
break;
case aFastImport:
- opt.import_options |= IMPORT_FAST_IMPORT;
+ opt.import_options |= IMPORT_FAST;
case aImport:
import_keys( argc? argv:NULL, argc, NULL, opt.import_options );
break;
Index: gnupg/g10/import.c
diff -u gnupg/g10/import.c:1.116 gnupg/g10/import.c:1.117
--- gnupg/g10/import.c:1.116 Thu Oct 14 12:48:15 2004
+++ gnupg/g10/import.c Fri Nov 26 16:51:37 2004
@@ -88,12 +88,14 @@
{
struct parse_options import_opts[]=
{
- {"allow-local-sigs",IMPORT_ALLOW_LOCAL_SIGS,NULL},
- {"repair-hkp-subkey-bug",IMPORT_REPAIR_PKS_SUBKEY_BUG,NULL},
+ {"import-local-sigs",IMPORT_LOCAL_SIGS,NULL},
{"repair-pks-subkey-bug",IMPORT_REPAIR_PKS_SUBKEY_BUG,NULL},
- {"fast-import",IMPORT_FAST_IMPORT,NULL},
+ {"fast-import",IMPORT_FAST,NULL},
{"convert-sk-to-pk",IMPORT_SK2PK,NULL},
{"merge-only",IMPORT_MERGE_ONLY,NULL},
+ /* Aliases for backward compatibility */
+ {"allow-local-sigs",IMPORT_LOCAL_SIGS,NULL},
+ {"repair-hkp-subkey-bug",IMPORT_REPAIR_PKS_SUBKEY_BUG,NULL},
{NULL,0,NULL}
};
@@ -195,7 +197,7 @@
that was other than a selfsig, or any revocation), then
update/check the trustdb if the user specified by setting
interactive or by not setting no-auto-check-trustdb */
- if (!(options&IMPORT_FAST_IMPORT) && trustdb_pending_check())
+ if (!(options&IMPORT_FAST) && trustdb_pending_check())
{
if (opt.interactive)
update_trustdb();
@@ -1493,7 +1495,7 @@
delete_kbnode( node ); /* build_packet() can't handle this */
else if( node->pkt->pkttype == PKT_SIGNATURE &&
!node->pkt->pkt.signature->flags.exportable &&
- !(options&IMPORT_ALLOW_LOCAL_SIGS) &&
+ !(options&IMPORT_LOCAL_SIGS) &&
seckey_available( node->pkt->pkt.signature->keyid ) )
{
/* here we violate the rfc a bit by still allowing
Index: gnupg/g10/options.h
diff -u gnupg/g10/options.h:1.127 gnupg/g10/options.h:1.128
--- gnupg/g10/options.h:1.127 Thu Nov 25 04:58:42 2004
+++ gnupg/g10/options.h Fri Nov 26 16:51:37 2004
@@ -245,15 +245,15 @@
names between the IMPORT_ and EXPORT_ flags as they can be mixed in
the keyserver-options option. */
-#define IMPORT_ALLOW_LOCAL_SIGS (1<<0)
+#define IMPORT_LOCAL_SIGS (1<<0)
#define IMPORT_REPAIR_PKS_SUBKEY_BUG (1<<1)
-#define IMPORT_FAST_IMPORT (1<<2)
+#define IMPORT_FAST (1<<2)
#define IMPORT_SK2PK (1<<3)
#define IMPORT_MERGE_ONLY (1<<4)
-#define EXPORT_INCLUDE_LOCAL_SIGS (1<<0)
-#define EXPORT_INCLUDE_ATTRIBUTES (1<<1)
-#define EXPORT_INCLUDE_SENSITIVE_REVKEYS (1<<2)
+#define EXPORT_LOCAL_SIGS (1<<0)
+#define EXPORT_ATTRIBUTES (1<<1)
+#define EXPORT_SENSITIVE_REVKEYS (1<<2)
#define EXPORT_MINIMAL (1<<3)
#define LIST_SHOW_PHOTOS (1<<0)
More information about the Gnupg-commits
mailing list