Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,12 @@ of the new YAML fields below until the version that ships them.
snippets instead of illustrative API fragments.
([docs/architecture.md], [docs/audit-log.md], [docs/cache-reserve.md])

- **Unsafe-code drift guardrails.** Crates that do not need unsafe now
forbid it at the crate root, while `sbproxy-vault` explicitly allows
its narrowly-scoped volatile zeroization unsafe with an inline
justification.
([crates/sbproxy-*/src/lib.rs])

- **AI client retry resilience.** `MemoryBatchStore` now uses
`parking_lot::Mutex` so a panic in one worker cannot poison the
in-memory batch map for every later operation. Provider retries now
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-ai/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-ai: AI gateway with provider routing, streaming, and guardrails.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod ai_metrics;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-cache/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-cache: Response cache and object cache management.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod reserve;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-classifiers/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
//! place it behind an [`std::sync::Arc`] and share it across worker
//! threads without an outer lock.

#![forbid(unsafe_code)]
#![deny(missing_docs)]

pub mod agent_class;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
//! - Intermediate representation ([`raw`])
//! - Compiling configs into immutable, performance-optimized snapshots ([`snapshot`], [`compiler`])

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod compiler;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
//! - [`server::SbProxy`] - Pingora `ProxyHttp` implementation
//! - [`server::run`] - Server entry point

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod admin;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-extension/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
//! sbproxy for conditional logic in routing, access control, and policy
//! enforcement.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod cel;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-httpkit/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-httpkit: HTTP utilities, buffer pool, and compression.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod bufferpool;
1 change: 1 addition & 0 deletions crates/sbproxy-k8s-operator/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
//! triple and applies it server-side. Config changes trigger a rollout-restart
//! by stamping `sbproxy.dev/config-hash` on the Deployment's pod template.

#![forbid(unsafe_code)]
#![deny(missing_docs)]

/// CRD type definitions.
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-k8s-operator/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
//!
//! See `docs/kubernetes.md` for end-user instructions.

#![forbid(unsafe_code)]
#![deny(missing_docs)]

use std::sync::Arc;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-middleware/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-middleware: CORS, HSTS, compression, callback, and header modifier middleware.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod callback;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-modules/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
//! The `Plugin` variant on each enum is the only case that falls back to
//! dynamic dispatch for third-party extensions.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod action;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-observe/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-observe: Observability - logging, metrics, and events.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod access_log;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-openapi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
//! `x-sbproxy-auth-type` extension and skip the `security` requirement so
//! the doc still validates.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

use sbproxy_config::{CompiledConfig, RawForwardRule};
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-platform/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! sbproxy-platform: Storage, messenger, circuit breaker, DNS, health checks,
//! and network protocol utilities.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod adaptive_breaker;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-plugin/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
//! - [`identity`] - Identity, classification, and anomaly hook surface.
//! - [`audit`] - Admin-action audit emitter trait surface.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod audit;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-security/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! sbproxy-security: Cryptography, IP utilities, host filtering, PII masking, and SSRF protection.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

#[cfg(feature = "agent-class")]
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-tls/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//! TLS, ACME auto-cert, and HTTP/3 support for sbproxy.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod acme;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy-transport/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
//! rate limiting, self-tuning connection pools, and request deduplication
//! for the proxy transport layer.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

pub mod auto_pool;
Expand Down
2 changes: 2 additions & 0 deletions crates/sbproxy-vault/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
//! sbproxy-vault: Secret management and secure variable interpolation.

#![allow(unsafe_code)]
// Volatile zeroization uses narrowly-scoped unsafe writes so secrets are not optimized away.
#![warn(missing_docs)]

pub mod convergent;
Expand Down
1 change: 1 addition & 0 deletions crates/sbproxy/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
//! mimalloc allocator, parses CLI args, and hands the config path to
//! [`sbproxy_core::run`]. All real work happens in the workspace crates.

#![forbid(unsafe_code)]
#![warn(missing_docs)]

use std::env;
Expand Down
Loading