ForwardedTransformExtensions.WithTransformXForwarded Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Clones the route and adds the transform which will add X-Forwarded-* headers.
public static Yarp.ReverseProxy.Configuration.RouteConfig WithTransformXForwarded (this Yarp.ReverseProxy.Configuration.RouteConfig route, string headerPrefix = "X-Forwarded-", Yarp.ReverseProxy.Transforms.ForwardedTransformActions xDefault = Yarp.ReverseProxy.Transforms.ForwardedTransformActions.Set, Yarp.ReverseProxy.Transforms.ForwardedTransformActions? xFor = default, Yarp.ReverseProxy.Transforms.ForwardedTransformActions? xHost = default, Yarp.ReverseProxy.Transforms.ForwardedTransformActions? xProto = default, Yarp.ReverseProxy.Transforms.ForwardedTransformActions? xPrefix = default);
static member WithTransformXForwarded : Yarp.ReverseProxy.Configuration.RouteConfig * string * Yarp.ReverseProxy.Transforms.ForwardedTransformActions * Nullable<Yarp.ReverseProxy.Transforms.ForwardedTransformActions> * Nullable<Yarp.ReverseProxy.Transforms.ForwardedTransformActions> * Nullable<Yarp.ReverseProxy.Transforms.ForwardedTransformActions> * Nullable<Yarp.ReverseProxy.Transforms.ForwardedTransformActions> -> Yarp.ReverseProxy.Configuration.RouteConfig
<Extension()>
Public Function WithTransformXForwarded (route As RouteConfig, Optional headerPrefix As String = "X-Forwarded-", Optional xDefault As ForwardedTransformActions = Yarp.ReverseProxy.Transforms.ForwardedTransformActions.Set, Optional xFor As Nullable(Of ForwardedTransformActions) = Nothing, Optional xHost As Nullable(Of ForwardedTransformActions) = Nothing, Optional xProto As Nullable(Of ForwardedTransformActions) = Nothing, Optional xPrefix As Nullable(Of ForwardedTransformActions) = Nothing) As RouteConfig
Parameters
- route
- RouteConfig
- headerPrefix
- String
- xDefault
- ForwardedTransformActions
- xProto
- Nullable<ForwardedTransformActions>
- xPrefix
- Nullable<ForwardedTransformActions>