@@ -526,40 +526,46 @@ libspdm_return_t libspdm_get_supported_algorithms(void *spdm_context,
526526 * If encapsulated mutual authentication is requested from the responder,
527527 * this function also perform the encapsulated mutual authentication.
528528 *
529- * @param spdm_context A pointer to the SPDM context.
530- * @param use_psk False means to use KEY_EXCHANGE/FINISH to start a session.
531- * True means to use PSK_EXCHANGE/PSK_FINISH to start a session.
532- * @param psk_hint The psk_hint in PSK_EXCHANGE. It is ignored if use_psk is false.
533- * @param psk_hint_size The size in bytes of psk_hint. It is ignored if use_psk is false.
534- * @param measurement_hash_type The type of the measurement hash.
535- * @param slot_id The number of slot for the certificate chain.
536- * @param session_policy The policy for the session.
537- * @param session_id The session ID of the session.
538- * @param heartbeat_period The heartbeat period for the session.
539- * @param measurement_hash A pointer to a destination buffer to store the measurement hash.
540- * @param requester_random_in A buffer to hold the requester random as input, if not NULL.
541- * @param requester_random_in_size The size of requester_random_in.
542- * If use_psk is false, it must be 32 bytes.
543- * If use_psk is true, it means the PSK context and must be 32 bytes at least,
544- * but not exceed LIBSPDM_PSK_CONTEXT_LENGTH.
545- * @param requester_random A buffer to hold the requester random, if not NULL.
546- * @param requester_random_size On input, the size of requester_random buffer.
547- * On output, the size of data returned in requester_random buffer.
548- * If use_psk is false, it must be 32 bytes.
549- * If use_psk is true, it means the PSK context and must be 32 bytes at least.
550- * @param responder_random A buffer to hold the responder random, if not NULL.
551- * @param responder_random_size On input, the size of requester_random buffer.
552- * On output, the size of data returned in requester_random buffer.
553- * If use_psk is false, it must be 32 bytes.
554- * If use_psk is true, it means the PSK context. It could be 0 if device does not support context.
555- * @param requester_opaque_data A buffer to hold the requester opaque data, if not NULL.
556- * If not NULL, this function will not generate any opaque data,
557- * including secured message versions.
558- * @param requester_opaque_data_size The size of the opaque data, if requester_opaque_data is not NULL.
559- * @param responder_opaque_data A buffer to hold the responder opaque data, if not NULL.
560- * @param responder_opaque_data_size On input, the size of the opaque data buffer.
561- * Opaque data should be less than 1024 bytes.
562- * On output, the size of the opaque data.
529+ * @param spdm_context A pointer to the SPDM context.
530+ * @param use_psk False means to use KEY_EXCHANGE/FINISH to start a session.
531+ * True means to use PSK_EXCHANGE/PSK_FINISH to start a session.
532+ * @param psk_hint The psk_hint in PSK_EXCHANGE. It is ignored if use_psk is false.
533+ * @param psk_hint_size The size in bytes of psk_hint. It is ignored if use_psk is false.
534+ * @param measurement_hash_type The type of the measurement hash.
535+ * @param slot_id The number of slot for the certificate chain.
536+ * @param session_policy The policy for the session.
537+ * @param session_id The session ID of the session.
538+ * @param heartbeat_period The heartbeat period for the session.
539+ * @param measurement_hash A pointer to a destination buffer to store the measurement hash.
540+ * @param requester_random_in A buffer to hold the requester random as input, if not NULL.
541+ * @param requester_random_in_size The size of requester_random_in.
542+ * If use_psk is false, it must be 32 bytes.
543+ * If use_psk is true, it means the PSK context and must be 32 bytes at least,
544+ * but not exceed LIBSPDM_PSK_CONTEXT_LENGTH.
545+ * @param requester_random A buffer to hold the requester random, if not NULL.
546+ * @param requester_random_size On input, the size of requester_random buffer.
547+ * On output, the size of data returned in requester_random buffer.
548+ * If use_psk is false, it must be 32 bytes.
549+ * If use_psk is true, it means the PSK context and must be 32 bytes at least.
550+ * @param responder_random A buffer to hold the responder random, if not NULL.
551+ * @param responder_random_size On input, the size of requester_random buffer.
552+ * On output, the size of data returned in requester_random buffer.
553+ * If use_psk is false, it must be 32 bytes.
554+ * If use_psk is true, it means the PSK context. It could be 0 if device does not support context.
555+ * @param requester_ex_opaque_data A buffer to hold the requester exchange opaque data, if not NULL.
556+ * If not NULL, this function will not generate any opaque data,
557+ * including secured message versions.
558+ * @param requester_ex_opaque_data_size The size of the opaque data, if requester_ex_opaque_data is not NULL.
559+ * @param responder_ex_opaque_data A buffer to hold the responder exchange opaque data, if not NULL.
560+ * @param responder_ex_opaque_data_size On input, the size of the opaque data buffer.
561+ * Opaque data should be less than 1024 bytes.
562+ * On output, the size of the opaque data.
563+ * @param requester_finish_opaque_data A buffer to hold the requester finish opaque data, if not NULL.
564+ * @param requester_finish_opaque_data_size The size of the opaque data, if requester_finish_opaque_data is not NULL.
565+ * @param responder_finish_opaque_data A buffer to hold the responder finish opaque data, if not NULL.
566+ * @param responder_finish_opaque_data_size On input, the size of the opaque data buffer.
567+ * Opaque data should be less than 1024 bytes.
568+ * On output, the size of the opaque data.
563569 **/
564570libspdm_return_t libspdm_start_session_ex (void * spdm_context , bool use_psk ,
565571 const void * psk_hint ,
@@ -576,10 +582,15 @@ libspdm_return_t libspdm_start_session_ex(void *spdm_context, bool use_psk,
576582 size_t * requester_random_size ,
577583 void * responder_random ,
578584 size_t * responder_random_size ,
579- const void * requester_opaque_data ,
580- size_t requester_opaque_data_size ,
581- void * responder_opaque_data ,
582- size_t * responder_opaque_data_size );
585+ const void * requester_ex_opaque_data ,
586+ size_t requester_ex_opaque_data_size ,
587+ void * responder_ex_opaque_data ,
588+ size_t * responder_ex_opaque_data_size ,
589+ const void * requester_finish_opaque_data ,
590+ size_t requester_finish_opaque_data_size ,
591+ void * responder_finish_opaque_data ,
592+ size_t * responder_finish_opaque_data_size );
593+
583594
584595/**
585596 * This function sends END_SESSION to stop an SPDM Session.
0 commit comments