Click here to Skip to main content
15,919,341 members
Please Sign up or sign in to vote.
1.92/5 (3 votes)
See more:
Hi everyone,

I am developing a web application using MVC 5 with C# .Net. Help me, how to secure this application?


I have implemented to MVC 5 filters security and role base authentication.

Please guide me what kind of security need to implements for the same app.

Waiting for your response. Thanks in advance!!!!



Thanks,
Anil Singh
Posted
Comments
Kunwar Saurabh 28-Jul-14 7:31am    
we are doing the same on MVC 4. How can we improvise security of the project?
anil.singh581 28-Jul-14 7:59am    
Dear, I am using filters security and role base ? It might help you!
http://www.code-sample.com/2014/07/mvc-5-redirect-from-globalasax-to.html
http://blogs.msdn.com/b/rickandy/archive/2011/05/02/securing-your-asp-net-mvc-3-application.aspx?Redirected=true

http://www.asp.net/web-api/overview/security/preventing-cross-site-request-forgery-%28csrf%29-attacks

Please look at below answers.



For security purpose you should to use following in your application

Authentication
Forms Authentication
Windows Authentication
Authorization
XSS
CSRF(Cross Site Request Forgery)

Please see following links that can we guide you for code and concept
and you can check new features of mvc 5

http://www.asp.net/mvc/mvc5[^]

Security In ASP.NET MVC[^]

http://blogs.msdn.com/b/rickandy/archive/2012/03/23/securing-your-asp-net-mvc-4-app-and-the-new-allowanonymous-attribute.aspx[^]
http://www.asp.net/mvc/mvc5

http://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-deploy-aspnet-mvc-app-membership-oauth-sql-database/[^]

Developing, Architecting and Testing Web Applications with MVC 5, Web API 2, KnockoutJS, Ninject and NUnit[^]


http://www.asp.net/mvc/tutorials/mvc-5/lifecycle-of-an-aspnet-mvc-5-application[^]
 
Share this answer
 
Please see the below link

- Preventing Cross-Site Request Forgery(CSRF) Attacks using MVC 5 Web API 2 Token Based Authentication

Secure MVC 5 C# .Net Application ?[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900