Skip to content

How to construct a client‑side JWE using ECDH‑ES with JOSESwift? #484

@Yourney

Description

@Yourney

I’m trying to produce (not parse or decrypt) a compact JWE on the client using JOSESwift with:
JSON: {"alg": "ECDH-ES+A256KW", "enc": "A256GCM"}

I see that:

the algorithms are listed as supported
JWE has a public initializer that takes an Encrypter

What I cannot find is a public, ready-to-use Encrypter implementation for ECDH‑ES (+A256KW) that I can use from application code.
If this already exists: could you point me to the intended public API (or a minimal example) for constructing a JWE with ECDH‑ES on the client?
If it does not exist: is the expectation that users implement their own Encrypter, or is this a gap you expect to fill with a public ECDH‑ES encrypter?

I’m specifically looking for guidance on the supported way to do client-side JWE encryption with ECDH‑ES using JOSESwift.

Kind regards,
Wouter

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions