XSRF Check Failed on Jira Server, Error 403
10-12-2022
09:12 AM
2,414 Views

NXP Employee
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am trying to call a POST (also tried a DELETE) method of a Jira Server rest api from an angular application.
Unfortunately, I am getting 403 error and it's saying XSRF check failed.
I tried adding X-Atlassian-Token: no-check but it does not do the trick for me.
Also I tried replacing the header's value of 'User-agent' with a dummy one but I am getting
The header is as follows
let headers = new HttpHeaders().set('content-type', 'application/json')
.set('X-Atlassian-Token','no-check')
.set('User-Agent','XX')
.append('Authorization', 'Basic ' + btoa(this.loginModel.username + ":" + this.loginModel.password));
I am getting completely frustrated because of this. Can anyone help me in this regard?
0 Replies
