gmcrypto-c 1.3.0

C ABI for gmcrypto-core — cdylib + staticlib exposing SM2/SM3/SM4/HMAC/PBKDF2 to C / C++ / Python / Go / Zig callers via opaque handles
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.85"
name = "gmcrypto-c"
version = "1.3.0"
build = "build.rs"
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "C ABI for gmcrypto-core — cdylib + staticlib exposing SM2/SM3/SM4/HMAC/PBKDF2 to C / C++ / Python / Go / Zig callers via opaque handles"
readme = "README.md"
keywords = [
    "sm2",
    "sm3",
    "sm4",
    "ffi",
    "c-abi",
]
categories = [
    "cryptography",
    "api-bindings",
]
license = "Apache-2.0"
repository = "https://github.com/frankxue831/gm-crypto-rs"
resolver = "2"

[features]
default = []
regen-header = ["dep:cbindgen"]

[lib]
name = "gmcrypto_c"
crate-type = [
    "cdylib",
    "staticlib",
    "rlib",
]
path = "src/lib.rs"

[[test]]
name = "c_smoke"
path = "tests/c_smoke.rs"

[dependencies.getrandom]
version = "0.4.2"
features = ["sys_rng"]
default-features = false

[dependencies.gmcrypto-core]
version = "=1.3.0"
features = [
    "sm4-aead",
    "sm4-xts",
    "sm2-key-exchange",
]

[dependencies.rand_core]
version = "0.10.1"
default-features = false

[dev-dependencies.crypto-bigint]
version = "0.7.3"
features = [
    "subtle",
    "zeroize",
]
default-features = false

[dev-dependencies.hex-literal]
version = "1.1.0"

[build-dependencies.cbindgen]
version = "0.29"
optional = true
default-features = false

[lints.clippy]
doc_markdown = "allow"
manual_c_str_literals = "allow"
manual_let_else = "allow"
many_single_char_names = "allow"
missing_const_for_fn = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
option_if_let_else = "allow"
similar_names = "allow"
too_long_first_doc_paragraph = "allow"
unnecessary_box_returns = "allow"

[lints.clippy.nursery]
level = "warn"
priority = -1

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
missing_docs = "warn"
unsafe_code = "warn"