Root > Reference > All Functions > TEAInitSessionKey

Function TEAInitSessionKey

Previous pageReturn to chapter overviewNext page   

Generates random TEA key.

 

Unit

EEncrypt

 

Syntax

 

Code (Delphi)

function TEAInitSessionKey: TTEAKey;

 

Return value

Random TEA key.

 

You do not need to free/release/dispose this key - it does not contain any allocated memory. However, it is strongly recommended to call TEADestroyKey function once you have finished working with key - to erase it with zeros.

 

This value is never the same.

 

Remarks

This function generates random TEA key. This key can be used as session key for asymmetric encryption. See description of RSAEncrypt for more details.

 

Important!

Do not use RTL's Random function to create random TEA key manually. RTL implementation is a simple pseudo-random generator and it does not generate cryptographically-strong random data.

 

Use TEADeriveKey function to derive symmetric TEA key from string password or any other arbitrary "seed" data.

 

See also




Send feedback... Build date: 2024-12-19
Last edited: 2024-12-19
PRIVACY STATEMENT
The documentation team uses the feedback submitted to improve the EurekaLog documentation. We do not use your e-mail address for any other purpose. We will remove your e-mail address from our system after the issue you are reporting has been resolved. While we are working to resolve this issue, we may send you an e-mail message to request more information about your feedback. After the issues have been addressed, we may send you an email message to let you know that your feedback has been addressed.


Permanent link to this article: https://www.eurekalog.com/help/eurekalog/topic_function_eencrypt_teainitsessionkey.php