pub unsafe fn _mm_encodekey128_u32(
key_params: u32,
key: __m128i,
handle: *mut u8,
) -> u32
🔬This is a nightly-only experimental API. (
keylocker_x86
#134813)Available on (x86 or x86-64) and target feature
kl
and x86-64 only.Expand description
Wrap a 128-bit AES key into a 384-bit key handle and stores it in handle
. Returns the control
parameter used to create the IWKey.
key_params[0]
: If set, this key can only be used by the Kernel.key_params[1]
: If set, this key can not be used to encrypt.key_params[2]
: If set, this key can not be used to decrypt.key_params[31:3]
: Reserved for future use, must be set to0
.
Note that these restrictions need hardware support, and the supported restrictions can be found by
calling __cpuid(0x19)
and checking the EAX[0:2]
bits. Failing to follow these restrictions may
result in a General Protection Exception.