#include <SPGameClass.h>
Inheritance diagram for SecurePlayLibrary::SPGameClass:

Public Member Functions | |
| SPGameClass () | |
| ~SPGameClass () | |
| SPGameClass (string gameID, string master, bool signaturepolicy, bool encryptionpolicy, SecurePlayClass *SPlibobj, SPLogInterface *log, SPSecurityManagerInterface *security) | |
| void | initializegame (string gameID, string master, bool signaturepolicy, bool encryptionpolicy, SecurePlayClass *SPlibobj, SPLogInterface *log, SPSecurityManagerInterface *security) |
| bool | attach (string gid, SecurePlayClass *lib, string master, bool signaturepolicy, bool encryptionpolicy, SPLogInterface *log, SPSecurityManagerInterface *security) |
| SPGameAPIInterface * | getGameAPI () |
| bool | addPlayer (string pid) |
| bool | removePlayer (string pid) |
| bool | setPlayerComms (string playerID, string commsID, bool relayflag) |
| SPPlayerInterface * | getGamePlayer (string playerID) |
| void | prUpdateGameStatus () |
| bool | gameComplete () |
| bool | addComms (string commsID) |
| bool | removeComms (string commsID) |
| bool | addTransaction (SPAbstractTransactionInterface *transObj) |
| bool | closeTransaction (string transID) |
| SPAbstractTransactionInterface * | getGameTransaction (string tid) |
| string | prsetTransactionID (SPAbstractTransactionInterface *transObj) |
| bool | transactionincluded (string tid) |
| bool | onbeginGame (SPMessageClass *messObj) |
| bool | onendGame (SPMessageClass *messObj) |
| void | onrequestbeginGame (SPMessageClass *messObj) |
| void | onrequestendGame (SPMessageClass *messObj) |
| bool | updateGameSegment (string currentseg, string nextseg) |
| bool | incrementBasicGameTransactionCount (int count) |
| bool | onnextGameSegmentID (SPMessageClass *messObj) |
| void | onIncomingTransaction (SPMessageClass *messObj) |
| bool | isPlayerInternal (string pid) |
| void | logError () |
| bool | sendMessage (string sender, vector< string > receivers, bool encryptflag, bool privateflag, string messagetype, vector< string > messagebody, vector< string > altmessage) |
| SPCommsManagerClass * | getCommsManager () |
| SecurePlayClass * | getSecurePlay () |
| string | getGamestatus () |
| vector< string > | getOpentransactionIDList () |
| vector< SPAbstractTransactionInterface * > | getTransactions () |
| int | getBasicGameTransactionCount () |
| string | getCurrentGameSegment () |
| int | getGameSegmentCount () |
| string | getNextGameSegment () |
| vector< SPPlayerInterface * > | getPlayers () |
| int | getPreloadGameSegment () |
| SPSecurityManagerInterface * | getSecurityManager () |
| vector< byte > | getHashText (string plainText, string algorithm) |
| vector< byte > | SPcreateBHash (string input, string gameid) |
| vector< byte > | SPcreateBSignature (string senderID, vector< byte > input, string gameid) |
| string | SPcreateHash (string input, string gameid) |
| string | SPcreateSignature (string senderID, string input, string gameid) |
| vector< string > | SPdecrypt (vector< string > input, string senderID, vector< string > recvrs, string gameID, string messageID) |
| vector< string > | SPencrypt (vector< string > input, string senderID, vector< string > recvrs, string gameID, string messageID) |
| string | SPtransform (string input, string gameid) |
| bool | SPverifySignature (vector< byte > sigToVerify, string senderID, vector< byte > testhash, string gameid) |
| bool | SPverifySignature (string signature, string senderID, string testhash, string gameid) |
| string | getGameID () |
| string | getTransactionID () |
| string | getMaster () |
| vector< string > | getPlayerIDList () |
| void | SPnotify (string eventdescription, vector< string > args) |
Public Attributes | |
| const string | extendedversion |
| const string | releaseversion |
Private Member Functions | |
| SPGameClass (const SPGameClass &p) | |
| operator= (const SPGameClass &p) | |
Private Attributes | |
| SPRootTransactionClass * | root |
| SPGameAPIInterface * | classAPI |
| SPCommsManagerClass * | comms |
| map< string, SPPlayerInterface * > | prplayerList |
| map< string, SPAbstractTransactionInterface * > | propentransactionList |
| vector< string > | opentransactionIDList |
| string | prcurrentGameSegment |
| string | prnextGameSegment |
| int | prpreloadGameSegment |
| int | prgamesegmentcount |
| int | prBasicGameTransactionCount |
| string | gamestatus |
| string | gameready |
| SecurePlayClass * | secureplay |
|
|
Private Copy Constructor that protects this class from being copied. |
|
|
Default Constructor. |
|
|
Default Destructor. |
|
||||||||||||||||||||||||||||||||
|
Constructs an overloaded SPGameClass()
|
|
|
This method associates a comms service specified by the commsID string to a game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method safely adds an existing Player, specified by the playerID to the game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This safely adds a transaction to a game instance and appropriately updates the game state.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||||||||||||||
|
This method attaches an empty game object instance and configures it for use in the SecurePlay library as a game with default comms
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Safely removes a transaction from a game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method allows external entities to review the status of the game instance without directly accessing its internals.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the property: prBasicGameTransactionCount
|
|
|
This method returns the unique Comms Manager object associated with the game instance
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the property: prcurrentGameSegment
|
|
|
This method returns the handler for the Game API object.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Gets the game id
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method returns the player object specified by the playerID.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the property: prgamesegmentcount
|
|
|
Getter function that returns the property: gamestatus
|
|
|
This method returns a specific transaction associated with a given game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This is a wrapper function for creating a hash of a string. This reference implementation includes a MD5 hash.
|
|
|
Gets the master of the transaction or game
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the property: prnextGameSegment
|
|
|
Getter function that returns the open transaction IDs
|
|
|
Gets the player id list of the players associated with the transaction or the game.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the players from prplayerlist
|
|
|
Getter function that returns the property: prpreloadGameSegment
|
|
|
This method returns the unique SecurePlay library object associated with the game instance object.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method returns the security manager class associated with this game.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Gets the transaction id.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
Getter function that returns the transactions from propentransactionlist
|
|
|
This method increments the game’s transaction counter to support certain licensing models
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||||||||||||||
|
Configures a new game.
|
|
|
Checks to see if the player is internal
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method is a placeholder for future internal logging |
|
|
This method handles requests to begin the local game. It ensures that the game is ready to be played, and, if so, updates the local game state appropriately.
|
|
|
This method safely ends the local game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method is the generic handler for incoming Game transaction methods.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method supports the SecurePlay licensing system to maintain synchronization of game segment IDs within a game. Deletion, modification, or circumvention of this software functionality is in violation of the SecurePlay license.
|
|
|
This method handles incoming requests to begin a game It passes the requests on to the API rules parser.
|
|
|
This method passes a request to end a game on to the game master's rule parser.
|
|
|
Private = operator that protects this class from being copied. |
|
|
This method generates a transactionID for a transaction object
|
|
|
This method does a self-check on the game instance object and updates its status appropriately. Mainly, it is used to lock the game when changes are occuring or if an error has occured. |
|
|
This method removes the association of a communications service with a game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method safely removes a Player instance from an existing Game Instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||||||||||||||
|
This method actually constructs messages to be sent by the Game object to other game object instances via the Comms Manager
|
|
||||||||||||||||
|
This method associates a specific player instance, specified by the playerID, with a specific communications service, specified by the commsID. For certain remote players, a relay service is supported to allow messages to be forwarded. NOTE: there is a reserved comms service "internal" for player instances that are included in the local application session.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This is a wrapper function for creating a hash of a string. This reference implementation includes a MD5 hash.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||
|
This is a wrapper function for creating a digital signature based on an existing hashed string and a Sender ID. The reference implementation currently uses an MD5 function to approximate performance of a real signature. The included signature function is a sample function - REPLACE with a function that meets your specific security requirements.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This is a wrapper function for creating a hash of a string. This reference implementation includes a MD5 hash.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||
|
This is a wrapper function for creating a digital signature based on an existing hashed string and a Sender ID. The reference implementation currently uses an MD5 function to approximate performance of a real signature. The included signature function is a sample function - REPLACE with a function that meets your specific security requirements.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||||||
|
This is a placeholder for an decryption function. An actual encryption function is the responsibility of the game implementer.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||||||
|
This is a placeholder for an encryption function. An actual encryption function is the responsibility of the game implementer.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This method notifies the Listeners of events
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This function performs an irreversible transform on an input string to generate an output string. The sample implementation uses MD5. This method can be overridden and should be reviewed for security purposes prior to use in a production implementation.
|
|
||||||||||||||||||||
|
This is a wrapper for a digital signature verification function. CAREFUL CHOICE OF ACTUAL DIGITAL SIGNATURES AND VERIFICATION IS CRITICAL. SELECTION OF APPROPRIATE FUNCTIONS AND IMPLEMENTATION MAY HAVE A SUBSTANTIAL IMPACT ON THE SECURITY AND PERFORMANCE OF A GAME IMPLEMENTATION.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||||||||||
|
This is a wrapper for a digital signature verification function. CAREFUL CHOICE OF ACTUAL DIGITAL SIGNATURES AND VERIFICATION IS CRITICAL. SELECTION OF APPROPRIATE FUNCTIONS AND IMPLEMENTATION MAY HAVE A SUBSTANTIAL IMPACT ON THE SECURITY AND PERFORMANCE OF A GAME IMPLEMENTATION.
Implements SecurePlayLibrary::SPGameInterface. |
|
|
This method checks the specified transaction ID against the currently included transaction IDs in the game instance.
Implements SecurePlayLibrary::SPGameInterface. |
|
||||||||||||
|
This method supports the administration of game segment IDs and counters. It is part of the SecurePlay licensing system. No deletion, modification, or circumvention is allowed without explicit permission as detailed in the SecurePlay license.
|
|
|
This is the same as prapi, it is being remapped to be consistent with the other classes. |
|
|
This is the SPcomms instance associated with the game instance. It is used to access the communications manager services to send and receive and process messages. |
|
|
Developer extended version. Reimplemented from SecurePlayLibrary::SPRootTransactionClass. |
|
|
this variable was created because we were not sure if it was a bug and should have been gamestatus, it will be clear after we test it |
|
|
This provides the current status of the game instance. The currenlty supported status strings are: "new" is a newly instantiateed game instance "ready" is ready to play (create transactions) "updating" is changing player or comms information "complete" is game over "error" is a hung game |
|
|
This property provides access to the open transaction IDs. This is the virtual method to access transactions. |
|
|
The basic game transaction count is a count of the total number of qualified basic game transactions in the game. It is required for conforming to the SecurePlay license. Unauthorized modification, circumvention, or removal is not permitted. |
|
|
This property should not be accessed directly. Modification of the game segment property or alteration of its usage is a violation of the SecurePlay license agreement. |
|
|
This is the count of game segments within a game instance. This is part of the SecurePlay licensing system. Modification, circumvention, or removal of this property or its associated methods is a violation of the SecurePlay license. |
|
|
This is the preloaded identifier for the next Game Segment. Modification, deletion, or circumvention of this property or its associated methods is a violation of the SecurePlay license. |
|
|
This is the associative array that holds the transaction object pointers. |
|
|
This is the associative array that holds the player objects that are participating in the game instance. |
|
|
This is a positive integer that specifies how early to preload a new game segment ID string. Modification, circumvention, or deletion of this property or its associated methods is a violation of the SecurePlay license. |
|
|
IT GlobalSecure release version. Reimplemented from SecurePlayLibrary::SPRootTransactionClass. |
|