Skip to main content

forwarded_for

Function forwarded_for 

Source
pub fn forwarded_for(headers: &HeaderMap) -> Option<String>
Expand description

Joins every X-Forwarded-For value on the request, in order.

A conforming proxy sends one comma-separated header, but nothing stops a client from sending its own and a proxy from appending a second line. Only the rightmost hop across all of them is evidence, so they must be read as one list.