? Success

User tests: Successful: Unsuccessful:

avatar andrepereiradasilva
andrepereiradasilva
20 Aug 2016

Summary of Changes

Remove Legacy Browser (IE 7 and older) Frame Breaking Script.

Since Joomla 3.x only support IE8+ and modern browsers this code have no effect anymore because all this browsers support the X-Frame-Options header that already does this.

See https://www.owasp.org/index.php/Clickjacking_Defense_Cheat_Sheet

This code was only used in admin com_login page:

So this PR deprecates the behaviour.noframes and in replace adds and HTTP Header in com_login admin view html file.

Testing Instructions

  1. Apply patch
  2. Admin login in isis and hathor work without issues and have the X-Frame-Options HTTP header
  3. Code review

Documentation Changes Required

None.

avatar joomla-cms-bot joomla-cms-bot - change - 20 Aug 2016
Category Libraries
avatar andrepereiradasilva andrepereiradasilva - open - 20 Aug 2016
avatar andrepereiradasilva andrepereiradasilva - change - 20 Aug 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 20 Aug 2016
Labels Added: ?
avatar andrepereiradasilva
andrepereiradasilva - comment - 20 Aug 2016

need some help with the unit tests.
JHtmlBehaviorTest::testNoFrames is failing and don't really know how to rewrite it.

avatar mbabker
mbabker - comment - 20 Aug 2016

JHtmlBehaviorTest::testNoFrames is validating that JHtmlBehavior::core gets
called. You're removing the call to it so remove that from the array
that's being validated.

For the other failures, I'm leaning toward that being a result of the JHtml
tests affecting global state and a value not being reset correctly.

On Friday, August 19, 2016, andrepereiradasilva notifications@github.com
wrote:

need some help with the unit tests.
JHtmlBehaviorTest::testNoFrames is failing and don't really know how to
rewrite it.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#11679 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAWfobN_3pgi0skKvNghSpHltR1xYD3jks5qhlDngaJpZM4Jo9Ir
.

avatar dgt41
dgt41 - comment - 20 Aug 2016

@andrepereiradasilva B/C policy states that this can not be done in 3.x. What could be done is to remove the calls to this function and deprecate the function so it will be removed in j4

avatar andrepereiradasilva
andrepereiradasilva - comment - 20 Aug 2016

@dgt41

B/C policy states that this can not be done in 3.x.

Why do you think this is not B/C? I'm not removing the method (the setHeader is still there), just some obslete js code inside the method.

avatar dgt41
dgt41 - comment - 20 Aug 2016

Ah, ok didn't catch that, still I think deprecating this and adding

JFactory::getApplication()->setHeader('X-Frame-Options', 'SAMEORIGIN');

to the two views is safer, but I don't mind either way

avatar andrepereiradasilva
andrepereiradasilva - comment - 20 Aug 2016

ok have no issue with that and also think it's better.
will check.

avatar joomla-cms-bot joomla-cms-bot - change - 20 Aug 2016
Category Libraries Administration Components Libraries
avatar joomla-cms-bot joomla-cms-bot - change - 20 Aug 2016
Category Libraries Administration Components Administration Components Templates (admin) Libraries
avatar andrepereiradasilva
andrepereiradasilva - comment - 20 Aug 2016

ok @dgt41:

  • no change in method. just added deprected messages
  • remove method usage where it was used in the core
  • added the X-Frame-Options header to admin com_login view html file.

please test.

avatar andrepereiradasilva andrepereiradasilva - change - 20 Aug 2016
The description was changed
avatar andrepereiradasilva andrepereiradasilva - edited - 20 Aug 2016
avatar andrepereiradasilva andrepereiradasilva - change - 20 Aug 2016
The description was changed
avatar andrepereiradasilva andrepereiradasilva - edited - 20 Aug 2016
avatar andrepereiradasilva andrepereiradasilva - edited - 20 Aug 2016
avatar andrepereiradasilva andrepereiradasilva - change - 20 Aug 2016
Title
Remove legacy browsers Frame Breaking Script code
Remove legacy browsers Frame Breaking Script code usage and deprecate it
avatar andrepereiradasilva andrepereiradasilva - edited - 20 Aug 2016
avatar dgt41 dgt41 - test_item - 20 Aug 2016 - Tested successfully
avatar dgt41
dgt41 - comment - 20 Aug 2016

I have tested this item successfully on b417a54

Tested on OSX with: safari, chrome, ff, opera (latest, development, tech review)


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/11679.

avatar brianteeman brianteeman - test_item - 20 Aug 2016 - Tested successfully
avatar brianteeman
brianteeman - comment - 20 Aug 2016

I have tested this item successfully on b417a54

I didnt even know we had this protection - cool;)


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/11679.

avatar andrepereiradasilva andrepereiradasilva - edited - 20 Aug 2016
avatar dgt41 dgt41 - change - 20 Aug 2016
Status Pending Ready to Commit
avatar dgt41
dgt41 - comment - 20 Aug 2016

RTC

avatar joomla-cms-bot joomla-cms-bot - change - 20 Aug 2016
Labels Added: ?
avatar wilsonge
wilsonge - comment - 4 Sep 2016

Merged with 92c08ef

avatar wilsonge wilsonge - change - 4 Sep 2016
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2016-09-04 12:49:37
Closed_By wilsonge
avatar wilsonge wilsonge - close - 4 Sep 2016
avatar joomla-cms-bot joomla-cms-bot - close - 4 Sep 2016
avatar joomla-cms-bot joomla-cms-bot - change - 4 Sep 2016
Labels Removed: ?

Add a Comment

Login with GitHub to post a comment