OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

oslc-core message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Click jacking security issue text for spec

Here's some suggested non-normative text to address clickjacking in the spec or best practices. Please review both the clarity of the wording, and the feasibility of the suggested steps to protect against the attack:
Security issue: clickjacking (UI redress attack).
This vulnerability can occur when a malicious (or compromised) web application embeds an OSLC delegated dialog (or UI preview) in their own web page, obscures it from the user's view by covering it with other layers or components, then tricks the user into clicking on a button in the unseen iframe by encouraging them to click on components that they can see. The user is intending to click on the components that they can see, but the malicious web page is "hijacking" those clicks because they really activate components in the embedded iframe.
This vulnerability requires that the user loads a malicious webpage in their browser. This can happen in a number of ways, including:
There are always two pages involved in this attack; the "UI consumer" page (which has the iframe embedded within it), and the "UI provider" page (which gets loaded within the iframe). I'll call the UI provider's server the "server under attack".
To protect against this attack:
  1. When requesting the URL for the delegates dialog (from the ServiceProvider) or the UI preview (from the compact resource), the server under attack must require requests for these resources to be authenticated. This authentication must be for the end-user, not for the client app itself.
  2. When returning a URL for the dialog or preview, the server under attack must return a URL that is specific to the authenticated user, and that cannot be guessed by merely knowing the user's username or ID.
  3. When the server under attack receives a request for the dialog or preview URL itself (the request that is generated by the iframe to load the page to display within it), the server under attack must check that the URL that was requested is one that was generated for the same user that is requesting this page (i.e. the user that is identified by a session ID in the cookies sent with the request). This makes sure that the client can't get a URL for the dialog from one user that it is authenticated for, an use that to perform a clickjacking attack on another user that has not authorised that client.
  4. If the users (for the URL and the cookie) do not match, then the server can either return with an HTTP error, or include an X-Frame-Options header with value SAMEORIGIN or DENY.
  5. All pages that are not dialogs or previews - that is, all pages that are not intended to be embedded - should include an X-Frame-Options response header with value SAMEORIGIN or DENY, to prevent them from being used for clickjacking attacks.
This is only required on dialogs or previews that contain controls that can be invoked with one or more clicks, and where those controls have side effects on the server. That is, if there are no controls on a preview, then there is no target for the malicious page to tick the user to click on.
By following these steps the server under attack knows that only clients that are able to authenticate against the server (e.g. for OAuth authentication they must have a valid client ID and - if required by the interaction pattern they're using - they must know the client secret), and that have also been authorized by the user to whom the the dialog is displayed, can display that dialog.
There are still some potential attack vectors:
But the exposure has been reduced as the attack cannot occur simply by loading a malicious web page in the user's browser.
Martin Pain

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]