Skip to main content

extract_forwarded_ip

Function extract_forwarded_ip 

Source
pub fn extract_forwarded_ip(value: &str) -> Option<String>
Expand description

Returns the first forwarded client address when it is a valid IP literal.

§Parameters

§Returns

Returns Some when crate::http::extract_forwarded_ip can produce a value and None otherwise.

§Performance

Performance is proportional to the size of the supplied inputs and any parsed or loaded data consumed by crate::http::extract_forwarded_ip.

§Examples

ⓘ
let _result = pharos_runtime_core::http::extract_forwarded_ip("value");
  • crate::http for adjacent helpers that share the same runtime surface.