Main Page | Modules | File List | File Members

# GSCryptoDefines.h File Reference

Cryptographic sdk variable definitions. More...

Go to the source code of this file.

## Classes
struct | RANDOM_STRUCT
struct | RSA_PRIVATE_KEY
struct | RSA_PROTO_KEY
struct | RSA_PUBLIC_KEY
## Defines
#define | MD5_DIGESTSIZE 16
| One-way hash digest size (MD5).
#define | SHA1_DIGESTSIZE 20
| One-way hash digest size (SHA1).
#define | MD5_HEXASIZE (2 * MD5_DIGESTSIZE)
| One-way hash hexadecimal output size (MD5).
#define | SHA1_HEXASIZE (2 * SHA1_DIGESTSIZE)
| One-way hash hexadecimal output size (SHA1).
#define | MGF1_HASHMULTIPLES 500
| Multiples of _DIGESTSIZE for byte string size.
#define | MIN_RSA_MODULUS_BITS 508
| Minimum length in bits of the modulus used in the RSA algorithm.
#define | MAX_RSA_MODULUS_BITS 1024
| Maximum length in bits of the modulus used in the RSA algorithm.
#define | MAX_RSA_MODULUS_LEN ((MAX_RSA_MODULUS_BITS + 7) / 8)
| Maximum length in bytes of the modulus used in the RSA algorithm.
#define | MAX_RSA_PRIME_BITS ((MAX_RSA_MODULUS_BITS + 1) / 2)
| Maximum length in bits of a prime.
#define | MAX_RSA_PRIME_LEN ((MAX_RSA_PRIME_BITS + 7) / 8)
#define | ENCODED_CONTENT_LEN(len) (4*(len)/3 + 3)
#define | ENCRYPTED_CONTENT_LEN(len) ENCODED_CONTENT_LEN ((len)+8)
#define | DECODED_CONTENT_LEN(len) (3*(len)/4 + 1)
#define | DECRYPTED_CONTENT_LEN(len) DECODED_CONTENT_LEN ((len)-1)
## Enumerations
enum | GSCRYPTO_HASH_ALGO { E_MD5, E_SHA1 }
| Cryptographic hash algorithms enumeration. More...
enum | GSCRYPTO_CIPHER_ALGO { E_BLOWFISH, E_GSXOR }
| Symmetric cryptographic algorithms enumeration. More...
enum | GSCRYPTO_PKC_ALGO { E_RSA }
| Asymmetric cryptographic algorithms enumeration. More...
enum | GSCRYPTO_PRNG_ALGO { E_MGF1 }
| Pseudo-Random Number Generator algorithms enumeration. More...

## Detailed Description

This file defines all the global values and structures used by the gs-sdk-crypto.

## Enumeration Type Documentation

enum GSCRYPTO_CIPHER_ALGO

| This structure contains the valid cipher algorithms that can be used with this sdk. E_BLOWFISH represent the blowfish algorithm and E_GSXOR represent the bitshift algorithm use by the the ubi.com gs-client.

enum GSCRYPTO_HASH_ALGO

| This structure contains the valid hash algorithms that can be used with this sdk. E_MD5 represent the MD5 algorithm and E_SHA1 represent the Secure Hash Algorithm .

enum GSCRYPTO_PKC_ALGO

| This structure contains the valid public/private key algorithms that can be used with this sdk. E_RSA represent the RSA algorithm.

enum GSCRYPTO_PRNG_ALGO

| This structure contains the valid PRNG algorithms that can be used with this sdk. E_MGF1 represent the Mask Generation Function algorithm.

Ubi.com GameService SDK - ©UbiSoft Entertainment 2002
GameService development team