Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
RequireHttpsAttribute Class
Collapse the table of content
Expand the table of content

RequireHttpsAttribute Class

 

Represents an attribute that forces an unsecured HTTP request to be re-sent over HTTPS.

Namespace:   System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

System.Object
  System.Attribute
    System.Web.Mvc.FilterAttribute
      System.Web.Mvc.RequireHttpsAttribute

[AttributeUsageAttribute(AttributeTargets.Class | AttributeTargets.Method, 
	Inherited = true, AllowMultiple = false)]
public class RequireHttpsAttribute : FilterAttribute, IAuthorizationFilter

NameDescription
System_CAPS_pubmethodRequireHttpsAttribute()

Initializes a new instance of the RequireHttpsAttribute class.

NameDescription
System_CAPS_pubpropertyAllowMultiple

Gets or sets a value that indicates whether more than one instance of the filter attribute can be specified.(Inherited from FilterAttribute.)

System_CAPS_pubpropertyOrder

Gets or sets the order in which the action filters are executed.(Inherited from FilterAttribute.)

System_CAPS_pubpropertyTypeId

(Inherited from Attribute.)

NameDescription
System_CAPS_pubmethodEquals(Object)

(Inherited from Attribute.)

System_CAPS_protmethodFinalize()

(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

(Inherited from Attribute.)

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_protmethodHandleNonHttpsRequest(AuthorizationContext)

Handles unsecured HTTP requests that are sent to the action method.

System_CAPS_pubmethodIsDefaultAttribute()

(Inherited from Attribute.)

System_CAPS_pubmethodMatch(Object)

(Inherited from Attribute.)

System_CAPS_protmethodMemberwiseClone()

(Inherited from Object.)

System_CAPS_pubmethodOnAuthorization(AuthorizationContext)

Determines whether a request is secured (HTTPS) and, if it is not, calls the HandleNonHttpsRequest method.

System_CAPS_pubmethodToString()

(Inherited from Object.)

For more information about the security implications of this attribute, see the entry "Security" in the MVC FAQ on Rick Anderson's blog. For more information about how to use attributes, see .

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show:
© 2015 Microsoft