--gen-revoke in batch

Werner Koch wk at gnupg.org
Fri Apr 18 10:33:05 CEST 2008


On Thu, 17 Apr 2008 20:28, mpant at ncsa.uiuc.edu said:

>>   $ gpg2 --status-fd 2  --command-fd 0 --gen-revoke joe
> I guess I can use gpg here ?

Yes.

>>   [GNUPG:] GET_BOOL gen_revoke.okay
> Are these commands generated by GPG ?

The option --status-fd N generates them and writes the to the file
descriptor N (in the example 2 = stderr), you may want to use 1 for stdout.


> What is FSM ? Finite State Machine. How can I use this?

Right.  This the proper way to automate gpg using
--command-fd/--status-fd .  It is a bit of work but has the advantage
that it won't break or, even worse, yields unexpected results if gpg
adds other status messages.  The GPA frontend uses this approach
(src/gpgmeedit.c).

>> should be answered with just a LF.  Of course you would use the
> What if LF ?

linefeed or in C notation "\n" (ASCII code 0x10).

> I need to write the revocation certificate to a file too.

Use the gpg option

  --output FILE



Shalom-Salam,

   Werner

-- 
Die Gedanken sind frei.  Auschnahme regelt ein Bundeschgesetz.




More information about the Gnupg-users mailing list