diff --git a/src/Microsoft.AspNetCore.Http.Features/IHttpRequestFeature.cs b/src/Microsoft.AspNetCore.Http.Features/IHttpRequestFeature.cs
index 16511caa..5a84221b 100644
--- a/src/Microsoft.AspNetCore.Http.Features/IHttpRequestFeature.cs
+++ b/src/Microsoft.AspNetCore.Http.Features/IHttpRequestFeature.cs
@@ -48,6 +48,17 @@ public interface IHttpRequestFeature
///
string QueryString { get; set; }
+ ///
+ /// The request target as it was sent in the HTTP request. This property contains the
+ /// raw path and full query, as well as other request targets such as * for OPTIONS
+ /// requests (https://tools.ietf.org/html/rfc7230#section-5.3).
+ ///
+ ///
+ /// This property is not used internally for routing or authorization decisions. It has not
+ /// been UrlDecoded and care should be taken in its use.
+ ///
+ string RawTarget { get; set; }
+
///
/// Headers included in the request, aggregated by header name. The values are not split
/// or merged across header lines. E.g. The following headers:
diff --git a/src/Microsoft.AspNetCore.Http/Features/HttpRequestFeature.cs b/src/Microsoft.AspNetCore.Http/Features/HttpRequestFeature.cs
index c23051f6..b8b667bf 100644
--- a/src/Microsoft.AspNetCore.Http/Features/HttpRequestFeature.cs
+++ b/src/Microsoft.AspNetCore.Http/Features/HttpRequestFeature.cs
@@ -17,6 +17,7 @@ public HttpRequestFeature()
PathBase = string.Empty;
Path = string.Empty;
QueryString = string.Empty;
+ RawTarget = string.Empty;
}
public string Protocol { get; set; }
@@ -25,6 +26,7 @@ public HttpRequestFeature()
public string PathBase { get; set; }
public string Path { get; set; }
public string QueryString { get; set; }
+ public string RawTarget { get; set; }
public IHeaderDictionary Headers { get; set; }
public Stream Body { get; set; }
}
diff --git a/src/Microsoft.AspNetCore.Owin/OwinFeatureCollection.cs b/src/Microsoft.AspNetCore.Owin/OwinFeatureCollection.cs
index 6809d5c4..4838b99f 100644
--- a/src/Microsoft.AspNetCore.Owin/OwinFeatureCollection.cs
+++ b/src/Microsoft.AspNetCore.Owin/OwinFeatureCollection.cs
@@ -102,6 +102,12 @@ string IHttpRequestFeature.QueryString
set { Prop(OwinConstants.RequestQueryString, Utilities.RemoveQuestionMark(value)); }
}
+ string IHttpRequestFeature.RawTarget
+ {
+ get { return string.Empty; }
+ set { throw new NotSupportedException(); }
+ }
+
IHeaderDictionary IHttpRequestFeature.Headers
{
get { return Utilities.MakeHeaderDictionary(Prop>(OwinConstants.RequestHeaders)); }