The make_local_key session key generation procedure fills the buffer with a sequence of random bytes. This procedure is performed in the same way by each Extra Systems Cypher Net subscriber (naturally, the random sequences are generated differently). Then, in the get_common_key procedure, the binary addition of two such keys created by two subscribers occurs. The result is the same number, which is used as a session key for the stream encryption algorithm.
The PACKED_SESSION_KEY_LENTH key size depends on the encryption algorithm, but must be less than the RSA modulus, otherwise it cannot be encrypted. In our system, the maximum length of this parameter is set to be one byte shorter than the RSA key length (this ensures the possibility of subsequent encryption).
void make_local_key(void) { memset(local_key.packed, 0, PACKED_VALUE_LENTH); fill_random_buffer(local_key.packed, PACKED_SESSION_KEY_LENTH); unpack_value(local_key.packed, local_key.unpacked); }
The content of this page is also available in French, German, Portuguese, Spanish, Italian, Ukrainian and Russian.
© Extra Systems, 2024 |
|