This site is the archived OWASP Foundation Wiki and is no longer accepting Account Requests.
To view the new OWASP Foundation website, please visit https://owasp.org
Difference between revisions of "OWASP Secure Application Design Project"
From OWASP
Ashish Rao (talk | contribs) (→Model Object Binding Technique) |
Ashish Rao (talk | contribs) (→Placement of Security Controls) |
||
Line 253: | Line 253: | ||
It thus seems logical that if you restrict the users at the page/view level they won’t be able to perform any operation in the application. But what if instead of requesting for a page/view an unauthorized user tries to request for an internal action like to action to add/modify any data in the application? It will get processed but the resultant view will be denied to the user; because the flaw lies in just having a view based access control in the applications. I am sure you will agree that a lot of processing for a request is done before the “view” comes into picture in any design. So the request to process any action will get processed successfully without authorization. | It thus seems logical that if you restrict the users at the page/view level they won’t be able to perform any operation in the application. But what if instead of requesting for a page/view an unauthorized user tries to request for an internal action like to action to add/modify any data in the application? It will get processed but the resultant view will be denied to the user; because the flaw lies in just having a view based access control in the applications. I am sure you will agree that a lot of processing for a request is done before the “view” comes into picture in any design. So the request to process any action will get processed successfully without authorization. | ||
− | Consider a MVC based given in the figure below. Observe in the figure that the authentication check is present only in the view pages. | + | Consider a MVC based given in the figure below. |
+ | [[File:Design7.png]] | ||
+ | |||
+ | Observe in the figure that the authentication check is present only in the view pages. | ||
Observe that neither the controller servlet (central processing entity) nor the action classes have any access control checks. So here, if the user requests for an internal action like add user details, etc. without authentication it will get processed, but the only difference is that the user will be shown an error page as resultant view will be disallowed to the user. | Observe that neither the controller servlet (central processing entity) nor the action classes have any access control checks. So here, if the user requests for an internal action like add user details, etc. without authentication it will get processed, but the only difference is that the user will be shown an error page as resultant view will be disallowed to the user. | ||
+ | |||
+ | [[File:Design8.png]] | ||
'''Insecure POST-BACK’s in ASP.NET''' | '''Insecure POST-BACK’s in ASP.NET''' | ||
A similar flaw is predominantly observed in ASP.NET applications where the developers tend to mix the code for handling POSTBACK’s and authentication checks. Usually it is observed that the authentication check in the ASP.NET pages are not applied for POSTBACKs, as indicated below. Here, if an attacker tries to access the page without authentication an error page will be rendered. Instead, if the attacker tries to send an internal POSTBACK request directly without authentication it would succeed. A detailed explanation is present here -[[http://artechtalks.blogspot.in/2013/02/insecure-postback-based-authentication.html]] | A similar flaw is predominantly observed in ASP.NET applications where the developers tend to mix the code for handling POSTBACK’s and authentication checks. Usually it is observed that the authentication check in the ASP.NET pages are not applied for POSTBACKs, as indicated below. Here, if an attacker tries to access the page without authentication an error page will be rendered. Instead, if the attacker tries to send an internal POSTBACK request directly without authentication it would succeed. A detailed explanation is present here -[[http://artechtalks.blogspot.in/2013/02/insecure-postback-based-authentication.html]] | ||
+ | |||
+ | [[File:Design9.png]] | ||
'''Secure Design Recommendation:''' | '''Secure Design Recommendation:''' |
Revision as of 18:34, 9 June 2015