FARGOS/VISTA Object Management Environment Core  ..
FARGOS/VISTA Object Management Environment Core Table of Contents
OME Cryptographic Routines

Enumerations

enum  { OME_INIT_VEC_LEN_IN_BITS =128, OME_INIT_VEC_LEN_IN_HEX_BYTES =(128 / 4), OME_SHA1_HASH_LEN_IN_BITS =160, OME_SHA1_HASH_LEN_IN_BYTES =(160 / 8) }
 
enum  {
  OME_ERROR_CRYPTO_BAD_VERSION =1, OME_ERROR_CRYPTO_BAD_MAGIC =2, OME_ERROR_CRYPTO_INTEGRITY1 =3, OME_ERROR_CRYPTO_DECODE_FAILED =4,
  OME_ERROR_CRYPTO_DECODE_ARRAY =5, OME_ERROR_CRYPTO_BAD_DATA =6, OME_ERROR_CRYPTO_INIT_FAILED =7, OME_ERROR_CRYPTO_WRONG_HOST =8,
  OME_ERROR_CRYPTO_WRONG_USER =9, OME_ERROR_CRYPTO_INTEGRITY2 =10
}
 

Functions

OMEstringOMEmakeRandomKey (int32_t bits=1024)
 Generate a random sequence of bits. More...
 
OMEstringOMEmakeSHA1hash (const OMEstring &message)
 Compute Secure Hash Algorithm 1 over an OMEstring. More...
 
OMEstringOMEmakeSHA256hash (const OMEstring &message)
 Compute Secure Hash Algorithm 256 over an OMEstring. More...
 
OMEstringOMEmakeMD5hash (const OMEstring &message)
 Compute Message Digest 5 over an OMEstring. More...
 
OMEstringOMEmakePrivateKey (const OMEstring &secretPhrase)
 
OMEstringOMEmakePublicKey (const OMEstring &privateKey)
 
OMEstringOMEmakeSessionKeyFromPublicKey (const OMEstring &publicKey, OMEstring &randomDataInSessionKeyOut)
 
OMEstringOMEdecryptSessionKeyWithPrivateKey (const OMEstring &privateKey, const OMEstring &data)
 
int OMEinitNewCipher (const OMEstring &initVector)
 
int OMEfreeCipher (int useCipher)
 
int OMEdefineNewEncryptKey (const OMEstring &key)
 
int OMEdefineNewDecryptKey (const OMEstring &key)
 
int OMEfreeEncryptionKey (int useKey)
 
int OMEfreeDecryptionKey (int useKey)
 
int OMEencryptString (int useCipher, int useKey, const OMEstring &input, OMEstring &result)
 
int OMEdecryptString (int useCipher, int useKey, const OMEstring &input, OMEstring &result)
 
OMEstringOMEreadLicenseFile (OMEstring *retFileName, const OMEstring &fileSuffix, const char *searchPath)
 
OMEtypeOMEgetLicenseAttribute (const OMEstring &attrName, OMEstring *retFileName=0)
 
OMEtypeOMEgetLicenseAttribute (const char *attrName, OMEstring *retFileName=0)
 
OMEtypeOMEgetSigningFile (const OMEstring &secret, const OMEstring &logicalDomain, bool isPublic=false)
 

Detailed Description

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
OME_INIT_VEC_LEN_IN_BITS 
OME_INIT_VEC_LEN_IN_HEX_BYTES 
OME_SHA1_HASH_LEN_IN_BITS 
OME_SHA1_HASH_LEN_IN_BYTES 

◆ anonymous enum

anonymous enum
Enumerator
OME_ERROR_CRYPTO_BAD_VERSION 
OME_ERROR_CRYPTO_BAD_MAGIC 
OME_ERROR_CRYPTO_INTEGRITY1 
OME_ERROR_CRYPTO_DECODE_FAILED 
OME_ERROR_CRYPTO_DECODE_ARRAY 
OME_ERROR_CRYPTO_BAD_DATA 
OME_ERROR_CRYPTO_INIT_FAILED 
OME_ERROR_CRYPTO_WRONG_HOST 
OME_ERROR_CRYPTO_WRONG_USER 
OME_ERROR_CRYPTO_INTEGRITY2 

Function Documentation

◆ OMEdecryptSessionKeyWithPrivateKey()

OMEstring* OMEdecryptSessionKeyWithPrivateKey ( const OMEstring privateKey,
const OMEstring data 
)

Referenced by decryptSessionKey().

◆ OMEdecryptString()

int OMEdecryptString ( int  useCipher,
int  useKey,
const OMEstring input,
OMEstring result 
)

◆ OMEdefineNewDecryptKey()

int OMEdefineNewDecryptKey ( const OMEstring key)

Referenced by initializeCipher().

◆ OMEdefineNewEncryptKey()

int OMEdefineNewEncryptKey ( const OMEstring key)

Referenced by initializeCipher().

◆ OMEencryptString()

int OMEencryptString ( int  useCipher,
int  useKey,
const OMEstring input,
OMEstring result 
)

◆ OMEfreeCipher()

int OMEfreeCipher ( int  useCipher)

◆ OMEfreeDecryptionKey()

int OMEfreeDecryptionKey ( int  useKey)

◆ OMEfreeEncryptionKey()

int OMEfreeEncryptionKey ( int  useKey)

◆ OMEgetLicenseAttribute() [1/2]

OMEtype* OMEgetLicenseAttribute ( const char *  attrName,
OMEstring retFileName = 0 
)

◆ OMEgetLicenseAttribute() [2/2]

◆ OMEgetSigningFile()

OMEtype* OMEgetSigningFile ( const OMEstring secret,
const OMEstring logicalDomain,
bool  isPublic = false 
)

◆ OMEinitNewCipher()

int OMEinitNewCipher ( const OMEstring initVector)

References MAX_CIPHERS.

Referenced by initializeCipher().

◆ OMEmakeMD5hash()

OMEstring* OMEmakeMD5hash ( const OMEstring message)

Compute Message Digest 5 over an OMEstring.

References OMEstring::length().

Referenced by MD5hash().

◆ OMEmakePrivateKey()

OMEstring* OMEmakePrivateKey ( const OMEstring secretPhrase)

◆ OMEmakePublicKey()

OMEstring* OMEmakePublicKey ( const OMEstring privateKey)

◆ OMEmakeRandomKey()

OMEstring* OMEmakeRandomKey ( int32_t  bits = 1024)

Generate a random sequence of bits.

References fd.

Referenced by becomePseudoUser(), getRandomInteger(), and makeRandomKey().

◆ OMEmakeSessionKeyFromPublicKey()

OMEstring* OMEmakeSessionKeyFromPublicKey ( const OMEstring publicKey,
OMEstring randomDataInSessionKeyOut 
)

Referenced by makeSessionKey().

◆ OMEmakeSHA1hash()

OMEstring* OMEmakeSHA1hash ( const OMEstring message)

Compute Secure Hash Algorithm 1 over an OMEstring.

References htonl, and OMEstring::length().

Referenced by OMEmakePrivateKey(), and SHA1hash().

◆ OMEmakeSHA256hash()

OMEstring* OMEmakeSHA256hash ( const OMEstring message)

Compute Secure Hash Algorithm 256 over an OMEstring.

References htonl, OMEstring::length(), and sha_memory().

Referenced by SHA256hash().

◆ OMEreadLicenseFile()

Generated: Fri Jul 31 2020 18:19:16
Support Information