Class Oauth2ProxyUpstream
Oauth2Proxy header model.
Namespace: Neon.Kube.Oauth2Proxy
Assembly: Neon.Kube.dll
Syntax
public class Oauth2ProxyUpstream
Constructors
Oauth2ProxyUpstream()
Constructor.
Declaration
public Oauth2ProxyUpstream()
Properties
FlushInterval
The period between flushing the response buffer when streaming response from the upstream.
Declaration
[JsonProperty(PropertyName = "FlushInterval", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "flushInterval", ApplyNamingConventions = false)]
public string FlushInterval { get; set; }
Property Value
Type | Description |
---|---|
string |
Id
Should be a unique identifier for the upstream.
Declaration
[JsonProperty(PropertyName = "Id", Required = Required.Always)]
[YamlMember(Alias = "id", ApplyNamingConventions = false)]
public string Id { get; set; }
Property Value
Type | Description |
---|---|
string |
InsecureSkipTlsVerify
Will skip TLS verification of upstream HTTPS hosts. This option is insecure and will allow potential Man-In-The-Middle attacks betweem OAuth2 Proxy and the usptream server.
Declaration
[JsonProperty(PropertyName = "InsecureSkipTlsVerify", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "insecureSkipTLSVerify", ApplyNamingConventions = false)]
public bool InsecureSkipTlsVerify { get; set; }
Property Value
Type | Description |
---|---|
bool |
PassHostHeader
Determines whether the request host header should be proxied to the upstream server.
Declaration
[JsonProperty(PropertyName = "PassHostHeader", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "passHostHeader", ApplyNamingConventions = false, DefaultValuesHandling = DefaultValuesHandling.OmitNull)]
public bool? PassHostHeader { get; set; }
Property Value
Type | Description |
---|---|
bool? |
Path
Used to map requests to the upstream server.
The closest match will take precedence and all Paths must be unique. Path can also take a pattern when used with RewriteTarget. Path segments can be captured and matched using regular experessions.
Eg:
- ^/foo$: Match only the explicit path /foo
- ^/bar/$: Match any path prefixed with /bar/
- ^/baz/(.*)$: Match any path prefixed with /baz and capture the remaining path for use with RewriteTarget
Declaration
[JsonProperty(PropertyName = "Path", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "path", ApplyNamingConventions = false)]
public string Path { get; set; }
Property Value
Type | Description |
---|---|
string |
ProxyWebSockets
Enables proxying of websockets to upstream servers.
Declaration
[JsonProperty(PropertyName = "ProxyWebSockets", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "proxyWebSockets", ApplyNamingConventions = false, DefaultValuesHandling = DefaultValuesHandling.OmitNull)]
public bool? ProxyWebSockets { get; set; }
Property Value
Type | Description |
---|---|
bool? |
RewriteTarget
Allows users to rewrite the request path before it is sent to the upstream server. Use the Path to capture segments for reuse within the rewrite target. Eg: With a Path of ^/baz/(.*), a RewriteTarget of /foo/$1 would rewrite the request /baz/abc/123 to /foo/abc/123 before proxying to the upstream server.
Declaration
[JsonProperty(PropertyName = "RewriteTarget", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "rewriteTarget", ApplyNamingConventions = false)]
public string RewriteTarget { get; set; }
Property Value
Type | Description |
---|---|
string |
Static
Will make all requests to this upstream have a static response. The response will have a body of "Authenticated" and a response code matching StaticCode. If StaticCode is not set, the response will return a 200 response.
Declaration
[JsonProperty(PropertyName = "Static", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "static", ApplyNamingConventions = false)]
public bool Static { get; set; }
Property Value
Type | Description |
---|---|
bool |
StaticCode
Determines the response code for the Static response. This option can only be used with Static enabled.
Declaration
[JsonProperty(PropertyName = "StaticCode", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "staticCode", ApplyNamingConventions = false)]
public int? StaticCode { get; set; }
Property Value
Type | Description |
---|---|
int? |
Timeout
The maximum duration the server will wait for a response from the upstream server.
Declaration
[JsonProperty(PropertyName = "Timeout", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "timeout", ApplyNamingConventions = false)]
public string Timeout { get; set; }
Property Value
Type | Description |
---|---|
string |
Uri
The URI of the upstream server. This may be an HTTP(S) server of a File based URL.It may include a path, in which case all requests will be served under that path. Eg:
- http://localhost:8080
- https://service.localhost
- https://service.localhost/path
- file://host/path If the URI's path is "/base" and the incoming request was for "/dir", the upstream request will be for "/base/dir".
Declaration
[JsonProperty(PropertyName = "Uri", Required = Required.Default, DefaultValueHandling = DefaultValueHandling.Ignore)]
[YamlMember(Alias = "uri", ApplyNamingConventions = false)]
public string Uri { get; set; }
Property Value
Type | Description |
---|---|
string |