tools.codec.pkcs
Class Sign

java.lang.Object
  extended bytools.codec.pkcs.AbstractTool
      extended bytools.codec.pkcs.Sign

public class Sign
extends AbstractTool

Demonstrates signing and verification based on PKCS#7.

Version:
"$Id: Sign.java 1913 2007-08-08 02:41:53Z jpeters $"
Author:
Volker Roth
See Also:
SignedData

Field Summary
static String DESCR
          The options descriptor.
protected  boolean dirty_
          Dirty flag, signals that the SignedData must be saved.
protected  SignedData p7m_
          The SignedData structure.
 
Fields inherited from class tools.codec.pkcs.AbstractTool
keystore_, p_
 
Constructor Summary
Sign()
           
 
Method Summary
protected  void addSigner(SignedData sd)
           
protected  SignedData create()
           
static void main(String[] argv)
           
 void run(String[] argv)
           
protected  void verify(SignedData sd)
           
 
Methods inherited from class tools.codec.pkcs.AbstractTool
getCertificate, getKeyStore, getPrivateKey, loadContentInfo, saveContentInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DESCR

public static final String DESCR
The options descriptor.

See Also:
Constant Field Values

p7m_

protected SignedData p7m_
The SignedData structure.


dirty_

protected boolean dirty_
Dirty flag, signals that the SignedData must be saved.

Constructor Detail

Sign

public Sign()
Method Detail

create

protected SignedData create()
                     throws GeneralSecurityException
Throws:
GeneralSecurityException

addSigner

protected void addSigner(SignedData sd)
                  throws GeneralSecurityException,
                         IOException,
                         BadNameException,
                         ArgsParserException
Throws:
GeneralSecurityException
IOException
BadNameException
ArgsParserException

verify

protected void verify(SignedData sd)
               throws IOException,
                      GeneralSecurityException,
                      ArgsParserException
Throws:
IOException
GeneralSecurityException
ArgsParserException

run

public void run(String[] argv)
         throws Exception
Throws:
Exception

main

public static void main(String[] argv)


Copyright © Fraunhofer Gesellschaft. All Rights Reserved.