[package] name = "clique-sibyl-commonlib" version = "2.3.2" edition = "2018" readme = "README.md" include = ["src/**/*.rs", "README.md", "assets/**/*"] license = "Apache-2.0" description = "Clique Sibyl Common Library, for generating and verifying TEE attestation (Intel SGX, Intel TDX) and providing customized TLS verification with TEE attestation" # In rust we use `lib` as the crate-type in default. # But WASM need to use `cdylib` as the crate-type # We can't set crate-type dynamically, set both crate-type to walkaround it. # See more details in: # https://github.com/rust-lang/cargo/issues/4881 # https://github.com/rust-lang/cargo/issues/12260 [lib] crate-type = ["cdylib", "lib"] [features] # Supports custom rustls versions with feature names consistent with actix-web default = [] tdx_attest = ["libc"] rustls-0_20 = ["rustls-020", "actix-web/rustls-0_20", "awc/rustls-0_20"] rustls-0_21 = ["rustls-021", "actix-web/rustls-0_21", "awc/rustls-0_21"] rustls-0_22 = ["rustls-022", "actix-web/rustls-0_22", "awc/rustls-0_22-webpki-roots"] rustls-0_23 = ["rustls-023", "actix-web/rustls-0_23", "awc/rustls-0_23"] # You should disable default feature and rustls feature if enable wasm feature wasm = ["wasm-bindgen", "getrandom/js"] [dependencies] wasm-bindgen = { version = "0.2.92", optional = true } getrandom = { version = "0.2", optional = true } tracing = "0.1.40" serde = { version = "1.0", features = ["derive"] } serde_json = { version = "1.0", features = ["preserve_order"] } base64 = "0.21.0" hex = "0.4" hex-literal = "0.4.1" thiserror = "1.0.50" p256 = "0.13.2" k256 = "0.13.3" rsa = "0.9.2" signature = "2.2.0" sha2 = { version = "0.10", default-features = false } sha3 = "0.10.8" rand_core = "0.6.4" uuid = { version = "1.5.0", features = ["v4"] } yasna = { version = "=0.3.1", features = ["chrono", "bit-vec", "num-bigint"] } chrono = "0.4" bit-vec = { version = "0.6.3", default-features = false } pem = "3.0.2" der = { version = "0.7.8", features = ["alloc"] } x509-cert = "0.2.5" x509-parser = "0.16.0" asn1-rs = "0.6.1" # Optional dependencies for different versions of rustls rustls-020 = { package = "rustls", version = "0.20.9", features = [ "dangerous_configuration", ], optional = true } rustls-021 = { package = "rustls", version = "0.21.12", optional = true } rustls-022 = { package = "rustls", version = "0.22.4", optional = true } rustls-023 = { package = "rustls", version = "0.23.8", optional = true } libc = { version = "0.2", optional = true } [dev-dependencies] actix-web = "4.6.0" actix-rt = "2.9.0" awc = "3.5.0" tokio = { version = "1", features = ["full", "test-util"] } reqwest = { version = "0.12.5", default-features = false, features = ["rustls-tls", "blocking"] }