Scoop API

scoop:scoop.crypto:0.1.0

SecretKey

class SecretKey

source · line 9
public
public class SecretKey private constructor(private var handle: ULong) : Closeable

Owned native storage for symmetric key bytes. Close it after use; exporting creates a separate managed byte copy.

function close

source · line 44
public
public override fun close(): Unit

Releases native key storage; repeated closes are harmless.

function exportBytes

source · line 39
public
public fun exportBytes(): Array<Byte>

Returns a managed copy of the key material. Closing the key does not erase this separate copy.