Rivest-Shamir-Adleman Algorithm in Microgaming Security Systems

The Microgaming security system uses various methods for data protection to provide a reliable service of creating games and soft for online gambling houses. As web venturing entertainments are in close connection with transferring of sensitive information like financial (credit card number) and personal data, the company has to implement the latest encryption technologies for safe transmission (without unauthorized access) of data between clients and casino operators.

For this, programmers use such cryptologic scheme as RSA. This method has become quite widespread and it’s common to use this public key algorithm in main security certificates including TLS/SSL.

Historical Notes

New security system (founders: Rivest, Shamir, and Adelman) was created in 1977. Diffie-Hellman published the paper about the first asymmetric pb-pr (public-private) key cipher after that the RSA creators initiated the work. Those mathematicians wanted to discover a way how to implement the above-mentioned concept in a single function that would be very difficult to invert. After a period of series of attempts, they succeeded and in 1986 started to bring the commercial side of the invention to evolve. And nowadays, it is a very common option when secure data transmission is necessary.
Such glory has appeared because RSA solves a question of confidential info sharing, integrity, and assuring that certain authorized parties are able to get the ciphering/deciphering keys (by implementing the digital signature verification).
One of two lock codes is public while another one is secret (however, both can encrypt information). Thus, only a party which has a private one is able to decipher the message.

The Mathematics of RSA

The concept mathematically emerges from sophisticated and time-consuming factoring of 2 big prime numbers. The keys have different components that must be calculated.
The public one consists of digits “i” (modulus) and “u” (or pb exponent). The private consists of “i” and pb exponent (“f”).
Steps to create a pair of pb-pr keys:

  • Create two large rdm prime numbers (“z” and “y”);
  • Compute “i” by multiplying “z” and “y”;
  • Pick an odd digit (public exponent) between 3 and n-1;
  • (“i”,“u”) – pb lock code and (“i”, “f”) will be pr accordingly.

Working Example

So to see how it works, let’s make an example of simple Microgaming RSA cipher with the help of the instruction given earlier.
For instance, Mike wants to create his RSA keys by randomly picking two primes, let it be 11 for z and 13 for y. Then he selects 7 as (pb exponent) and gets 143 (i), and the private code will be 103 (after computing).
The modulus i is found by multiplying z and y (143).
When Tom sends Mike a ciphered text M he needs to get Mike’s RSA (pb key-code) that is (143,7). The content of his message is just the digit 9, which turns into an encrypted message C (after using public signature).
M^u mod i=9 7 mod 143=C
When Mike gets such message H, he can decrypt it (with pr key):
C^f mod i=48 103 mod 143=9=M

Weaknesses and Solutions

However, this algorithm has some weak places that emerge from poor experience (lack of knowledge) when working with it:

  • Not large enough size of (u) exponent that may allow to easily recover the initial text
  • Insufficient u and tiny size of the message that can be deciphered without much effort (the condition for safe text: M is bigger than i)
  • Same chain for digital signing and ciphering
  • Reverse RSA alteration of the input

The solution for decreasing weaknesses includes such statements as:

  • Don’t use mentioned above points in the encoding process
  • It is necessary to format the input before ciphering or signing
  • Try to add extra 8 bytes or more to the text before encrypting

Advanced Schemes

There is a usual scheme of calculation for RSA (mentioned in the example paragraph), but other ones also exist that are more advanced for encrypting or signing.

X9.31 Signature Scheme

This scheme performs a way of ciphering the text digest specific to the hash algorithm. The length of the chain, in this case, 256 bits.


Such ciphering method exists for encrypting messages before generating a signature.

ISO/IEC 9796

ISO/IEC 9796 is an old-fashioned option that was used when there was a text digest function of recognition. The scheme made it possible to get the initial text.


This technique for encrypting uses a specific function (MGF) that is derived from the hash function, but the ciphered block doesn’t have obvious and straight structure.


It ciphers a rdm integer with the pb lock code of the recipient and then RSA-KEM uses a symmetric keyframing scheme for encoding data.

Ferguson-Schneier Encryption

Such technique uses RSA for ciphering a rdm integer and then obtains initial encryption key by using a hash function (this method removes similar structural points between CEK and encoded information).

Security of Algorithm in Microgaming

The safety of it relies on the complexity of time-consuming calculation when factoring big numbers. With the today’s power of computers, small keys are not secure, that’s why standards of 1024 and 2048 bits are used (including Microgaming). In the near future, only 2048 bits will remain secure.

Comparing Diffie-Hellman and RSA

The Diffie-Hellman method is for sharing a secret key (asymmetric) between two parties (using unsafe channel) that only they know, without any preliminary connection.
The RSA also consists of asymmetric signatures, but it has the additional function of digital signing. However, it requires the shared pb key-code.