Skip to main content

dahua_camera_http/
lib.rs

1//! Digest-authenticating HTTP client for a camera's own CGI interface.
2//!
3//! Every management protocol in this workspace — CGI control, the Dahua event
4//! attach stream, ONVIF SOAP, snapshots, storage queries — reaches the camera
5//! through [`CameraHttpClient`]. It exists as its own crate so that
6//! `dahua-camera-events`, `-control`, `-onvif`, `-record` and `-discovery` can
7//! share one connection pool and one Digest implementation without depending
8//! on each other.
9//!
10//! # Credentials
11//!
12//! [`CameraHttpClient`] holds a password, so it implements [`std::fmt::Debug`]
13//! by hand and prints the password as `<redacted>`. URLs are stripped of any
14//! embedded userinfo before they reach a log line or an error message.
15//!
16//! # Features
17//!
18//! - `tls` — allow `https://` management URLs. Off by default.
19
20#![warn(missing_docs)]
21#![forbid(unsafe_code)]
22
23pub mod client;
24
25pub use client::CameraHttpClient;