hyperlane-plugin-rewrite 22.14.0

A high-performance HTTP URL rewrite and redirect plugin for the Hyperlane framework featuring canonical host/HTTPS enforcement (X-Forwarded-Proto aware), trailing-slash and duplicate-slash normalization, O(1) XxHash3_64 static tables, segment-bounded prefix rules, and compiled regex rules.
Documentation
/// Context attribute key preserving the pre-rewrite request path after an internal rewrite.
pub const ATTR_ORIGINAL_PATH: &str = "hyperlane_plugin_rewrite_original_path";

/// Scheme string denoting HTTPS traffic.
pub(crate) const SCHEME_HTTPS: &str = "https";

/// Scheme string denoting plaintext HTTP traffic.
pub(crate) const SCHEME_HTTP: &str = "http";

/// Scheme-authority separator used when assembling absolute redirect URLs.
pub(crate) const SCHEME_SEPARATOR: &str = "://";

/// RFC 7239 `Forwarded` directive prefix selecting the incoming protocol scheme.
pub(crate) const FORWARDED_PROTO_PREFIX: &str = "proto=";

/// Default HTTP port stripped during canonical host comparison.
pub(crate) const DEFAULT_HTTP_PORT: &str = ":80";

/// Default HTTPS port stripped during canonical host comparison.
pub(crate) const DEFAULT_HTTPS_PORT: &str = ":443";

/// Error message prefix when compiling an invalid regex rewrite pattern.
pub(crate) const ERR_INVALID_REGEX: &str = "invalid rewrite regex pattern";

/// Error message when a rewrite target or host contains forbidden CR/LF characters.
pub(crate) const ERR_UNSAFE_LOCATION: &str = "unsafe CR/LF character in rewrite target";