-/****s* silcske/SilcSKEAPI/SilcSKEStruct
- *
- * NAME
- *
- * struct SilcSKEStruct { ... };
- *
- * DESCRIPTION
- *
- * This structure is the SKE session context, and has a type definition
- * to SilcSKE. The structure includes the network connection socket,
- * security properties collected during the SKE negotiation, payloads
- * sent and received during the negotiation, and the actual raw key
- * material too. The application usually does not need to reference
- * to the inside of this structure. However, checking the current
- * status of the session can easily be checked with ske->status.
- *
- * SOURCE
- */
-struct SilcSKEStruct {
- /* The network socket connection stream. Set by application. */
- SilcPacketStream stream;
-
- /* Negotiated Security properties. May be NULL in case of error. */
- SilcSKESecurityProperties prop;
-
- /* Key Exchange payloads filled during key negotiation with
- remote data. Responder may save local data here as well. */
- SilcSKEStartPayload start_payload;
- SilcSKEKEPayload ke1_payload;
- SilcSKEKEPayload ke2_payload;
- unsigned char *remote_version;
-
- /* Temporary copy of the KE Start Payload used in the
- HASH computation. */
- SilcBuffer start_payload_copy;
-
- /* Random number x, 1 < x < q. This is the secret exponent
- used in Diffie Hellman computations. */
- SilcMPInt *x;
-
- /* The secret shared key */
- SilcMPInt *KEY;
-
- /* The hash value HASH of the key exchange */
- unsigned char *hash;
- SilcUInt32 hash_len;
-
- /* Random Number Generator. This is set by the caller and must
- be free'd by the caller. */
- SilcRng rng;
-
- /* Pointer to the what ever user data. This is set by the caller
- and is not touched by the SKE. The caller must also free this one. */
- void *user_data;
-
- /* Current status of SKE */
- SilcSKEStatus status;
-
- /* Reference counter. This is used when SKE library is performing async
- operations, like public key verification. */
- int users;
-
- /* SKE callbacks. */
- SilcSKECallbacks callbacks;
-
- /* Backwards support version indicator */
- SilcUInt32 backward_version;
-
- char *version;
- SilcPublicKey public_key;
- SilcPrivateKey private_key;
- SilcSKEPKType pk_type;
- SilcBuffer packet_buf;
- SilcSKESecurityPropertyFlag flags;
- SilcSKEKeyMaterial keymat;
- SilcSKERekeyMaterial rekey;
- SilcSchedule schedule;
- SilcFSMStruct fsm;
- SilcAsyncOperationStruct op;
- bool aborted;
-};
-/***/
-