Skip to content
Daniel edited this page Mar 9, 2018 · 7 revisions

What is JOSESwift?

JOSESwift is a modular and extensible framework for the JOSE standards JWS, JWE, and JWK written in Swift.

The JOSE standards specify means of protecting data in transit using JSON data structures which can be understood across a wide range of platforms.

JOSESwift is designed with usage on iOS and on pure Swift environments in mind.

What is JOSESwift for?

  • 📝 Integrity protect data in transit
  • 🔒 Encrypt, decrypt and integrity protect data in transit
  • 🔑 Represent cryptographic keys as JSON data structures
  • 🎰 Provide platform independent and URL-safe serializations of above data representations

What platforms does JOSESwift support?

JOSESwift is designed with usage on iOS and on pure Swift environments in mind. It is ready for use on iOS out of the box. Some adaptions are needed for pure Swift environments, though:

For security reasons, JOSESwift does not implement its own cryptographic primitives. Therefore, it is dependent on the crypto implementation available on the respective platform it is being used on.

iOS provides a wide range of cryptographic functions through its Security framework and through Apple's CommonCrypto. JOSESwift provides bindings to those frameworks in JOSESwift/Sources/CryptoImplementation/.

If you use JOSESwift on a platform where Security and CommonCrypto are not available, you will need to replace the bindings in JOSESwift/Sources/CryptoImplementation/ with bindings to a crypto implementation of your choice. If you do so, feel free to submit your adaptions via a pull request, so that we can support pure Swift environments out of the box as well.

Is JOSESwift a complete implementation of the JOSE standards?

No, it is not (yet). But you are more than welcome to implement and submit additional details of the specifications via a pull request.

The following is a rough listing of already implemented features, grouped by the standards that specify them.

JWS (RFC-7515)

JWE (RFC-7516)

JWK (RFC-7517)

JWA (RFC-7518)