Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8131477
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T09:06:02+00:00 2026-06-06T09:06:02+00:00

Hi, For a view that will be submited I have two actions with the

  • 0

Hi,

For a view that will be submited I have two actions with the same name but one of them have this attribute :

[AcceptVerbs(HttpVerbs.Post)]

In the nonPost action I usually makes some validations where the User will be redirect to another action if its not correct, for example validating that the current object in edit is able to be changed.

Is it true that I need to make the exact same validations in the post Action to be sure that tha page is not hacked with some sort of custom post?

If so, how du u usually handle this? I do know about AuthorizeAttribute but the validations I need to do is specific for this action.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T09:06:05+00:00Added an answer on June 6, 2026 at 9:06 am

    Is it true that I need to make the exact same validations in the post
    Action to be sure that tha page is not hacked with some sort of custom
    post?

    Every controller action that modifies some state on the server and which requires authorization must perform this authorization.

    I do know about AuthorizeAttribute but the validations I need to do is
    specific for this action.

    Then write a specific Authorize attribute for those 2 actions (as apparently you have the same authorization logic for the 2 actions).

    But there’s something weird about your description. You said that if authorization fails in the GET action you redirect. But when you redirect you obviously cannot invoke the POST action because redirect means GET.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a view that has two buttons(First and Second) and one hidden field.
I have a view that will be displaying downloaded images and text. I'd like
We have a view that, without constraints, will return 90 million rows and a
I have a silverlight application (MVVM) with a view that will be used by
I'm trying to create a CGRect inside of a custom view (rectView) that will
I'm trying to set up a messages view with asp.net mvc that will display
I need to setup an ASP.Net MVC view with a Date Picker that will
We host online reports that a client will log into and view. The reports
I have an index view that I want to update automatically as the user
We currently have a View that queries active directory info. I was wondering if

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.