com.SecurePlay.SPTMultiPartSecret
Class SPTMultiPartSecretAPIClass

java.lang.Object
  extended bycom.SecurePlay.SPAbstractTransactionAPIClass
      extended bycom.SecurePlay.SPTMultiPartSecret.SPTMultiPartSecretAPIClass
All Implemented Interfaces:
SPAbstractTransactionAPIInterface

public class SPTMultiPartSecretAPIClass
extends SPAbstractTransactionAPIClass

This method is an extension of the SPSecretAPI Class to handle multi-part (String Array) secrets

Author:
IT GlobalSecure
See Also:
SecurePlay License Information
 

Field Summary
 
Fields inherited from class com.SecurePlay.SPAbstractTransactionAPIClass
transactioninstance
 
Constructor Summary
SPTMultiPartSecretAPIClass(SPTMultiPartSecretClass secretinstance)
          Overloaded Constructor
 
Method Summary
 java.lang.String[] APIgetSecret()
          This method returns the actual secret that this transaction is protecting, if available.
 boolean APIrequestrevealSecret(java.lang.String pid, java.lang.String[] receivers, java.lang.String liststatus)
          This method allows a third party player to request that the secret be revealed by the transaction master to the specified receiver list.
 boolean APIrequestsendHiddenSecret(java.lang.String pid, java.lang.String[] newsecret)
          This method allows a non-transaction master to request the transaction master send a Secret.
 boolean APIrevealSecret(java.lang.String sender, java.lang.String[] recievers, java.lang.String liststatus)
          This method sends the secretpadded value to the specified remote players.
 boolean APIsendHiddenSecret(java.lang.String sender, java.lang.String[] newsecret)
          This method allows the Secret Transaction master to send the transform of a secret to the other participants in the transaction.
 boolean APIverifySecret()
          This method verifies the paddedsecret that was sent.
 boolean rulesrevealSecret(java.lang.String sender, java.lang.String[] receivers, java.lang.String liststatus, SPTMultiPartSecretClass transobj)
          This shell method is a pluggable function to allow the override of handing incoming requests to reveal a Secret by the transaction master.
 boolean rulessendHiddenSecret(java.lang.String sender, java.lang.String[] newsecret, SPTMultiPartSecretClass transobj)
          This shell method provides a pluggable function to handle sendHiddenSecret requests.
 
Methods inherited from class com.SecurePlay.SPAbstractTransactionAPIClass
APIAddListener, APIbeginTransaction, APIClearListeners, APIcompleteTransaction, APIconfigureTransaction, APIGetListenerCount, APIGetListeners, APIRemoveListener, APIrequestbeginTransaction, APIrequestCompleteTransaction, APIrequestconfigureTransaction, APISPawn, getTransactioninstance, rulesbeginTransaction, rulescompleteTransaction, rulesconfigureTransaction
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SPTMultiPartSecretAPIClass

public SPTMultiPartSecretAPIClass(SPTMultiPartSecretClass secretinstance)
Overloaded Constructor

Parameters:
secretinstance - SPMultiPartSecretClass - the API associated with SPMultiPartSecretClass
Method Detail

APIgetSecret

public java.lang.String[] APIgetSecret()
This method returns the actual secret that this transaction is protecting, if available.

Returns:
result - String - the secret

APIrequestrevealSecret

public boolean APIrequestrevealSecret(java.lang.String pid,
                                      java.lang.String[] receivers,
                                      java.lang.String liststatus)
This method allows a third party player to request that the secret be revealed by the transaction master to the specified receiver list. This method is mainly used for remote debugging.

Parameters:
pid - String - the player id of the requestor
receivers - String[] - player ids of recievers of the secret
liststatus - String - status of the list
Returns:
result - Boolean: TRUE, if request successfully sent, FALSE, if not

APIrequestsendHiddenSecret

public boolean APIrequestsendHiddenSecret(java.lang.String pid,
                                          java.lang.String[] newsecret)
This method allows a non-transaction master to request the transaction master send a Secret. It is mainly used for remote debugging purposes.

Parameters:
pid - String - player id of the requestor
newsecret - String[] - the secret to be sent
Returns:
result - Boolean: TRUE, if request successfully sent, FALSE, if not

APIrevealSecret

public boolean APIrevealSecret(java.lang.String sender,
                               java.lang.String[] recievers,
                               java.lang.String liststatus)
This method sends the secretpadded value to the specified remote players.

Parameters:
sender - String - the sender of the secret
recievers - String[] - player ids of recievers
liststatus - String - "P" or "L"
Returns:
result - Boolean: TRUE, if successful, FALSE, if not

APIsendHiddenSecret

public boolean APIsendHiddenSecret(java.lang.String sender,
                                   java.lang.String[] newsecret)
This method allows the Secret Transaction master to send the transform of a secret to the other participants in the transaction.

Parameters:
sender - String - the sender of the hidden secret
newsecret - String[] - the secret message
Returns:
result - Boolean: TRUE, if successful, FALSE, if not

APIverifySecret

public boolean APIverifySecret()
This method verifies the paddedsecret that was sent. It computes the transform of the paddedsecret that has been sent and compares it with the previously sent secrettransform. It returns a Boolean flag to indicate success or failure.

Returns:
result - Boolean: TRUE, if able to verify secret, FALSE, if not

rulesrevealSecret

public boolean rulesrevealSecret(java.lang.String sender,
                                 java.lang.String[] receivers,
                                 java.lang.String liststatus,
                                 SPTMultiPartSecretClass transobj)
This shell method is a pluggable function to allow the override of handing incoming requests to reveal a Secret by the transaction master. It is mainly used for remote debugging purposes.

Parameters:
sender - String - sender of the secret
receivers - String[] - recievers of the secret
liststatus - String - list status
transobj - SPMultiPartSecretClass - the transaction object
Returns:
result - boolean: TRUE, if allowed or boolean FALSE, if not

rulessendHiddenSecret

public boolean rulessendHiddenSecret(java.lang.String sender,
                                     java.lang.String[] newsecret,
                                     SPTMultiPartSecretClass transobj)
This shell method provides a pluggable function to handle sendHiddenSecret requests. It is mainly used for debugging remote transactions.

Parameters:
sender - String - sender of the secret
newsecret - String[] - the secret
transobj - SPMultiPartSecretClass - the transaction object
Returns:
String - newsecret, if Successful, BOOLEAN FALSE, if not