- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I found the SGX SDK has a set of ECC crypto APIs but the User Guide is not clear (IMHO) regarding how to use them. So I'm asking for clarification.
- All of the APIs seem to require a sgx_ecc_state_handle_t. But nowhere is stated how this handle should be created. Any idea?
- Can I get to specify the EC curve? If not, what is the default curve?
Thanks!
Fan
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
- All of the APIs seem to require a sgx_ecc_state_handle_t. But nowhere is stated how this handle should be created. Any idea? -
sgx_ecc256_open_context:
sgx_ecc256_open_context returns an allocated and initialized context for the elliptic curve cryptosystem over a prime finite field, GF(p). This context must be created prior to calling sgx_ecc256_create_key_pair or sgx_ecc256_compute_shared_dhkey. When the calling code has completed its set of ECC operations, sgx_ecc256_close_context should be called to cleanup and deallocate the ECC context. - Syntax: sgx_status_t sgx_ecc256_open_context( sgx_ecc_state_handle_t *p_ecc_handle );
- Parameters: p_ecc_handle [out]
This is a handle to the ECC GF(p) context state allocated and initialized used to perform elliptic curve cryptosystem standard functions. The algorithm stores the intermediate results of calculations performed using this context.
-Surenthar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Interesting. The documentation (https://software.intel.com/sites/products/sgx-sdk-users-guide-windows/Default.htm) I'm reading says the opposite ([in] v.s. [out]):
I guess you're right and the documentation has a typo?
Surenthar Selvaraj. (Intel) wrote:
Hi,
- All of the APIs seem to require a sgx_ecc_state_handle_t. But nowhere is stated how this handle should be created. Any idea? -
sgx_ecc256_open_context:
sgx_ecc256_open_context returns an allocated and initialized context for the elliptic curve cryptosystem over a prime finite field, GF(p). This context must be created prior to calling sgx_ecc256_create_key_pair or sgx_ecc256_compute_shared_dhkey. When the calling code has completed its set of ECC operations, sgx_ecc256_close_context should be called to cleanup and deallocate the ECC context.- Syntax: sgx_status_t sgx_ecc256_open_context( sgx_ecc_state_handle_t *p_ecc_handle );
- Parameters: p_ecc_handle [out]
This is a handle to the ECC GF(p) context state allocated and initialized used to perform elliptic curve cryptosystem standard functions. The algorithm stores the intermediate results of calculations performed using this context.-Surenthar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Note that the HTML version of the User's Guide is out-of-date.
Please refer to the PDF document instead.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page