TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Sri Ram
1.6k
173
99.7k
Custom Validation using Action Filter vs Authorize Filter
May 22 2020 11:28 PM
We have an ASP.NET Core 3 MVC app using cookie authentication. When the user logs into the app, a SessionId(created in sql db) is added to the claims collection.
For every action method execution, we want to verify this SessionId is valid string, belongs only to the logged-in user and has doesn't expired. This validation logic will be kept in the sql server side using a stored proc. If this validation results in failure, then user would have to redirected to a custom page(e.g. InvalidSession.cshtml)
For this implementing this validation, what would be the best approach in ASP.NET Core 3.0?
Can we use custom ActionFilters or AuthorizationFilters or is there any better way of handling this scenario?
Experts, please advice.
Reply
Answers (
1
)
how to pass from.serilize() and array value using ajax?
How to create crystal report in asp.net mvc using c#?