Encryption Methods

The race-encryptor module is responsible for securing communication and protecting hidden knowledge within Race Protocol games. It utilizes a combination of cryptographic algorithms to achieve these goals:

  • ChaCha20: This symmetric stream cipher is used to encrypt game state data and custom game events. ChaCha20 is a modern and efficient algorithm that provides strong encryption while maintaining good performance.

  • RSA: This asymmetric encryption algorithm is used to encrypt secret keys and other sensitive information that needs to be shared selectively between participants. RSA allows for secure communication between the Transactor and individual players or validators without revealing the information to others.

  • SHA-1 and SHA-256: These cryptographic hash functions are used for various purposes within the protocol, such as generating unique identifiers for transactions and verifying the integrity of data.

Securing Communication

The race-encryptor module ensures secure communication between different components in Race Protocol:

  • Client-Transactor Communication: When a client connects to the Transactor, it shares its public key. The Transactor uses this public key to encrypt any sensitive information, such as secret keys or private game state updates, before sending them to the client. The client can then decrypt the information using its private key.

  • Transactor-Validator Communication: Similar to client communication, the Transactor uses RSA to encrypt sensitive information before sharing it with validator servers. This ensures that only authorized participants can access the information.

Protecting Hidden Knowledge

In games with asymmetric information, it's crucial to protect hidden knowledge from unauthorized access. The race-encryptor module uses ChaCha20 to encrypt game state data and custom game events, ensuring that this information remains hidden until the game handler decides to reveal it. This prevents players from gaining an unfair advantage by prematurely accessing sensitive information.

By employing these encryption methods, Race Protocol guarantees the confidentiality and integrity of game data and communication, fostering a secure and fair gaming environment for all participants.

Last updated