linkCookieXSRFStrategy
npm Package | @angular/http |
---|---|
Module | import { CookieXSRFStrategy } from '@angular/http'; |
Source | http/src/backends/xhr_backend.ts |
linkDeprecation Notes
use @angular/common/http instead
linkOverview
class CookieXSRFStrategy implements XSRFStrategy {
constructor(_cookieName: string = 'XSRF-TOKEN', _headerName: string = 'X-XSRF-TOKEN')
configureRequest(req: Request): void
}
linkDescription
XSRFConfiguration
sets up Cross Site Request Forgery (XSRF) protection for the application
using a cookie. See https://www.owasp.org/index.php/Cross-SiteRequest_Forgery(CSRF)
for more information on XSRF.
Applications can configure custom cookie and header names by binding an instance of this class
with different cookieName
and headerName
values. See the main HTTP documentation for more
details.
linkConstructor
linkMembers
configureRequest(req: Request): void