TrustedProxyResolver class

A resolver that determines the client IP address, considering trusted proxies and headers. This is useful for applications deployed behind reverse proxies.

Constructors

TrustedProxyResolver({required bool enabled, required bool forwardClientIp, required List<String> proxies, required List<String> headers, String? trustedPlatform})
Creates a TrustedProxyResolver.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolve(HttpRequest request) String
Resolves the client IP address from the HttpRequest.
toString() String
A string representation of this object.
inherited
update({bool? enabled, bool? forwardClientIp, String? trustedPlatform, List<String>? proxies, List<String>? headers}) → void
Updates the resolver's configuration.

Operators

operator ==(Object other) bool
The equality operator.
inherited