wolfcose-sys 0.1.0

Low-level unsafe Rust bindings for wolfSSL wolfCOSE.
docs.rs failed to build wolfcose-sys-0.1.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.

wolfcose-sys

Low-level unsafe bindings for wolfSSL wolfCOSE.

By default this crate vendors the wolfCOSE C sources, pulls a pinned wolfSSL source commit into Cargo's build output, and builds wolfSSL statically. Set WOLFSSL_SRC to use a pre-fetched wolfSSL source tree, or enable system-wolfssl to link against an installed wolfSSL/wolfCrypt library.

wolfCOSE is GPL-3.0-or-later. Contact wolfSSL for commercial licensing.

Features

  • vendored builds the bundled wolfCOSE C sources. This is enabled by default.
  • vendored-wolfssl pulls/builds wolfSSL from source. This is enabled by default.
  • system-wolfssl links to an installed wolfSSL library instead.
  • system-wolfcose links to an installed wolfCOSE library instead.
  • full enables every wolfCOSE message/key/CBOR group.
  • float defines WOLFCOSE_FLOAT and enables CBOR float/double encoding.

The build script maps disabled positive Cargo features to upstream WOLFCOSE_NO_* macros. Additional C defines can be passed with WOLFCOSE_SYS_DEFINES.

The default wolfSSL fetch can be overridden with:

  • WOLFSSL_SRC=/path/to/wolfssl to use an existing source checkout.
  • WOLFCOSE_SYS_WOLFSSL_GIT=https://... to change the Git remote.
  • WOLFCOSE_SYS_WOLFSSL_REF=<tag-or-commit> to change the fetched ref.
  • WOLFCOSE_SYS_WOLFSSL_TAG=<tag> as a compatibility alias for the ref.

Bindings

Bindgen allowlists all public wc_CBOR_* and wc_Cose* functions, all public WOLFCOSE_* constants and structs, and the wolfCrypt key/RNG types referenced by the wolfCOSE API. A small C shim exposes optional APIs with stable symbols so safe Rust wrappers can return WOLFCOSE_E_UNSUPPORTED instead of disappearing when a wolfSSL feature is absent.