Interface Origin

All Superinterfaces:
AbsoluteUri, AbsoluteUrl, BaseUrl, Normalisable<AbsoluteUri>, org.wiremock.stringparser.ParsedString, ServersideAbsoluteUrl, Uri, Url, UrlWithAuthority

public interface Origin extends BaseUrl
Represents a web origin as defined in HTML Living Standard.

An origin consists of a scheme, host, and port. It represents the security context of a web resource and is used for same-origin policy enforcement. Origins have no path, query, or fragment components.

The component parts of an origin (scheme, host and port) are always normalised. The origin itself is not the normal form of the URL it represents, since it has an empty path rather than an absolute root path. Origin.parse("https://example.org").normalise().toString() will return https://example.org/ .

Implementations must be immutable and thread-safe.

See Also: