JCE Provider
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | List of all members
CryptoServerException Class Reference

Signals that a CryptoServer exception of some sort has occured. More...

Inherits Exception.

Public Member Functions

 CryptoServerException (int err, String message)
 Constructs a CryptoServer exception with the given error code (reason) and the specified message. More...
 
 CryptoServerException (int err)
 Constructs a CryptoServer exception with the given error code (reason). More...
 

Static Public Member Functions

static void addErrorTable (String name) throws IOException
 Extents the error string table. More...
 
static String getErrorMessage (int err, String message)
 Returns the error message associated with a given error code. More...
 

Public Attributes

int ErrorCode
 Error Code of the exception. More...
 
byte[] ErrorAnswer
 Answer data in error case. More...
 

Protected Member Functions

 CryptoServerException (int err, byte[] eansw)
 

Detailed Description

Signals that a CryptoServer exception of some sort has occured.

Exections of this type are produced either on the CryptoServer (mask: 0xB3FF0000) or by the CryptoServerAPI (mask: 0xBC000000).

Constructor & Destructor Documentation

◆ CryptoServerException() [1/2]

CryptoServerException ( int  err,
String  message 
)

Constructs a CryptoServer exception with the given error code (reason) and the specified message.

Parameters
errerror code (reason).
messageadditional error message

◆ CryptoServerException() [2/2]

CryptoServerException ( int  err)

Constructs a CryptoServer exception with the given error code (reason).

Parameters
errerror code (reason).

Member Function Documentation

◆ addErrorTable()

static void addErrorTable ( String  name) throws IOException
static

Extents the error string table.

This class contains a list of error message strings, one for each error code. This method can be used to add custom specific error messages to this list.

Parameters
nameName of the file that contains error messages (ASCII). The file is loaded from the jar file that contains the CryptoServerException class.

◆ getErrorMessage()

static String getErrorMessage ( int  err,
String  message 
)
static

Returns the error message associated with a given error code.

Parameters
errError code.
messagedefault error message if no other message was found.
Returns
Message.

Member Data Documentation

◆ ErrorAnswer

byte [] ErrorAnswer

Answer data in error case.

In addition to the error code the CryptoServer may send additional data in case of an error.

Note
Currently standard Utimaco firmware modules don't send error answer data.

◆ ErrorCode

int ErrorCode

Error Code of the exception.

Each reason for an exception is uniquely identified by an error code.