filmov
tv
What is CORS In Spring boot | CORS Policy | CORS Interview Questions and Answer | Code Decode |
Показать описание
This video covers CORS policy And how to implement it in the spring Boot application. Why CORS is important And how it works is also explained here.
Udemy Course of Code Decode on Microservice k8s AWS CICD link:
Course Description Video :
What is CORS
CORS is Cross Origin Resource sharing.
Its a violation of Same origin policy
What is same-origin policy (SOP)
The same-origin policy (SOP) is a web security mechanism built into web browsers that influences how websites can access one another. The concept of same-origin policy was introduced by Netscape Navigator 2.02 in 1995,
Without SOP, a malicious website or web application could access another without restrictions. That would allow attackers to easily steal sensitive information from other websites or even perform actions on other sites without user consent.
SOP does not need to be turned on – it is automatically enabled in every browser that supports it.
The SOP mechanism was designed to protect against attacks such as cross-site request forgery (CSRF), which basically attempt to take advantage of vulnerabilities due to differing origins
What is Origin
Two URLs have the same origin if the protocol, port (if specified), and host are the same for both.
Why we Backend developers need CORS if its implemented at browser level?
Though we are just the backend developers working on backend application but we do have Front end application too .
Now Backend and Front end urls are usually
We can clearly see difference in origin. Hence when ever Front end tries to call ur rest APi, It fails due to SOP policy saying No “Access-Control-Allow-Origin” header is present on requested resource. Origin 4200 is not allowed access.
Solution is CORS.
Hibernate Interview Questions and Answers:
Spring Boot Interview Questions and Answers:
Subscriber and Follow Code Decode
#elasticsearch #interviewquestions #codedecode
Udemy Course of Code Decode on Microservice k8s AWS CICD link:
Course Description Video :
What is CORS
CORS is Cross Origin Resource sharing.
Its a violation of Same origin policy
What is same-origin policy (SOP)
The same-origin policy (SOP) is a web security mechanism built into web browsers that influences how websites can access one another. The concept of same-origin policy was introduced by Netscape Navigator 2.02 in 1995,
Without SOP, a malicious website or web application could access another without restrictions. That would allow attackers to easily steal sensitive information from other websites or even perform actions on other sites without user consent.
SOP does not need to be turned on – it is automatically enabled in every browser that supports it.
The SOP mechanism was designed to protect against attacks such as cross-site request forgery (CSRF), which basically attempt to take advantage of vulnerabilities due to differing origins
What is Origin
Two URLs have the same origin if the protocol, port (if specified), and host are the same for both.
Why we Backend developers need CORS if its implemented at browser level?
Though we are just the backend developers working on backend application but we do have Front end application too .
Now Backend and Front end urls are usually
We can clearly see difference in origin. Hence when ever Front end tries to call ur rest APi, It fails due to SOP policy saying No “Access-Control-Allow-Origin” header is present on requested resource. Origin 4200 is not allowed access.
Solution is CORS.
Hibernate Interview Questions and Answers:
Spring Boot Interview Questions and Answers:
Subscriber and Follow Code Decode
#elasticsearch #interviewquestions #codedecode
Комментарии