IAIK PKCS#11 Wrapper Demo
version 1.2.17

demo.pkcs.pkcs11
Class InitArgs

java.lang.Object
  extended bydemo.pkcs.pkcs11.InitArgs
All Implemented Interfaces:
InitializeArgs

public class InitArgs
extends Object
implements InitializeArgs

This demo program tries to call initialize with some arguments.

Invariants

Field Summary
protected  byte[] reservedParameter_
           
 
Constructor Summary
InitArgs(byte[] reservedParameter)
           
 
Method Summary
 MutexHandler getMutexHandler()
          Get the handler object that handes mutex objects.
 Object getReserved()
          Get the reserved parameter.
 boolean isLibraryCantCreateOsThreads()
          Checks, if the library is not allowed to create operating system threads.
 boolean isOsLockingOk()
          Checks, if the library is allowed to use locking mechanisms of the operating system.
static void main(String[] args)
           
protected static void printUsage()
           
protected static byte[] readStream(InputStream in)
          Read the contents of the stream into a byte array.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

reservedParameter_

protected byte[] reservedParameter_
Constructor Detail

InitArgs

public InitArgs(byte[] reservedParameter)
Method Detail

main

public static void main(String[] args)

printUsage

protected static void printUsage()

readStream

protected static byte[] readStream(InputStream in)
                            throws IOException
Read the contents of the stream into a byte array. The stream is read until it returns EOF.

Throws:
IOException

getMutexHandler

public MutexHandler getMutexHandler()
Get the handler object that handes mutex objects.

Specified by:
getMutexHandler in interface InitializeArgs
Returns:
The mutex handler object or null, if there is none set.
Preconditions
Postconditions

isLibraryCantCreateOsThreads

public boolean isLibraryCantCreateOsThreads()
Checks, if the library is not allowed to create operating system threads.

Specified by:
isLibraryCantCreateOsThreads in interface InitializeArgs
Returns:
True, if the library is not allowed to create operating system threads; false, otherwise.
Preconditions
Postconditions

isOsLockingOk

public boolean isOsLockingOk()
Checks, if the library is allowed to use locking mechanisms of the operating system.

Specified by:
isOsLockingOk in interface InitializeArgs
Returns:
True, if the library is allowed to use locking mechanisms of the operating system.
Preconditions
Postconditions

getReserved

public Object getReserved()
Get the reserved parameter. This is always null as of version 2.11 of PKCS#11.

Specified by:
getReserved in interface InitializeArgs
Returns:
null as of version 2.11 of PKCS#11.
Preconditions
Postconditions
(result == null)

IAIK PKCS#11 Wrapper Demo
version 1.2.17

IAIK JavaSecurity Website http://jce.iaik.tugraz.at/

IAIK at Graz University of Technology, Austria, Europe
Copyright 2001-2002, IAIK, Graz University of Technology, Inffeldgasse 16a, 8010 Graz, Austria. All Rights Reserved.