diff --git a/Package.swift b/Package.swift index b143760..7c245b4 100644 --- a/Package.swift +++ b/Package.swift @@ -14,7 +14,7 @@ let package = Package( ], dependencies: [ // Dependencies declare other packages that this package depends on. - .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.13.0"), + .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.14.0"), .package(url: "https://github.com/leif-ibsen/ASN1", from: "2.1.0"), ], targets: [ diff --git a/README.md b/README.md index 70681e5..f83856b 100755 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@
KEM | Sender | Recipient |
---|---|---|
P256 | 7 mSec | 6 mSec |
P384 | 20 mSec | 17 mSec |
P521 | 46 mSec | 39 mSec |
X25519 | 0.14 mSec | 0.09 mSec |
X448 | 1.1 mSec | 0.5 mSec |
AEAD | Encryption speed | Decryption speed |
---|---|---|
AESGCM128 | 3500 MB/Sec (0.91 cycles / byte) | 3340 MB/Sec (0.96 cycles / byte) |
AESGCM256 | 3640 MB/Sec (0.88 cycles / byte) | 3630 MB/Sec (0.88 cycles / byte) |
CHACHAPOLY | 555 MB/Sec (5.8 cycles / byte) | 557 MB/Sec (5.7 cycles / byte) |
Recipient
- -Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
The decryption of the messages must be done in the order in which they were encrypted
+The decryption of the messages must be done in the order in which they were encrypted.
+A Recipient instance can also retrieve a generated export secret.
Sender
- -Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
A Sender instance can also generate an export secret that only the recipient can know.
+ See moreRecipient
- -Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
The decryption of the messages must be done in the order in which they were encrypted
+The decryption of the messages must be done in the order in which they were encrypted.
+A Recipient instance can also retrieve a generated export secret.
Sender
- -Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
A Sender instance can also generate an export secret that only the recipient can know.
+A HPKE CipherSuite
- -A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) +
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) and a AEAD Encryption Algorithm (AEAD). It can encrypt or decrypt a single message in one of four modes:
@@ -184,9 +182,7 @@A HPKE private key
- -There are five different private key types corresponding to the five KEM’s
+There are five different private key types corresponding to the five KEM’s
A HPKE public key
- -There are five different public key types corresponding to the five KEM’s
+There are five different public key types corresponding to the five KEM’s
A HPKE CipherSuite
- -A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) +
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) and a AEAD Encryption Algorithm (AEAD). It can encrypt or decrypt a single message in one of four modes:
@@ -2359,7 +2357,7 @@A HPKE private key
- -There are five different private key types corresponding to the five KEM’s
+There are five different private key types corresponding to the five KEM’s
A HPKE public key
- -There are five different public key types corresponding to the five KEM’s
+There are five different public key types corresponding to the five KEM’s
Creates a PublicKey from its type and key bytes
+Creates a PublicKey from its type and key bytes.
+For types P256, P384 and P521 the key bytes represents
+either a compressed curve point or an uncompressed curve point.
Throws
An exception if bytes has wrong size for the key type @@ -535,7 +535,7 @@Recipient
- -Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
The decryption of the messages must be done in the order in which they were encrypted
+The decryption of the messages must be done in the order in which they were encrypted.
+A Recipient instance can also retrieve a generated export secret.
Sender
- -Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
A Sender instance can also generate an export secret that only the recipient can know.
+ See moreRecipient
- -Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
The decryption of the messages must be done in the order in which they were encrypted
+The decryption of the messages must be done in the order in which they were encrypted.
+A Recipient instance can also retrieve a generated export secret.
Sender
- -Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
+Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
A Sender instance can also generate an export secret that only the recipient can know.
+A HPKE CipherSuite
- -A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) +
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) and a AEAD Encryption Algorithm (AEAD). It can encrypt or decrypt a single message in one of four modes:
@@ -184,9 +182,7 @@A HPKE private key
- -There are five different private key types corresponding to the five KEM’s
+There are five different private key types corresponding to the five KEM’s
A HPKE public key
- -There are five different public key types corresponding to the five KEM’s
+There are five different public key types corresponding to the five KEM’s
A HPKE CipherSuite
- -A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) +
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF) and a AEAD Encryption Algorithm (AEAD). It can encrypt or decrypt a single message in one of four modes:
@@ -2359,7 +2357,7 @@A HPKE private key
- -There are five different private key types corresponding to the five KEM’s
+There are five different private key types corresponding to the five KEM’s
A HPKE public key
- -There are five different public key types corresponding to the five KEM’s
+There are five different public key types corresponding to the five KEM’s
Creates a PublicKey from its type and key bytes
+Creates a PublicKey from its type and key bytes.
+For types P256, P384 and P521 the key bytes represents
+either a compressed curve point or an uncompressed curve point.
Throws
An exception if bytes has wrong size for the key type @@ -535,7 +535,7 @@In your project Package.swift file add a dependency like
dependencies: [
- .package(url: "https://github.com/leif-ibsen/SwiftHPKE", from: "1.3.0"),
+ .package(url: "https://github.com/leif-ibsen/SwiftHPKE", from: "1.4.0"),
]
@@ -364,32 +365,55 @@ The SwiftHPKE keys of type .P256, .P384, .P521 and .X25519 are equivalent to CryptoKit keys of type P256, P384, P521 and Curve25519. Keys of type .X448 is not supported in CryptoKit.
-To convert CryptoKit P256 keys (similarly for P384 and P521) - say cc256priv and cc256pub:
-let hpke256priv = try PrivateKey(der: Bytes(cc256priv.derRepresentation))
-let hpke256pub = try PublicKey(der: Bytes(cc256pub.derRepresentation))
+To convert CryptoKit P256 keys (similarly for P384 and P521) - say ckPriv and ckPub to SwiftHPKE keys:
+let hpkePriv = try PrivateKey(der: Bytes(ckPriv.derRepresentation))
+let hpkePub = try PublicKey(der: Bytes(ckPub.derRepresentation))
-To convert CryptoKit Curve25519 keys - say cc25519priv and cc25519pub:
-let hpke25519priv = try PrivateKey(kem: .X25519, bytes: Bytes(cc25519priv.rawRepresentation))
-let hpke25519pub = try PublicKey(kem: .X25519, bytes: Bytes(cc25519pub.rawRepresentation))
+To convert CryptoKit Curve25519 keys - say ckPriv and ckPub to SwiftHPKE keys:
+let hpkePriv = try PrivateKey(kem: .X25519, bytes: Bytes(ckPriv.rawRepresentation))
+let hpkePub = try PublicKey(kem: .X25519, bytes: Bytes(ckPub.rawRepresentation))
-To convert SwiftHPKE .P256 keys (similarly for .P384 and .P521) - say hpke256priv and hpke256pub:
-let cc256priv = try CryptoKit.P256.KeyAgreement.PrivateKey(derRepresentation: hpke256priv.der)
-let cc256pub = try CryptoKit.P256.KeyAgreement.PublicKey(derRepresentation: hpke256pub.der)
+To convert SwiftHPKE .P256 keys (similarly for .P384 and .P521) - say hpkePriv and hpkePub to CryptoKit keys:
+let ckPriv = try CryptoKit.P256.KeyAgreement.PrivateKey(derRepresentation: hpkePriv.der)
+let ckPub = try CryptoKit.P256.KeyAgreement.PublicKey(derRepresentation: hpkePub.der)
-To convert SwiftHPKE .X25519 keys - say hpke25519priv and hpke25519pub:
-let cc25519priv = try CryptoKit.Curve25519.KeyAgreement.PrivateKey(rawRepresentation: hpke25519priv.bytes)
-let cc25519pub = try CryptoKit.Curve25519.KeyAgreement.PublicKey(rawRepresentation: hpke25519pub.bytes)
+To convert SwiftHPKE .X25519 keys - say hpkePriv and hpkePub to CryptoKit keys:
+let ckPriv = try CryptoKit.Curve25519.KeyAgreement.PrivateKey(rawRepresentation: hpkePriv.bytes)
+let ckPub = try CryptoKit.Curve25519.KeyAgreement.PublicKey(rawRepresentation: hpkePub.bytes)
+Performance
+
+SwiftHPKE’s encryption and decryption performance was measured on an iMac 2021, Apple M1 chip.
+The time to create a Sender and Recipient instance in base mode is shown in the table below, depending on the KEM type - units are milliseconds.
+
+
+KEM Sender Recipient
+P256 7 mSec 6 mSec
+P384 20 mSec 17 mSec
+P521 46 mSec 39 mSec
+X25519 0.14 mSec 0.09 mSec
+X448 1.1 mSec 0.5 mSec
+
+
+The encryption and decryption speed in base mode, once the Sender or Recipient instance is created, is shown in the table below, depending on the AEAD type - units are MBytes / Sec.
+
+
+AEAD Encryption speed Decryption speed
+AESGCM128 3500 MB/Sec (0.91 cycles / byte) 3340 MB/Sec (0.96 cycles / byte)
+AESGCM256 3640 MB/Sec (0.88 cycles / byte) 3630 MB/Sec (0.88 cycles / byte)
+CHACHAPOLY 555 MB/Sec (5.8 cycles / byte) 557 MB/Sec (5.7 cycles / byte)
+
+
Dependencies
The SwiftHPKE package depends on the ASN1 and BigInt packages
dependencies: [
.package(url: "https://github.com/leif-ibsen/ASN1", from: "2.1.0"),
- .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.13.0"),
+ .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.14.0"),
],
@@ -410,7 +434,7 @@ References
diff --git a/docs/docsets/SwiftHPKE.docset/Contents/Resources/Documents/search.json b/docs/docsets/SwiftHPKE.docset/Contents/Resources/Documents/search.json
index 230bb12..0768c2d 100644
--- a/docs/docsets/SwiftHPKE.docset/Contents/Resources/Documents/search.json
+++ b/docs/docsets/SwiftHPKE.docset/Contents/Resources/Documents/search.json
@@ -1 +1 @@
-{"Typealiases.html#/s:9SwiftHPKE4Bytea":{"name":"Byte","abstract":"Unsigned 8 bit value
"},"Typealiases.html#/s:9SwiftHPKE5Bytesa":{"name":"Bytes","abstract":"Array of unsigned 8 bit values
"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PublicKey from its type and key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PublicKey from its DER encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PublicKey from its PEM encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two public keys
","parent_name":"PublicKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PrivateKey from its type and key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PrivateKey from its DER encoding
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PrivateKey from its PEM encoding.
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV06publicD0AA06PublicD0Vvp":{"name":"publicKey","abstract":"The corresponding public key
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two private keys
","parent_name":"PrivateKey"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kem3kdf4aeadAcA3KEMO_AA3KDFOAA4AEADOtcfc":{"name":"init(kem:kdf:aead:)","abstract":"Creates a CipherSuite instance
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kemAA3KEMOvp":{"name":"kem","abstract":"The key encapsulation mechanism
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kdfAA3KDFOvp":{"name":"kdf","abstract":"The key derivation function
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4aeadAA4AEADOvp":{"name":"aead","abstract":"The AEAD encryption algorithm
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11descriptionSSvp":{"name":"description","abstract":"A textual representation of self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13deriveKeyPair3ikmAA06PublicF0V_AA07PrivateF0VtSays5UInt8VG_tKF":{"name":"deriveKeyPair(ikm:)","abstract":"Derives a public- and private HPKE key pair for self based on keying material
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11makeKeyPairAA06PublicF0V_AA07PrivateF0VtyKF":{"name":"makeKeyPair()","abstract":"Generates a public- and private HPKE key pair for self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info2pt3aadSays5UInt8VG5encap_AK2cttAA06PublicG0V_A3KtKF":{"name":"seal(publicKey:info:pt:aad:)","abstract":"Single-shot encryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A4LtKF":{"name":"open(privateKey:info:ct:aad:encap:)","abstract":"Single-shot decryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1LSays5UInt8VG012encapsulatedH0_AK6secrettAA06PublicH0V_A2KSitKF":{"name":"sendExport(publicKey:info:context:L:)","abstract":"Generate an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L5encapSays5UInt8VGAA07PrivateH0V_A2LSiALtKF":{"name":"receiveExport(privateKey:info:context:L:encap:)","abstract":"Retrieve an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info3psk0I2Id2pt3aadSays5UInt8VG5encap_AM2cttAA06PublicG0V_A5MtKF":{"name":"seal(publicKey:info:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info3psk0I2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A6NtKF":{"name":"open(privateKey:info:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L3psk0K2IdSays5UInt8VG012encapsulatedH0_AM6secrettAA06PublicH0V_A2MSiA2MtKF":{"name":"sendExport(publicKey:info:context:L:psk:pskId:)","abstract":"Generate an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L3psk0K2Id5encapSays5UInt8VGAA07PrivateH0V_A2NSiA3NtKF":{"name":"receiveExport(privateKey:info:context:L:psk:pskId:encap:)","abstract":"Retrieve an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication2pt3aadSays5UInt8VG5encap_AL2cttAA06PublicG0V_AlA07PrivateG0VA2LtKF":{"name":"seal(publicKey:info:authentication:pt:aad:)","abstract":"Single-shot encryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AmA06PublicG0VA3MtKF":{"name":"open(privateKey:info:authentication:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authenticationSays5UInt8VG012encapsulatedH0_AL6secrettAA06PublicH0V_A2LSiAA07PrivateH0VtKF":{"name":"sendExport(publicKey:info:context:L:authentication:)","abstract":"Generate an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication5encapSays5UInt8VGAA07PrivateH0V_A2MSiAA06PublicH0VAMtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:encap:)","abstract":"Retrieve an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication3psk0J2Id2pt3aadSays5UInt8VG5encap_AN2cttAA06PublicG0V_AnA07PrivateG0VA4NtKF":{"name":"seal(publicKey:info:authentication:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication3psk0J2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AoA06PublicG0VA5OtKF":{"name":"open(privateKey:info:authentication:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authentication3psk0L2IdSays5UInt8VG012encapsulatedH0_AN6secrettAA06PublicH0V_A2NSiAA07PrivateH0VA2NtKF":{"name":"sendExport(publicKey:info:context:L:authentication:psk:pskId:)","abstract":"Generate an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication3psk0L2Id5encapSays5UInt8VGAA07PrivateH0V_A2OSiAA06PublicH0VA3OtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:psk:pskId:encap:)","abstract":"Retrieve an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemEncodeySSSays5UInt8VG_SStFZ":{"name":"pemEncode(_:_:)","abstract":"PEM encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemDecodeySays5UInt8VGSS_SStKFZ":{"name":"pemDecode(_:_:)","abstract":"PEM decodes a string
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6encodeySSSays5UInt8VG_SitFZ":{"name":"encode(_:_:)","abstract":"Base64 encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6decodeySays5UInt8VGSSKFZ":{"name":"decode(_:)","abstract":"Base64 decodes a string
","parent_name":"Base64"},"Structs/Base64.html":{"name":"Base64","abstract":"There is no Base64 instances."},"Structs/CipherSuite.html":{"name":"CipherSuite","abstract":"
A HPKE CipherSuite
"},"Structs/PrivateKey.html":{"name":"PrivateKey","abstract":"A HPKE private key
"},"Structs/PublicKey.html":{"name":"PublicKey","abstract":"A HPKE public key
"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P256yA2CmF":{"name":"P256","abstract":"P256 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P384yA2CmF":{"name":"P384","abstract":"P384 - HKDF-SHA384
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P521yA2CmF":{"name":"P521","abstract":"P521 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO6X25519yA2CmF":{"name":"X25519","abstract":"X25519 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4X448yA2CmF":{"name":"X448","abstract":"X448 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF256yA2CmF":{"name":"KDF256","abstract":"HKDF-SHA256
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF384yA2CmF":{"name":"KDF384","abstract":"HKDF-SHA384
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF512yA2CmF":{"name":"KDF512","abstract":"HKDF-SHA512
","parent_name":"KDF"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO6base64yA2CmF":{"name":"base64","abstract":"Base64 decoding exception
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO13asn1StructureyA2CmF":{"name":"asn1Structure","abstract":"ASN1 structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO12pemStructureyA2CmF":{"name":"pemStructure","abstract":"PEM structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11decodePointyA2CmF":{"name":"decodePoint","abstract":"Decode point error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15derivedKeyErroryA2CmF":{"name":"derivedKeyError","abstract":"Derived key error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15exportOnlyErroryA2CmF":{"name":"exportOnlyError","abstract":"Export only error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10exportSizeyA2CmF":{"name":"exportSize","abstract":"Export size is negative or too large
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11keyMismatchyA2CmF":{"name":"keyMismatch","abstract":"CipherSuite key mismatch
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO19privateKeyParameteryA2CmF":{"name":"privateKeyParameter","abstract":"Invalid parameter to PrivateKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO8pskErroryA2CmF":{"name":"pskError","abstract":"Inconsistent PSK parameters
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO18publicKeyParameteryA2CmF":{"name":"publicKeyParameter","abstract":"Invalid parameter to PublicKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10smallOrderyA2CmF":{"name":"smallOrder","abstract":"X25519, X448 small order error
","parent_name":"HPKEException"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM128yA2CmF":{"name":"AESGCM128","abstract":"AES-128-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM256yA2CmF":{"name":"AESGCM256","abstract":"AES-256-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10CHACHAPOLYyA2CmF":{"name":"CHACHAPOLY","abstract":"ChaCha20-Poly1305
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10EXPORTONLYyA2CmF":{"name":"EXPORTONLY","abstract":"Export Only
","parent_name":"AEAD"},"Enums/AEAD.html":{"name":"AEAD","abstract":"AEAD Encryption Algorithms
"},"Enums/HPKEException.html":{"name":"HPKEException","abstract":"HPKE exceptions
"},"Enums/KDF.html":{"name":"KDF","abstract":"Key Derivation Functions
"},"Enums/KEM.html":{"name":"KEM","abstract":"Key Encapsulation Mechanisms
"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4infoAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGtKcfc":{"name":"init(suite:publicKey:info:)","abstract":"Creates a Sender instance in base mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info3psk0H2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGA2OtKcfc":{"name":"init(suite:publicKey:info:psk:pskId:)","abstract":"Creates a Sender instance in preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authenticationAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VtKcfc":{"name":"init(suite:publicKey:info:authentication:)","abstract":"Creates a Sender instance in authenticated mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authentication3psk0I2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VA2PtKcfc":{"name":"init(suite:publicKey:info:authentication:psk:pskId:)","abstract":"Creates a Sender instance in authenticated, preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC15encapsulatedKeySays5UInt8VGvp":{"name":"encapsulatedKey","abstract":"The encapsulated key
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC4seal2pt3aadSays5UInt8VGAI_AItKF":{"name":"seal(pt:aad:)","abstract":"Encrypts a message
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC10sendExport7context1LSays5UInt8VGAI_SitKF":{"name":"sendExport(context:L:)","abstract":"Generate an export secret
","parent_name":"Sender"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGANtKcfc":{"name":"init(suite:privateKey:info:encap:)","abstract":"Creates a Recipient instance in base mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info3psk0H2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGA3PtKcfc":{"name":"init(suite:privateKey:info:psk:pskId:encap:)","abstract":"Creates a Recipient instance in preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VAOtKcfc":{"name":"init(suite:privateKey:info:authentication:encap:)","abstract":"Creates a Recipient instance in authenticated mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication3psk0I2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VA3QtKcfc":{"name":"init(suite:privateKey:info:authentication:psk:pskId:encap:)","abstract":"Creates a Recipient instance in authenticated, preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC4open2ct3aadSays5UInt8VGAI_AItKF":{"name":"open(ct:aad:)","abstract":"Decrypts a message
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC13receiveExport7context1LSays5UInt8VGAI_SitKF":{"name":"receiveExport(context:L:)","abstract":"Retrieve an export secret
","parent_name":"Recipient"},"Classes/Recipient.html":{"name":"Recipient","abstract":"Recipient
"},"Classes/Sender.html":{"name":"Sender","abstract":"Sender
"},"Classes.html":{"name":"Classes","abstract":"The following classes are available globally.
"},"Enums.html":{"name":"Enumerations","abstract":"The following enumerations are available globally.
"},"Structs.html":{"name":"Structures","abstract":"The following structures are available globally.
"},"Typealiases.html":{"name":"Type Aliases","abstract":"The following type aliases are available globally.
"}}
\ No newline at end of file
+{"Typealiases.html#/s:9SwiftHPKE4Bytea":{"name":"Byte","abstract":"Unsigned 8 bit value
"},"Typealiases.html#/s:9SwiftHPKE5Bytesa":{"name":"Bytes","abstract":"Array of unsigned 8 bit values
"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PublicKey from its type and key bytes.
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"
Creates a PublicKey from its DER encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PublicKey from its PEM encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two public keys
","parent_name":"PublicKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PrivateKey from its type and key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PrivateKey from its DER encoding
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PrivateKey from its PEM encoding.
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV06publicD0AA06PublicD0Vvp":{"name":"publicKey","abstract":"The corresponding public key
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two private keys
","parent_name":"PrivateKey"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kem3kdf4aeadAcA3KEMO_AA3KDFOAA4AEADOtcfc":{"name":"init(kem:kdf:aead:)","abstract":"Creates a CipherSuite instance
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kemAA3KEMOvp":{"name":"kem","abstract":"The key encapsulation mechanism
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kdfAA3KDFOvp":{"name":"kdf","abstract":"The key derivation function
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4aeadAA4AEADOvp":{"name":"aead","abstract":"The AEAD encryption algorithm
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11descriptionSSvp":{"name":"description","abstract":"A textual representation of self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13deriveKeyPair3ikmAA06PublicF0V_AA07PrivateF0VtSays5UInt8VG_tKF":{"name":"deriveKeyPair(ikm:)","abstract":"Derives a public- and private HPKE key pair for self based on keying material
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11makeKeyPairAA06PublicF0V_AA07PrivateF0VtyKF":{"name":"makeKeyPair()","abstract":"Generates a public- and private HPKE key pair for self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info2pt3aadSays5UInt8VG5encap_AK2cttAA06PublicG0V_A3KtKF":{"name":"seal(publicKey:info:pt:aad:)","abstract":"Single-shot encryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A4LtKF":{"name":"open(privateKey:info:ct:aad:encap:)","abstract":"Single-shot decryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1LSays5UInt8VG012encapsulatedH0_AK6secrettAA06PublicH0V_A2KSitKF":{"name":"sendExport(publicKey:info:context:L:)","abstract":"Generate an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L5encapSays5UInt8VGAA07PrivateH0V_A2LSiALtKF":{"name":"receiveExport(privateKey:info:context:L:encap:)","abstract":"Retrieve an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info3psk0I2Id2pt3aadSays5UInt8VG5encap_AM2cttAA06PublicG0V_A5MtKF":{"name":"seal(publicKey:info:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info3psk0I2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A6NtKF":{"name":"open(privateKey:info:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L3psk0K2IdSays5UInt8VG012encapsulatedH0_AM6secrettAA06PublicH0V_A2MSiA2MtKF":{"name":"sendExport(publicKey:info:context:L:psk:pskId:)","abstract":"Generate an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L3psk0K2Id5encapSays5UInt8VGAA07PrivateH0V_A2NSiA3NtKF":{"name":"receiveExport(privateKey:info:context:L:psk:pskId:encap:)","abstract":"Retrieve an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication2pt3aadSays5UInt8VG5encap_AL2cttAA06PublicG0V_AlA07PrivateG0VA2LtKF":{"name":"seal(publicKey:info:authentication:pt:aad:)","abstract":"Single-shot encryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AmA06PublicG0VA3MtKF":{"name":"open(privateKey:info:authentication:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authenticationSays5UInt8VG012encapsulatedH0_AL6secrettAA06PublicH0V_A2LSiAA07PrivateH0VtKF":{"name":"sendExport(publicKey:info:context:L:authentication:)","abstract":"Generate an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication5encapSays5UInt8VGAA07PrivateH0V_A2MSiAA06PublicH0VAMtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:encap:)","abstract":"Retrieve an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication3psk0J2Id2pt3aadSays5UInt8VG5encap_AN2cttAA06PublicG0V_AnA07PrivateG0VA4NtKF":{"name":"seal(publicKey:info:authentication:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication3psk0J2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AoA06PublicG0VA5OtKF":{"name":"open(privateKey:info:authentication:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authentication3psk0L2IdSays5UInt8VG012encapsulatedH0_AN6secrettAA06PublicH0V_A2NSiAA07PrivateH0VA2NtKF":{"name":"sendExport(publicKey:info:context:L:authentication:psk:pskId:)","abstract":"Generate an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication3psk0L2Id5encapSays5UInt8VGAA07PrivateH0V_A2OSiAA06PublicH0VA3OtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:psk:pskId:encap:)","abstract":"Retrieve an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemEncodeySSSays5UInt8VG_SStFZ":{"name":"pemEncode(_:_:)","abstract":"PEM encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemDecodeySays5UInt8VGSS_SStKFZ":{"name":"pemDecode(_:_:)","abstract":"PEM decodes a string
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6encodeySSSays5UInt8VG_SitFZ":{"name":"encode(_:_:)","abstract":"Base64 encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6decodeySays5UInt8VGSSKFZ":{"name":"decode(_:)","abstract":"Base64 decodes a string
","parent_name":"Base64"},"Structs/Base64.html":{"name":"Base64","abstract":"There is no Base64 instances."},"Structs/CipherSuite.html":{"name":"CipherSuite","abstract":"
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF)"},"Structs/PrivateKey.html":{"name":"PrivateKey","abstract":"
There are five different private key types corresponding to the five KEM’s
"},"Structs/PublicKey.html":{"name":"PublicKey","abstract":"There are five different public key types corresponding to the five KEM’s
"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P256yA2CmF":{"name":"P256","abstract":"P256 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P384yA2CmF":{"name":"P384","abstract":"P384 - HKDF-SHA384
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P521yA2CmF":{"name":"P521","abstract":"P521 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO6X25519yA2CmF":{"name":"X25519","abstract":"X25519 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4X448yA2CmF":{"name":"X448","abstract":"X448 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF256yA2CmF":{"name":"KDF256","abstract":"HKDF-SHA256
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF384yA2CmF":{"name":"KDF384","abstract":"HKDF-SHA384
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF512yA2CmF":{"name":"KDF512","abstract":"HKDF-SHA512
","parent_name":"KDF"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO6base64yA2CmF":{"name":"base64","abstract":"Base64 decoding exception
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO13asn1StructureyA2CmF":{"name":"asn1Structure","abstract":"ASN1 structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO12pemStructureyA2CmF":{"name":"pemStructure","abstract":"PEM structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11decodePointyA2CmF":{"name":"decodePoint","abstract":"Decode point error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15derivedKeyErroryA2CmF":{"name":"derivedKeyError","abstract":"Derived key error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15exportOnlyErroryA2CmF":{"name":"exportOnlyError","abstract":"Export only error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10exportSizeyA2CmF":{"name":"exportSize","abstract":"Export size is negative or too large
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11keyMismatchyA2CmF":{"name":"keyMismatch","abstract":"CipherSuite key mismatch
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO19privateKeyParameteryA2CmF":{"name":"privateKeyParameter","abstract":"Invalid parameter to PrivateKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO8pskErroryA2CmF":{"name":"pskError","abstract":"Inconsistent PSK parameters
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO18publicKeyParameteryA2CmF":{"name":"publicKeyParameter","abstract":"Invalid parameter to PublicKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10smallOrderyA2CmF":{"name":"smallOrder","abstract":"X25519, X448 small order error
","parent_name":"HPKEException"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM128yA2CmF":{"name":"AESGCM128","abstract":"AES-128-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM256yA2CmF":{"name":"AESGCM256","abstract":"AES-256-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10CHACHAPOLYyA2CmF":{"name":"CHACHAPOLY","abstract":"ChaCha20-Poly1305
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10EXPORTONLYyA2CmF":{"name":"EXPORTONLY","abstract":"Export Only
","parent_name":"AEAD"},"Enums/AEAD.html":{"name":"AEAD","abstract":"AEAD Encryption Algorithms
"},"Enums/HPKEException.html":{"name":"HPKEException","abstract":"HPKE exceptions
"},"Enums/KDF.html":{"name":"KDF","abstract":"Key Derivation Functions
"},"Enums/KEM.html":{"name":"KEM","abstract":"Key Encapsulation Mechanisms
"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4infoAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGtKcfc":{"name":"init(suite:publicKey:info:)","abstract":"Creates a Sender instance in base mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info3psk0H2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGA2OtKcfc":{"name":"init(suite:publicKey:info:psk:pskId:)","abstract":"Creates a Sender instance in preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authenticationAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VtKcfc":{"name":"init(suite:publicKey:info:authentication:)","abstract":"Creates a Sender instance in authenticated mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authentication3psk0I2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VA2PtKcfc":{"name":"init(suite:publicKey:info:authentication:psk:pskId:)","abstract":"Creates a Sender instance in authenticated, preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC15encapsulatedKeySays5UInt8VGvp":{"name":"encapsulatedKey","abstract":"The encapsulated key
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC4seal2pt3aadSays5UInt8VGAI_AItKF":{"name":"seal(pt:aad:)","abstract":"Encrypts a message
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC10sendExport7context1LSays5UInt8VGAI_SitKF":{"name":"sendExport(context:L:)","abstract":"Generate an export secret
","parent_name":"Sender"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGANtKcfc":{"name":"init(suite:privateKey:info:encap:)","abstract":"Creates a Recipient instance in base mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info3psk0H2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGA3PtKcfc":{"name":"init(suite:privateKey:info:psk:pskId:encap:)","abstract":"Creates a Recipient instance in preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VAOtKcfc":{"name":"init(suite:privateKey:info:authentication:encap:)","abstract":"Creates a Recipient instance in authenticated mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication3psk0I2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VA3QtKcfc":{"name":"init(suite:privateKey:info:authentication:psk:pskId:encap:)","abstract":"Creates a Recipient instance in authenticated, preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC4open2ct3aadSays5UInt8VGAI_AItKF":{"name":"open(ct:aad:)","abstract":"Decrypts a message
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC13receiveExport7context1LSays5UInt8VGAI_SitKF":{"name":"receiveExport(context:L:)","abstract":"Retrieve an export secret
","parent_name":"Recipient"},"Classes/Recipient.html":{"name":"Recipient","abstract":"Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
"},"Classes/Sender.html":{"name":"Sender","abstract":"Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
"},"Classes.html":{"name":"Classes","abstract":"The following classes are available globally.
"},"Enums.html":{"name":"Enumerations","abstract":"The following enumerations are available globally.
"},"Structs.html":{"name":"Structures","abstract":"The following structures are available globally.
"},"Typealiases.html":{"name":"Type Aliases","abstract":"The following type aliases are available globally.
"}}
\ No newline at end of file
diff --git a/docs/docsets/SwiftHPKE.tgz b/docs/docsets/SwiftHPKE.tgz
index 75c9b28..b4110cd 100644
Binary files a/docs/docsets/SwiftHPKE.tgz and b/docs/docsets/SwiftHPKE.tgz differ
diff --git a/docs/index.html b/docs/index.html
index 6caaa46..e9f8c53 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -108,6 +108,7 @@ Contents:
- Encryption and Decryption
- Secret Export
- CryptoKit Compatibility
+- Performance
- Dependencies
- References
@@ -118,7 +119,7 @@ Usage
In your project Package.swift file add a dependency like
dependencies: [
- .package(url: "https://github.com/leif-ibsen/SwiftHPKE", from: "1.3.0"),
+ .package(url: "https://github.com/leif-ibsen/SwiftHPKE", from: "1.4.0"),
]
@@ -364,32 +365,55 @@ Compatibility with Apple’s CryptoKit Framework
The SwiftHPKE keys of type .P256, .P384, .P521 and .X25519 are equivalent to
CryptoKit keys of type P256, P384, P521 and Curve25519. Keys of type .X448 is not supported in CryptoKit.
-To convert CryptoKit P256 keys (similarly for P384 and P521) - say cc256priv and cc256pub:
-let hpke256priv = try PrivateKey(der: Bytes(cc256priv.derRepresentation))
-let hpke256pub = try PublicKey(der: Bytes(cc256pub.derRepresentation))
+To convert CryptoKit P256 keys (similarly for P384 and P521) - say ckPriv and ckPub to SwiftHPKE keys:
+let hpkePriv = try PrivateKey(der: Bytes(ckPriv.derRepresentation))
+let hpkePub = try PublicKey(der: Bytes(ckPub.derRepresentation))
-To convert CryptoKit Curve25519 keys - say cc25519priv and cc25519pub:
-let hpke25519priv = try PrivateKey(kem: .X25519, bytes: Bytes(cc25519priv.rawRepresentation))
-let hpke25519pub = try PublicKey(kem: .X25519, bytes: Bytes(cc25519pub.rawRepresentation))
+To convert CryptoKit Curve25519 keys - say ckPriv and ckPub to SwiftHPKE keys:
+let hpkePriv = try PrivateKey(kem: .X25519, bytes: Bytes(ckPriv.rawRepresentation))
+let hpkePub = try PublicKey(kem: .X25519, bytes: Bytes(ckPub.rawRepresentation))
-To convert SwiftHPKE .P256 keys (similarly for .P384 and .P521) - say hpke256priv and hpke256pub:
-let cc256priv = try CryptoKit.P256.KeyAgreement.PrivateKey(derRepresentation: hpke256priv.der)
-let cc256pub = try CryptoKit.P256.KeyAgreement.PublicKey(derRepresentation: hpke256pub.der)
+To convert SwiftHPKE .P256 keys (similarly for .P384 and .P521) - say hpkePriv and hpkePub to CryptoKit keys:
+let ckPriv = try CryptoKit.P256.KeyAgreement.PrivateKey(derRepresentation: hpkePriv.der)
+let ckPub = try CryptoKit.P256.KeyAgreement.PublicKey(derRepresentation: hpkePub.der)
-To convert SwiftHPKE .X25519 keys - say hpke25519priv and hpke25519pub:
-let cc25519priv = try CryptoKit.Curve25519.KeyAgreement.PrivateKey(rawRepresentation: hpke25519priv.bytes)
-let cc25519pub = try CryptoKit.Curve25519.KeyAgreement.PublicKey(rawRepresentation: hpke25519pub.bytes)
+To convert SwiftHPKE .X25519 keys - say hpkePriv and hpkePub to CryptoKit keys:
+let ckPriv = try CryptoKit.Curve25519.KeyAgreement.PrivateKey(rawRepresentation: hpkePriv.bytes)
+let ckPub = try CryptoKit.Curve25519.KeyAgreement.PublicKey(rawRepresentation: hpkePub.bytes)
+Performance
+
+SwiftHPKE’s encryption and decryption performance was measured on an iMac 2021, Apple M1 chip.
+The time to create a Sender and Recipient instance in base mode is shown in the table below, depending on the KEM type - units are milliseconds.
+
+
+KEM Sender Recipient
+P256 7 mSec 6 mSec
+P384 20 mSec 17 mSec
+P521 46 mSec 39 mSec
+X25519 0.14 mSec 0.09 mSec
+X448 1.1 mSec 0.5 mSec
+
+
+The encryption and decryption speed in base mode, once the Sender or Recipient instance is created, is shown in the table below, depending on the AEAD type - units are MBytes / Sec.
+
+
+AEAD Encryption speed Decryption speed
+AESGCM128 3500 MB/Sec (0.91 cycles / byte) 3340 MB/Sec (0.96 cycles / byte)
+AESGCM256 3640 MB/Sec (0.88 cycles / byte) 3630 MB/Sec (0.88 cycles / byte)
+CHACHAPOLY 555 MB/Sec (5.8 cycles / byte) 557 MB/Sec (5.7 cycles / byte)
+
+
Dependencies
The SwiftHPKE package depends on the ASN1 and BigInt packages
dependencies: [
.package(url: "https://github.com/leif-ibsen/ASN1", from: "2.1.0"),
- .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.13.0"),
+ .package(url: "https://github.com/leif-ibsen/BigInt", from: "1.14.0"),
],
@@ -410,7 +434,7 @@ References
diff --git a/docs/search.json b/docs/search.json
index 230bb12..0768c2d 100644
--- a/docs/search.json
+++ b/docs/search.json
@@ -1 +1 @@
-{"Typealiases.html#/s:9SwiftHPKE4Bytea":{"name":"Byte","abstract":"Unsigned 8 bit value
"},"Typealiases.html#/s:9SwiftHPKE5Bytesa":{"name":"Bytes","abstract":"Array of unsigned 8 bit values
"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PublicKey from its type and key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PublicKey from its DER encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PublicKey from its PEM encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two public keys
","parent_name":"PublicKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PrivateKey from its type and key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PrivateKey from its DER encoding
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PrivateKey from its PEM encoding.
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV06publicD0AA06PublicD0Vvp":{"name":"publicKey","abstract":"The corresponding public key
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two private keys
","parent_name":"PrivateKey"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kem3kdf4aeadAcA3KEMO_AA3KDFOAA4AEADOtcfc":{"name":"init(kem:kdf:aead:)","abstract":"Creates a CipherSuite instance
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kemAA3KEMOvp":{"name":"kem","abstract":"The key encapsulation mechanism
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kdfAA3KDFOvp":{"name":"kdf","abstract":"The key derivation function
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4aeadAA4AEADOvp":{"name":"aead","abstract":"The AEAD encryption algorithm
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11descriptionSSvp":{"name":"description","abstract":"A textual representation of self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13deriveKeyPair3ikmAA06PublicF0V_AA07PrivateF0VtSays5UInt8VG_tKF":{"name":"deriveKeyPair(ikm:)","abstract":"Derives a public- and private HPKE key pair for self based on keying material
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11makeKeyPairAA06PublicF0V_AA07PrivateF0VtyKF":{"name":"makeKeyPair()","abstract":"Generates a public- and private HPKE key pair for self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info2pt3aadSays5UInt8VG5encap_AK2cttAA06PublicG0V_A3KtKF":{"name":"seal(publicKey:info:pt:aad:)","abstract":"Single-shot encryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A4LtKF":{"name":"open(privateKey:info:ct:aad:encap:)","abstract":"Single-shot decryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1LSays5UInt8VG012encapsulatedH0_AK6secrettAA06PublicH0V_A2KSitKF":{"name":"sendExport(publicKey:info:context:L:)","abstract":"Generate an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L5encapSays5UInt8VGAA07PrivateH0V_A2LSiALtKF":{"name":"receiveExport(privateKey:info:context:L:encap:)","abstract":"Retrieve an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info3psk0I2Id2pt3aadSays5UInt8VG5encap_AM2cttAA06PublicG0V_A5MtKF":{"name":"seal(publicKey:info:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info3psk0I2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A6NtKF":{"name":"open(privateKey:info:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L3psk0K2IdSays5UInt8VG012encapsulatedH0_AM6secrettAA06PublicH0V_A2MSiA2MtKF":{"name":"sendExport(publicKey:info:context:L:psk:pskId:)","abstract":"Generate an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L3psk0K2Id5encapSays5UInt8VGAA07PrivateH0V_A2NSiA3NtKF":{"name":"receiveExport(privateKey:info:context:L:psk:pskId:encap:)","abstract":"Retrieve an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication2pt3aadSays5UInt8VG5encap_AL2cttAA06PublicG0V_AlA07PrivateG0VA2LtKF":{"name":"seal(publicKey:info:authentication:pt:aad:)","abstract":"Single-shot encryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AmA06PublicG0VA3MtKF":{"name":"open(privateKey:info:authentication:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authenticationSays5UInt8VG012encapsulatedH0_AL6secrettAA06PublicH0V_A2LSiAA07PrivateH0VtKF":{"name":"sendExport(publicKey:info:context:L:authentication:)","abstract":"Generate an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication5encapSays5UInt8VGAA07PrivateH0V_A2MSiAA06PublicH0VAMtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:encap:)","abstract":"Retrieve an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication3psk0J2Id2pt3aadSays5UInt8VG5encap_AN2cttAA06PublicG0V_AnA07PrivateG0VA4NtKF":{"name":"seal(publicKey:info:authentication:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication3psk0J2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AoA06PublicG0VA5OtKF":{"name":"open(privateKey:info:authentication:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authentication3psk0L2IdSays5UInt8VG012encapsulatedH0_AN6secrettAA06PublicH0V_A2NSiAA07PrivateH0VA2NtKF":{"name":"sendExport(publicKey:info:context:L:authentication:psk:pskId:)","abstract":"Generate an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication3psk0L2Id5encapSays5UInt8VGAA07PrivateH0V_A2OSiAA06PublicH0VA3OtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:psk:pskId:encap:)","abstract":"Retrieve an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemEncodeySSSays5UInt8VG_SStFZ":{"name":"pemEncode(_:_:)","abstract":"PEM encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemDecodeySays5UInt8VGSS_SStKFZ":{"name":"pemDecode(_:_:)","abstract":"PEM decodes a string
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6encodeySSSays5UInt8VG_SitFZ":{"name":"encode(_:_:)","abstract":"Base64 encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6decodeySays5UInt8VGSSKFZ":{"name":"decode(_:)","abstract":"Base64 decodes a string
","parent_name":"Base64"},"Structs/Base64.html":{"name":"Base64","abstract":"There is no Base64 instances."},"Structs/CipherSuite.html":{"name":"CipherSuite","abstract":"
A HPKE CipherSuite
"},"Structs/PrivateKey.html":{"name":"PrivateKey","abstract":"A HPKE private key
"},"Structs/PublicKey.html":{"name":"PublicKey","abstract":"A HPKE public key
"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P256yA2CmF":{"name":"P256","abstract":"P256 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P384yA2CmF":{"name":"P384","abstract":"P384 - HKDF-SHA384
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P521yA2CmF":{"name":"P521","abstract":"P521 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO6X25519yA2CmF":{"name":"X25519","abstract":"X25519 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4X448yA2CmF":{"name":"X448","abstract":"X448 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF256yA2CmF":{"name":"KDF256","abstract":"HKDF-SHA256
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF384yA2CmF":{"name":"KDF384","abstract":"HKDF-SHA384
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF512yA2CmF":{"name":"KDF512","abstract":"HKDF-SHA512
","parent_name":"KDF"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO6base64yA2CmF":{"name":"base64","abstract":"Base64 decoding exception
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO13asn1StructureyA2CmF":{"name":"asn1Structure","abstract":"ASN1 structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO12pemStructureyA2CmF":{"name":"pemStructure","abstract":"PEM structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11decodePointyA2CmF":{"name":"decodePoint","abstract":"Decode point error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15derivedKeyErroryA2CmF":{"name":"derivedKeyError","abstract":"Derived key error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15exportOnlyErroryA2CmF":{"name":"exportOnlyError","abstract":"Export only error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10exportSizeyA2CmF":{"name":"exportSize","abstract":"Export size is negative or too large
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11keyMismatchyA2CmF":{"name":"keyMismatch","abstract":"CipherSuite key mismatch
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO19privateKeyParameteryA2CmF":{"name":"privateKeyParameter","abstract":"Invalid parameter to PrivateKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO8pskErroryA2CmF":{"name":"pskError","abstract":"Inconsistent PSK parameters
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO18publicKeyParameteryA2CmF":{"name":"publicKeyParameter","abstract":"Invalid parameter to PublicKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10smallOrderyA2CmF":{"name":"smallOrder","abstract":"X25519, X448 small order error
","parent_name":"HPKEException"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM128yA2CmF":{"name":"AESGCM128","abstract":"AES-128-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM256yA2CmF":{"name":"AESGCM256","abstract":"AES-256-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10CHACHAPOLYyA2CmF":{"name":"CHACHAPOLY","abstract":"ChaCha20-Poly1305
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10EXPORTONLYyA2CmF":{"name":"EXPORTONLY","abstract":"Export Only
","parent_name":"AEAD"},"Enums/AEAD.html":{"name":"AEAD","abstract":"AEAD Encryption Algorithms
"},"Enums/HPKEException.html":{"name":"HPKEException","abstract":"HPKE exceptions
"},"Enums/KDF.html":{"name":"KDF","abstract":"Key Derivation Functions
"},"Enums/KEM.html":{"name":"KEM","abstract":"Key Encapsulation Mechanisms
"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4infoAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGtKcfc":{"name":"init(suite:publicKey:info:)","abstract":"Creates a Sender instance in base mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info3psk0H2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGA2OtKcfc":{"name":"init(suite:publicKey:info:psk:pskId:)","abstract":"Creates a Sender instance in preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authenticationAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VtKcfc":{"name":"init(suite:publicKey:info:authentication:)","abstract":"Creates a Sender instance in authenticated mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authentication3psk0I2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VA2PtKcfc":{"name":"init(suite:publicKey:info:authentication:psk:pskId:)","abstract":"Creates a Sender instance in authenticated, preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC15encapsulatedKeySays5UInt8VGvp":{"name":"encapsulatedKey","abstract":"The encapsulated key
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC4seal2pt3aadSays5UInt8VGAI_AItKF":{"name":"seal(pt:aad:)","abstract":"Encrypts a message
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC10sendExport7context1LSays5UInt8VGAI_SitKF":{"name":"sendExport(context:L:)","abstract":"Generate an export secret
","parent_name":"Sender"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGANtKcfc":{"name":"init(suite:privateKey:info:encap:)","abstract":"Creates a Recipient instance in base mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info3psk0H2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGA3PtKcfc":{"name":"init(suite:privateKey:info:psk:pskId:encap:)","abstract":"Creates a Recipient instance in preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VAOtKcfc":{"name":"init(suite:privateKey:info:authentication:encap:)","abstract":"Creates a Recipient instance in authenticated mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication3psk0I2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VA3QtKcfc":{"name":"init(suite:privateKey:info:authentication:psk:pskId:encap:)","abstract":"Creates a Recipient instance in authenticated, preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC4open2ct3aadSays5UInt8VGAI_AItKF":{"name":"open(ct:aad:)","abstract":"Decrypts a message
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC13receiveExport7context1LSays5UInt8VGAI_SitKF":{"name":"receiveExport(context:L:)","abstract":"Retrieve an export secret
","parent_name":"Recipient"},"Classes/Recipient.html":{"name":"Recipient","abstract":"Recipient
"},"Classes/Sender.html":{"name":"Sender","abstract":"Sender
"},"Classes.html":{"name":"Classes","abstract":"The following classes are available globally.
"},"Enums.html":{"name":"Enumerations","abstract":"The following enumerations are available globally.
"},"Structs.html":{"name":"Structures","abstract":"The following structures are available globally.
"},"Typealiases.html":{"name":"Type Aliases","abstract":"The following type aliases are available globally.
"}}
\ No newline at end of file
+{"Typealiases.html#/s:9SwiftHPKE4Bytea":{"name":"Byte","abstract":"Unsigned 8 bit value
"},"Typealiases.html#/s:9SwiftHPKE5Bytesa":{"name":"Bytes","abstract":"Array of unsigned 8 bit values
"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PublicKey from its type and key bytes.
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"
Creates a PublicKey from its DER encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PublicKey from its PEM encoding
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PublicKey"},"Structs/PublicKey.html#/s:9SwiftHPKE9PublicKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two public keys
","parent_name":"PublicKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3kem5bytesAcA3KEMO_Says5UInt8VGtKcfc":{"name":"init(kem:bytes:)","abstract":"Creates a PrivateKey from its type and key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derACSays5UInt8VG_tKcfc":{"name":"init(der:)","abstract":"Creates a PrivateKey from its DER encoding
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemACSS_tKcfc":{"name":"init(pem:)","abstract":"Creates a PrivateKey from its PEM encoding.
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV5bytesSays5UInt8VGvp":{"name":"bytes","abstract":"The serialized key bytes
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV06publicD0AA06PublicD0Vvp":{"name":"publicKey","abstract":"The corresponding public key
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV4asn14ASN1AECvp":{"name":"asn1","abstract":"The ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3derSays5UInt8VGvp":{"name":"der","abstract":"The DER encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV3pemSSvp":{"name":"pem","abstract":"The PEM base 64 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV11descriptionSSvp":{"name":"description","abstract":"A textual representation of the ASN1 encoding of self
","parent_name":"PrivateKey"},"Structs/PrivateKey.html#/s:9SwiftHPKE10PrivateKeyV2eeoiySbAC_ACtFZ":{"name":"==(_:_:)","abstract":"Equality of two private keys
","parent_name":"PrivateKey"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kem3kdf4aeadAcA3KEMO_AA3KDFOAA4AEADOtcfc":{"name":"init(kem:kdf:aead:)","abstract":"Creates a CipherSuite instance
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kemAA3KEMOvp":{"name":"kem","abstract":"The key encapsulation mechanism
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV3kdfAA3KDFOvp":{"name":"kdf","abstract":"The key derivation function
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4aeadAA4AEADOvp":{"name":"aead","abstract":"The AEAD encryption algorithm
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11descriptionSSvp":{"name":"description","abstract":"A textual representation of self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13deriveKeyPair3ikmAA06PublicF0V_AA07PrivateF0VtSays5UInt8VG_tKF":{"name":"deriveKeyPair(ikm:)","abstract":"Derives a public- and private HPKE key pair for self based on keying material
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV11makeKeyPairAA06PublicF0V_AA07PrivateF0VtyKF":{"name":"makeKeyPair()","abstract":"Generates a public- and private HPKE key pair for self
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info2pt3aadSays5UInt8VG5encap_AK2cttAA06PublicG0V_A3KtKF":{"name":"seal(publicKey:info:pt:aad:)","abstract":"Single-shot encryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A4LtKF":{"name":"open(privateKey:info:ct:aad:encap:)","abstract":"Single-shot decryption in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1LSays5UInt8VG012encapsulatedH0_AK6secrettAA06PublicH0V_A2KSitKF":{"name":"sendExport(publicKey:info:context:L:)","abstract":"Generate an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L5encapSays5UInt8VGAA07PrivateH0V_A2LSiALtKF":{"name":"receiveExport(privateKey:info:context:L:encap:)","abstract":"Retrieve an export secret in base mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info3psk0I2Id2pt3aadSays5UInt8VG5encap_AM2cttAA06PublicG0V_A5MtKF":{"name":"seal(publicKey:info:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info3psk0I2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_A6NtKF":{"name":"open(privateKey:info:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L3psk0K2IdSays5UInt8VG012encapsulatedH0_AM6secrettAA06PublicH0V_A2MSiA2MtKF":{"name":"sendExport(publicKey:info:context:L:psk:pskId:)","abstract":"Generate an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L3psk0K2Id5encapSays5UInt8VGAA07PrivateH0V_A2NSiA3NtKF":{"name":"receiveExport(privateKey:info:context:L:psk:pskId:encap:)","abstract":"Retrieve an export secret in preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication2pt3aadSays5UInt8VG5encap_AL2cttAA06PublicG0V_AlA07PrivateG0VA2LtKF":{"name":"seal(publicKey:info:authentication:pt:aad:)","abstract":"Single-shot encryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AmA06PublicG0VA3MtKF":{"name":"open(privateKey:info:authentication:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authenticationSays5UInt8VG012encapsulatedH0_AL6secrettAA06PublicH0V_A2LSiAA07PrivateH0VtKF":{"name":"sendExport(publicKey:info:context:L:authentication:)","abstract":"Generate an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication5encapSays5UInt8VGAA07PrivateH0V_A2MSiAA06PublicH0VAMtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:encap:)","abstract":"Retrieve an export secret in authenticated mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4seal9publicKey4info14authentication3psk0J2Id2pt3aadSays5UInt8VG5encap_AN2cttAA06PublicG0V_AnA07PrivateG0VA4NtKF":{"name":"seal(publicKey:info:authentication:psk:pskId:pt:aad:)","abstract":"Single-shot encryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV4open10privateKey4info14authentication3psk0J2Id2ct3aad5encapSays5UInt8VGAA07PrivateG0V_AoA06PublicG0VA5OtKF":{"name":"open(privateKey:info:authentication:psk:pskId:ct:aad:encap:)","abstract":"Single-shot decryption in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV10sendExport9publicKey4info7context1L14authentication3psk0L2IdSays5UInt8VG012encapsulatedH0_AN6secrettAA06PublicH0V_A2NSiAA07PrivateH0VA2NtKF":{"name":"sendExport(publicKey:info:context:L:authentication:psk:pskId:)","abstract":"Generate an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/CipherSuite.html#/s:9SwiftHPKE11CipherSuiteV13receiveExport10privateKey4info7context1L14authentication3psk0L2Id5encapSays5UInt8VGAA07PrivateH0V_A2OSiAA06PublicH0VA3OtKF":{"name":"receiveExport(privateKey:info:context:L:authentication:psk:pskId:encap:)","abstract":"Retrieve an export secret in authenticated, preshared key mode
","parent_name":"CipherSuite"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemEncodeySSSays5UInt8VG_SStFZ":{"name":"pemEncode(_:_:)","abstract":"PEM encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V9pemDecodeySays5UInt8VGSS_SStKFZ":{"name":"pemDecode(_:_:)","abstract":"PEM decodes a string
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6encodeySSSays5UInt8VG_SitFZ":{"name":"encode(_:_:)","abstract":"Base64 encodes a byte array
","parent_name":"Base64"},"Structs/Base64.html#/s:9SwiftHPKE6Base64V6decodeySays5UInt8VGSSKFZ":{"name":"decode(_:)","abstract":"Base64 decodes a string
","parent_name":"Base64"},"Structs/Base64.html":{"name":"Base64","abstract":"There is no Base64 instances."},"Structs/CipherSuite.html":{"name":"CipherSuite","abstract":"
A CipherSuite instance combines a Key Encapsulation Mechanism (KEM), a Key Derivation Function (KDF)"},"Structs/PrivateKey.html":{"name":"PrivateKey","abstract":"
There are five different private key types corresponding to the five KEM’s
"},"Structs/PublicKey.html":{"name":"PublicKey","abstract":"There are five different public key types corresponding to the five KEM’s
"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P256yA2CmF":{"name":"P256","abstract":"P256 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P384yA2CmF":{"name":"P384","abstract":"P384 - HKDF-SHA384
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4P521yA2CmF":{"name":"P521","abstract":"P521 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO6X25519yA2CmF":{"name":"X25519","abstract":"X25519 - HKDF-SHA256
","parent_name":"KEM"},"Enums/KEM.html#/s:9SwiftHPKE3KEMO4X448yA2CmF":{"name":"X448","abstract":"X448 - HKDF-SHA512
","parent_name":"KEM"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF256yA2CmF":{"name":"KDF256","abstract":"HKDF-SHA256
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF384yA2CmF":{"name":"KDF384","abstract":"HKDF-SHA384
","parent_name":"KDF"},"Enums/KDF.html#/s:9SwiftHPKE3KDFO6KDF512yA2CmF":{"name":"KDF512","abstract":"HKDF-SHA512
","parent_name":"KDF"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO6base64yA2CmF":{"name":"base64","abstract":"Base64 decoding exception
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO13asn1StructureyA2CmF":{"name":"asn1Structure","abstract":"ASN1 structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO12pemStructureyA2CmF":{"name":"pemStructure","abstract":"PEM structure is wrong
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11decodePointyA2CmF":{"name":"decodePoint","abstract":"Decode point error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15derivedKeyErroryA2CmF":{"name":"derivedKeyError","abstract":"Derived key error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO15exportOnlyErroryA2CmF":{"name":"exportOnlyError","abstract":"Export only error
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10exportSizeyA2CmF":{"name":"exportSize","abstract":"Export size is negative or too large
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO11keyMismatchyA2CmF":{"name":"keyMismatch","abstract":"CipherSuite key mismatch
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO19privateKeyParameteryA2CmF":{"name":"privateKeyParameter","abstract":"Invalid parameter to PrivateKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO8pskErroryA2CmF":{"name":"pskError","abstract":"Inconsistent PSK parameters
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO18publicKeyParameteryA2CmF":{"name":"publicKeyParameter","abstract":"Invalid parameter to PublicKey constructor
","parent_name":"HPKEException"},"Enums/HPKEException.html#/s:9SwiftHPKE13HPKEExceptionO10smallOrderyA2CmF":{"name":"smallOrder","abstract":"X25519, X448 small order error
","parent_name":"HPKEException"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO11descriptionSSvp":{"name":"description","abstract":"Textual description of self
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM128yA2CmF":{"name":"AESGCM128","abstract":"AES-128-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO9AESGCM256yA2CmF":{"name":"AESGCM256","abstract":"AES-256-GCM
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10CHACHAPOLYyA2CmF":{"name":"CHACHAPOLY","abstract":"ChaCha20-Poly1305
","parent_name":"AEAD"},"Enums/AEAD.html#/s:9SwiftHPKE4AEADO10EXPORTONLYyA2CmF":{"name":"EXPORTONLY","abstract":"Export Only
","parent_name":"AEAD"},"Enums/AEAD.html":{"name":"AEAD","abstract":"AEAD Encryption Algorithms
"},"Enums/HPKEException.html":{"name":"HPKEException","abstract":"HPKE exceptions
"},"Enums/KDF.html":{"name":"KDF","abstract":"Key Derivation Functions
"},"Enums/KEM.html":{"name":"KEM","abstract":"Key Encapsulation Mechanisms
"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4infoAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGtKcfc":{"name":"init(suite:publicKey:info:)","abstract":"Creates a Sender instance in base mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info3psk0H2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGA2OtKcfc":{"name":"init(suite:publicKey:info:psk:pskId:)","abstract":"Creates a Sender instance in preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authenticationAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VtKcfc":{"name":"init(suite:publicKey:info:authentication:)","abstract":"Creates a Sender instance in authenticated mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC5suite9publicKey4info14authentication3psk0I2IdAcA11CipherSuiteV_AA06PublicF0VSays5UInt8VGAA07PrivateF0VA2PtKcfc":{"name":"init(suite:publicKey:info:authentication:psk:pskId:)","abstract":"Creates a Sender instance in authenticated, preshared key mode
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC15encapsulatedKeySays5UInt8VGvp":{"name":"encapsulatedKey","abstract":"The encapsulated key
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC4seal2pt3aadSays5UInt8VGAI_AItKF":{"name":"seal(pt:aad:)","abstract":"Encrypts a message
","parent_name":"Sender"},"Classes/Sender.html#/s:9SwiftHPKE6SenderC10sendExport7context1LSays5UInt8VGAI_SitKF":{"name":"sendExport(context:L:)","abstract":"Generate an export secret
","parent_name":"Sender"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGANtKcfc":{"name":"init(suite:privateKey:info:encap:)","abstract":"Creates a Recipient instance in base mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info3psk0H2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGA3PtKcfc":{"name":"init(suite:privateKey:info:psk:pskId:encap:)","abstract":"Creates a Recipient instance in preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VAOtKcfc":{"name":"init(suite:privateKey:info:authentication:encap:)","abstract":"Creates a Recipient instance in authenticated mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC5suite10privateKey4info14authentication3psk0I2Id5encapAcA11CipherSuiteV_AA07PrivateF0VSays5UInt8VGAA06PublicF0VA3QtKcfc":{"name":"init(suite:privateKey:info:authentication:psk:pskId:encap:)","abstract":"Creates a Recipient instance in authenticated, preshared key mode
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC4open2ct3aadSays5UInt8VGAI_AItKF":{"name":"open(ct:aad:)","abstract":"Decrypts a message
","parent_name":"Recipient"},"Classes/Recipient.html#/s:9SwiftHPKE9RecipientC13receiveExport7context1LSays5UInt8VGAI_SitKF":{"name":"receiveExport(context:L:)","abstract":"Retrieve an export secret
","parent_name":"Recipient"},"Classes/Recipient.html":{"name":"Recipient","abstract":"Based on its CipherSuite, a Recipient instance can decrypt a sequence of messages in one of four modes:
"},"Classes/Sender.html":{"name":"Sender","abstract":"Based on its CipherSuite, a Sender instance can encrypt a sequence of messages in one of four modes:
"},"Classes.html":{"name":"Classes","abstract":"The following classes are available globally.
"},"Enums.html":{"name":"Enumerations","abstract":"The following enumerations are available globally.
"},"Structs.html":{"name":"Structures","abstract":"The following structures are available globally.
"},"Typealiases.html":{"name":"Type Aliases","abstract":"The following type aliases are available globally.
"}}
\ No newline at end of file