mirror of
git://git.gnupg.org/gnupg.git
synced 2025-04-17 15:44:34 +02:00
See ChangeLog: Mon Sep 20 12:24:41 CEST 1999 Werner Koch
This commit is contained in:
parent
eabe7b277c
commit
db78307c03
7
NEWS
7
NEWS
@ -1,3 +1,10 @@
|
|||||||
|
|
||||||
|
* New command --verify-files.
|
||||||
|
|
||||||
|
* Fixed some minor bugs.
|
||||||
|
|
||||||
|
* Add Indonesian and Portugese translations.
|
||||||
|
|
||||||
Noteworthy changes in version 1.0.0 (1999-09-07)
|
Noteworthy changes in version 1.0.0 (1999-09-07)
|
||||||
-----------------------------------
|
-----------------------------------
|
||||||
|
|
||||||
|
@ -156,6 +156,15 @@ filename to force a read from stdin). With more than
|
|||||||
and the remaining files are the signed stuff.
|
and the remaining files are the signed stuff.
|
||||||
</para></listitem></varlistentry>
|
</para></listitem></varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term>--verify-files <optional><optional><parameter/files/</optional>
|
||||||
|
<listitem><para>
|
||||||
|
This is a special version of the --verify command which does not work with
|
||||||
|
detached signatures. The command expects the files to bee verified either
|
||||||
|
on the commandline or reads the filenames from stdin; each anem muts be on
|
||||||
|
separate line. The command is intended for quick checking of many files.
|
||||||
|
</para></listitem></varlistentry>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
B<-k> [I<username>] [I<keyring>]
|
B<-k> [I<username>] [I<keyring>]
|
||||||
Kludge to be somewhat compatible with PGP.
|
Kludge to be somewhat compatible with PGP.
|
||||||
|
@ -11,7 +11,7 @@ all-local: ./signatures.jpg
|
|||||||
./signatures.jpg: $(srcdir)/signatures.jpg.asc
|
./signatures.jpg: $(srcdir)/signatures.jpg.asc
|
||||||
../../g10/gpg --yes --dearmor \
|
../../g10/gpg --yes --dearmor \
|
||||||
-o ./signatures.jpg $(srcdir)/signatures.jpg.asc
|
-o ./signatures.jpg $(srcdir)/signatures.jpg.asc
|
||||||
test -d manual && cp ./signatures.jpg ./manual/signatures.jpg
|
-test -d manual && cp ./signatures.jpg ./manual/signatures.jpg
|
||||||
|
|
||||||
|
|
||||||
index.html: $(PARTS)
|
index.html: $(PARTS)
|
||||||
|
@ -1,6 +1,11 @@
|
|||||||
Fri Sep 17 12:56:42 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
Mon Sep 20 12:24:41 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
||||||
|
|
||||||
|
|
||||||
|
* verify.c (verify_files, ferify_one_file): New.
|
||||||
|
* g10.c: New command --verify-files
|
||||||
|
|
||||||
|
Fri Sep 17 12:56:42 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
||||||
|
|
||||||
* g10.c: Add UK spelling as alias for armor options ;-)
|
* g10.c: Add UK spelling as alias for armor options ;-)
|
||||||
|
|
||||||
* import.c (append_uid): Fixed a SEGV when there is no selfsig and
|
* import.c (append_uid): Fixed a SEGV when there is no selfsig and
|
||||||
@ -9,16 +14,13 @@ Fri Sep 17 12:56:42 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
|||||||
|
|
||||||
Wed Sep 15 16:22:17 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
Wed Sep 15 16:22:17 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
||||||
|
|
||||||
|
|
||||||
* g10.c: New option --entropy-dll-name
|
* g10.c: New option --entropy-dll-name
|
||||||
|
|
||||||
Mon Sep 13 10:51:29 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
Mon Sep 13 10:51:29 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
||||||
|
|
||||||
|
|
||||||
* signal.c (got_fatal_signal): Print message using write(2) and
|
* signal.c (got_fatal_signal): Print message using write(2) and
|
||||||
only for development versions.
|
only for development versions.
|
||||||
|
|
||||||
|
|
||||||
Mon Sep 6 19:59:08 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
Mon Sep 6 19:59:08 CEST 1999 Werner Koch <wk@isil.d.shuttle.de>
|
||||||
|
|
||||||
* tdbio.c (tdbio_set_dbname): Use mkdir macro
|
* tdbio.c (tdbio_set_dbname): Use mkdir macro
|
||||||
|
@ -79,6 +79,7 @@ enum cmd_and_opt_values { aNull = 0,
|
|||||||
aImport,
|
aImport,
|
||||||
aFastImport,
|
aFastImport,
|
||||||
aVerify,
|
aVerify,
|
||||||
|
aVerifyFiles,
|
||||||
aListKeys,
|
aListKeys,
|
||||||
aListSigs,
|
aListSigs,
|
||||||
aListSecretKeys,
|
aListSecretKeys,
|
||||||
@ -193,6 +194,7 @@ static ARGPARSE_OPTS opts[] = {
|
|||||||
{ aStore, "store", 256, N_("store only")},
|
{ aStore, "store", 256, N_("store only")},
|
||||||
{ aDecrypt, "decrypt", 256, N_("decrypt data (default)")},
|
{ aDecrypt, "decrypt", 256, N_("decrypt data (default)")},
|
||||||
{ aVerify, "verify" , 256, N_("verify a signature")},
|
{ aVerify, "verify" , 256, N_("verify a signature")},
|
||||||
|
{ aVerifyFiles, "verify-files" , 256, "@" },
|
||||||
{ aListKeys, "list-keys", 256, N_("list keys")},
|
{ aListKeys, "list-keys", 256, N_("list keys")},
|
||||||
{ aListKeys, "list-public-keys", 256, "@" },
|
{ aListKeys, "list-public-keys", 256, "@" },
|
||||||
{ aListSigs, "list-sigs", 256, N_("list keys and signatures")},
|
{ aListSigs, "list-sigs", 256, N_("list keys and signatures")},
|
||||||
@ -697,6 +699,7 @@ main( int argc, char **argv )
|
|||||||
case aClearsign: set_cmd( &cmd, aClearsign); break;
|
case aClearsign: set_cmd( &cmd, aClearsign); break;
|
||||||
case aGenRevoke: set_cmd( &cmd, aGenRevoke); break;
|
case aGenRevoke: set_cmd( &cmd, aGenRevoke); break;
|
||||||
case aVerify: set_cmd( &cmd, aVerify); break;
|
case aVerify: set_cmd( &cmd, aVerify); break;
|
||||||
|
case aVerifyFiles: set_cmd( &cmd, aVerifyFiles); break;
|
||||||
case aPrimegen: set_cmd( &cmd, aPrimegen); break;
|
case aPrimegen: set_cmd( &cmd, aPrimegen); break;
|
||||||
case aGenRandom: set_cmd( &cmd, aGenRandom); break;
|
case aGenRandom: set_cmd( &cmd, aGenRandom); break;
|
||||||
case aPrintMD: set_cmd( &cmd, aPrintMD); break;
|
case aPrintMD: set_cmd( &cmd, aPrintMD); break;
|
||||||
@ -1116,6 +1119,11 @@ main( int argc, char **argv )
|
|||||||
log_error("verify signatures failed: %s\n", g10_errstr(rc) );
|
log_error("verify signatures failed: %s\n", g10_errstr(rc) );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case aVerifyFiles:
|
||||||
|
if( (rc = verify_files( argc, argv ) ))
|
||||||
|
log_error("verify files failed: %s\n", g10_errstr(rc) );
|
||||||
|
break;
|
||||||
|
|
||||||
case aDecrypt:
|
case aDecrypt:
|
||||||
if( argc > 1 )
|
if( argc > 1 )
|
||||||
wrong_args(_("--decrypt [filename]"));
|
wrong_args(_("--decrypt [filename]"));
|
||||||
|
@ -138,6 +138,7 @@ void secret_key_list( int nnames, char **names );
|
|||||||
|
|
||||||
/*-- verify.c --*/
|
/*-- verify.c --*/
|
||||||
int verify_signatures( int nfiles, char **files );
|
int verify_signatures( int nfiles, char **files );
|
||||||
|
int verify_files( int nfiles, char **files );
|
||||||
|
|
||||||
/*-- decrypt.c --*/
|
/*-- decrypt.c --*/
|
||||||
int decrypt_message( const char *filename );
|
int decrypt_message( const char *filename );
|
||||||
|
58
g10/verify.c
58
g10/verify.c
@ -83,5 +83,63 @@ verify_signatures( int nfiles, char **files )
|
|||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int
|
||||||
|
verify_one_file( const char *name )
|
||||||
|
{
|
||||||
|
IOBUF fp;
|
||||||
|
armor_filter_context_t afx;
|
||||||
|
int rc;
|
||||||
|
|
||||||
|
fp = iobuf_open(name);
|
||||||
|
if( !fp ) {
|
||||||
|
log_error(_("can't open `%s'\n"), print_fname_stdin(name));
|
||||||
|
return G10ERR_OPEN_FILE;
|
||||||
|
}
|
||||||
|
|
||||||
|
if( !opt.no_armor ) {
|
||||||
|
if( use_armor_filter( fp ) ) {
|
||||||
|
memset( &afx, 0, sizeof afx);
|
||||||
|
iobuf_push_filter( fp, armor_filter, &afx );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
rc = proc_signature_packets( NULL, fp, NULL, name );
|
||||||
|
iobuf_close(fp);
|
||||||
|
return rc;
|
||||||
|
}
|
||||||
|
|
||||||
|
/****************
|
||||||
|
* Verify each file given in the files array or read the names of the
|
||||||
|
* files from stdin.
|
||||||
|
* Note: This function can not handle detached signatures.
|
||||||
|
*/
|
||||||
|
int
|
||||||
|
verify_files( int nfiles, char **files )
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
if( !nfiles ) { /* read the filenames from stdin */
|
||||||
|
char line[2048];
|
||||||
|
unsigned int lno = 0;
|
||||||
|
|
||||||
|
while( fgets(line, DIM(line), stdin) ) {
|
||||||
|
lno++;
|
||||||
|
if( !*line || line[strlen(line)-1] != '\n' ) {
|
||||||
|
log_error(_("input line %u too long or missing LF\n"), lno );
|
||||||
|
return G10ERR_GENERAL;
|
||||||
|
}
|
||||||
|
/* This code does not work on MSDOS but how cares there are
|
||||||
|
* also no script languages available. We don't strip any
|
||||||
|
* spaces, so that we can process nearly all filenames */
|
||||||
|
line[strlen(line)-1] = 0;
|
||||||
|
verify_one_file( line );
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
else { /* take filenames from the array */
|
||||||
|
for(i=0; i < nfiles; i++ )
|
||||||
|
verify_one_file( files[i] );
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user