What is cross-site request forgery (csrf)? How is rails protected against it?



What is cross-site request forgery (csrf)? How is rails protected against it?..

Answer / Aakash Rastogi

Cross-Site Request Forgery (CSRF) is an exploit that tricks the victim into making unwanted requests to a web application. Rails provides protection against CSRF by automatically including a CSRF token in all POST requests and forms. This token is generated and verified on both client and server sides.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Ruby on Rails Interview Questions

Do you know what is “yield” in ruby on rails?

1 Answers  


What are rails validation used for?

1 Answers  


Can you list out what can rails migration do?

1 Answers  


What is the flash?

1 Answers  


Why RubyonRails?

8 Answers  


What is action cable?

1 Answers  


How are observers and callbacks different from each other?

1 Answers  


Do you know what is rake in rails?

1 Answers  


Mention the differences between the observers and callbacks in ruby on rails.

1 Answers  


What are the different types of association relationships that exist?

1 Answers  


Explain rails migration.

1 Answers  


how many types of callbacks available in ror?

1 Answers  


Categories