be.SIRAPRISE.messages
Class ServerHelloMessageTypeV1_0

java.lang.Object
  extended by be.SIRAPRISE.messages.ServerMessageType
      extended by be.SIRAPRISE.messages.ServerHelloMessageType
          extended by be.SIRAPRISE.messages.ServerHelloMessageTypeV1_0

public final class ServerHelloMessageTypeV1_0
extends ServerHelloMessageType

ServerHelloMessageTypeV1_0 is the V1.0 version of the server hello message type.

The layout of this message is as follows :

Zone Format Length Description
SPINDICATOR INTEGER 1 0 if no signing protocol was retained (field SP will not be present in the response).
1 if a signing protocol is retained.
SP STRING   The name of the signing protocol that the server elected as the most appropriate to be used.
EPINDICATOR INTEGER 1 0 if no encryption protocol was retained (fields EP and SERVEREPINFO will not be present in the response).
1 if an encryption protocol is retained (fields EP and SERVEREPINFO will be present in the response).
EP STRING   The name of the encryption protocol that the server elected as the one to be used on this connection.
SERVEREPINFO BYTES   This field contains info pertinent to the particular encryption protocol elected by the server. The format of this field is protocol-specific and explained in separate tables below.
IDLETIME INTEGER 8 The idle time that the server has decided to allow for this connection. Clients must inspect this field and cannot simply assume that the server will retain the IDLETIME setting that has been requested by the client in the session protocol negotiation message.
MAJORVERSION INTEGER 2 The major version of the SIRA_PRISE specification that the client is to use when selecting the message versions to send to the server and to interpret the responses from the server. This may be a "lesser" version of the SIRA_PRISE specification if the client package is "more recent" than the server that the client is connecting to.
MINORVERSION INTEGER 2 The minor version of the SIRA_PRISE specification that the client is to use.
ALTSIGNATURES INTEGER 2 The number of alternative signature algorithms that the server supports, and that can be used in e.g. transaction user identity signing. Can be zero.
ALTSIGNATURE STRING   The name of an alternative signing algorithm that the server supports and that can be used in e.g. user identity signing when starting transactions. Appears as many times as indicated in the ALTSIGNATURES field.

The layout of the SERVEREPINFO field depends on the particular encryption protocol elected by the server and named in EP. Currently, only one encryption protocol is supported, namely SIRA_PRISE's proprietary SPE protocol. The layout of the SERVEREPINFO field for this protocol is as follows :

Zone Format Length Description
KEY INTEGER 4096 An array of 2048 2-byte INTEGER values.
Note that SPE is a symmetric algorithm. The key to be used for encryption is generated by the SIRA_PRISE server for each new connection created.

Since:
SIRA_PRISE 1.1
Author:
Erwin Smout

Field Summary
 
Fields inherited from class be.SIRAPRISE.messages.ServerHelloMessageType
MESSAGETYPEID
 
Method Summary
 ServerHelloMessage message(java.security.Signature signingProtocol, be.SIRAPRISE.security.ProprietaryOrJCECipher cryptoProtocol, long idleTime, Version clientSiraPriseVersion, java.util.Set<java.lang.String> alternativeSigningProtocols)
          Factory method to produce a ServerHello message of this version of the message type
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

message

public ServerHelloMessage message(java.security.Signature signingProtocol,
                                  be.SIRAPRISE.security.ProprietaryOrJCECipher cryptoProtocol,
                                  long idleTime,
                                  Version clientSiraPriseVersion,
                                  java.util.Set<java.lang.String> alternativeSigningProtocols)
Description copied from class: ServerHelloMessageType
Factory method to produce a ServerHello message of this version of the message type

Specified by:
message in class ServerHelloMessageType
Parameters:
signingProtocol - The message signing protocol elected by the server from the set of signing protocols proposed by the client
cryptoProtocol - The encryption protocol elected by the server from the set of encryption protocols proposed by the client
idleTime - The time in milliseconds that the server will allow this connection to remain idle
clientSiraPriseVersion - The SIRA_PRISE version that the client must use for communication.
alternativeSigningProtocols - The set of alternative signing protocols that the server can handle (in addition to the elected signingProtocol) for user authentication
Returns:
A ServerHello message with the given data, of the appropriate version