8 releases (5 major breaking)
128.0.1 | Jul 8, 2024 |
---|---|
127.0.1 | May 30, 2024 |
125.0.1 | Mar 28, 2024 |
123.0.1 | Feb 1, 2024 |
120.0.2 | Nov 29, 2023 |
#39 in #firefox
626 stars & 47 watchers
40KB
994 lines
nss_sys
Low-level NSS bindings for Rust.
This crate defines low-level FFI bindings for NSS. They are maintained by hand,
and their correctness is verified using the systest
crate in the parent directory.
The directory structure of this crate is meant to mirror that of NSS itself.
For each header file provided by NSS, there should be a corresponding .rs
file
in the nss_sys::bindings
module that declares the corresponding functions and
data types.
To add new bindings in this crate, you'll need to:
- Identify the NSS header file that contains the functionality of interest.
- Edit the Rust file of the corresponding name under
./src/bindings
.- If one doesn't currently exist then create it, and also add the corresponding
header to the list of headers in
../systest/build.rs
.
- If one doesn't currently exist then create it, and also add the corresponding
header to the list of headers in
- Add
#[recpr(C)]
structs andpub extern "C"
functions as necessary to make the new functionality visible to Rust. - Verify the correctness of your additions using
cargo run -p systest
in the repository root.
Dependencies
~20MB
~386K SLoC