HttpBaseProtocolFilter.AllowAutoRedirect Property
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.
Get or set a value that indicates whether the HttpBaseProtocolFilter should follow redirection responses.
public:
property bool AllowAutoRedirect { bool get(); void set(bool value); };
bool AllowAutoRedirect();
void AllowAutoRedirect(bool value);
public bool AllowAutoRedirect { get; set; }
var boolean = httpBaseProtocolFilter.allowAutoRedirect;
httpBaseProtocolFilter.allowAutoRedirect = boolean;
Public Property AllowAutoRedirect As Boolean
Property Value
bool
A value that indicates whether the HttpBaseProtocolFilter should follow redirection responses.
This value is true if the if HttpBaseProtocolFilter should follow redirection responses; otherwise false. The default value is true.
Remarks
Set AllowAutoRedirect to true if you want the HttpBaseProtocolFilter to automatically follow HTTP redirection headers to the new location of the resource. The maximum number of redirections to follow is set internally by the system.
If AllowAutoRedirect is set to false, all HTTP responses with an HTTP status code from 300 to 399 are returned to whatever called the HttpBaseProtocolFilter, which might another filter that might then return them to the app.
The Authorization header is cleared on auto-redirects and the HttpBaseProtocolFilter automatically tries to re-authenticate to the redirected location. In practice, this means that an app can't put custom authentication information into the Authorization header if it is possible to encounter redirection. Instead, the app must implement a custom authentication module using a filter.
Applies to
Feedback
Submit and view feedback for