Germany/Projekte/Top 10-2013-A7-Fehlerhafte Autorisierung auf Anwendungsebene

From OWASP
Revision as of 17:29, 15 June 2013 by T.Gigler (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

BAUSTELLE! Hier entsteht das deutsche Wiki der OWASP Top 10-2013

← A6-Verlust der Vertraulichkeit sensibler Daten
2013 Inhaltsverzeichnis

2013 Die Top-10-Risiken

A8-Cross-Site Request Forgery (CSRF) →
Bedrohungsquelle
Angriffsvektor
Schwachstellen
Technische Auswirkung
Auswirkung auf das Unternehmen
Application Specific Ausnutzbarkeit
EINFACH
Verbreitung
HÄUFIG
Auffindbarkeit
DURCHSCHNITTLICH
Auswirkung
MITTEL
Application / Business Specific

Anyone with network access can send your application a request. Could anonymous users access private functionality or regular users a privileged function?

Attacker, who is an authorized system user, simply changes the URL or a parameter to a privileged function. Is access granted? Anonymous users could access private functions that aren’t protected.

Applications do not always protect application functions properly. Sometimes, function level protection is managed via configuration, and the system is misconfigured. Sometimes, developers must include the proper code checks, and they forget.

Detecting such flaws is easy. The hardest part is identifying which pages (URLs) or functions exist to attack.

Such flaws allow attackers to access unauthorized functionality. Administrative functions are key targets for this type of attack.

Cbusiness value of the exposed functions and the data they process.

Also consider the impact to your reputation if this vulnerability became onsider the public.

Bin ich durch 'Fehlerhafte Autorisierung auf Anwendungsebene' verwundbar?

The best way to find out if an application has failed to properly restrict function level access is to verify every application function:

  1. Does the UI show navigation to unauthorized functions?
  2. Are server side authentication or authorization checks missing?
  3. Are server side checks done that solely rely on information provided by the attacker?

Using a proxy, browse your application with a privileged role. Then revisit restricted pages using a less privileged role. If the server responses are alike, you're probably vulnerable. Some testing proxies directly support this type of analysis.

You can also check the access control implementation in the code. Try following a single privileged request through the code and verifying the authorization pattern. Then search the codebase to find where that pattern is not being followed.

Automated tools are unlikely to find these problems.

Wie kann ich 'Fehlerhafte Autorisierung auf Anwendungsebene' verhindern?

Your application should have a consistent and easy to analyze authorization module that is invoked from all of your business functions. Frequently, such protection is provided by one or more components external to the application code.

  1. Think about the process for managing entitlements and ensure you can update and audit easily. Don’t hard code.
  2. The enforcement mechanism(s) should deny all access by default, requiring explicit grants to specific roles for access to every function.
  3. If the function is involved in a workflow, check to make sure the conditions are in the proper state to allow access.

NOTE: Most web applications don’t display links and buttons to unauthorized functions, but this “presentation layer access control” doesn’t actually provide protection. You must also implement checks in the controller or business logic.


Mögliche Angriffsszenarien

Scenario #1: The attacker simply force browses to target URLs. The following URLs require authentication. Admin rights are also required for access to the admin_getappInfo page.

http://example.com/app/getappInfo http://example.com/app/admin_getappInfo

If an unauthenticated user can access either page, that’s a flaw. If an authenticated, non-admin, user is allowed to access the admin_getappInfo page, this is also a flaw, and may lead the attacker to more improperly protected admin pages.

Scenario #2: A page provides an 'action' parameter to specify the function being invoked, and different actions require different roles. If these roles aren’t enforced, that’s a flaw.

Referenzen

OWASP

For additional access control requirements, see the ASVS requirements area for Access Control (V4).

Andere

← A6-Verlust der Vertraulichkeit sensibler Daten
2013 Inhaltsverzeichnis

2013 Die Top-10-Risiken

A8-Cross-Site Request Forgery (CSRF) →

© 2002-2013 OWASP Foundation This document is licensed under the Creative Commons Attribution-ShareAlike 3.0 license. Some rights reserved. CC-by-sa-3 0-88x31.png