---
title: HPKE.Errors
framework: cryptokit
role: symbol
role_heading: Enumeration
path: cryptokit/hpke/errors
---

# HPKE.Errors

Hybrid public key encryption (HPKE) errors that CryptoKit uses.

## Declaration

```swift
enum Errors
```

## Topics

### Enumeration Cases

- [HPKE.Errors.ciphertextTooShort](cryptokit/hpke/errors/ciphertexttooshort.md)
- [HPKE.Errors.expectedPSK](cryptokit/hpke/errors/expectedpsk.md)
- [HPKE.Errors.exportOnlyMode](cryptokit/hpke/errors/exportonlymode.md)
- [HPKE.Errors.inconsistentCiphersuiteAndKey](cryptokit/hpke/errors/inconsistentciphersuiteandkey.md)
- [HPKE.Errors.inconsistentPSKInputs](cryptokit/hpke/errors/inconsistentpskinputs.md)
- [HPKE.Errors.inconsistentParameters](cryptokit/hpke/errors/inconsistentparameters.md)
- [HPKE.Errors.outOfRangeSequenceNumber](cryptokit/hpke/errors/outofrangesequencenumber.md)
- [HPKE.Errors.unexpectedPSK](cryptokit/hpke/errors/unexpectedpsk.md)

## Relationships

### Conforms To

- [Equatable](swift/equatable.md)
- [Error](swift/error.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)
