Function relay_filter::csp::matches_any_origin

source ยท
pub fn matches_any_origin(
    url: Option<&str>,
    origins: &[SchemeDomainPort],
) -> bool
Expand description

Checks if a url satisfies one of the specified origins.

An origin specification may be in any of the following formats:

  • http://domain.com[:port]
  • an exact match is required
  • *: anything goes
  • *.domain.com: matches domain.com and any subdomains
  • *:port: matches any hostname as long as the port matches