? ? Pending

User tests: Successful: Unsuccessful:

avatar PhilETaylor
PhilETaylor
25 Mar 2021

Joomla 4 version of #32866 for easy merging.

This also includes protection of the /api endpoint which is specific to Joomla 4

// @joomla/security @zero-24

avatar PhilETaylor PhilETaylor - open - 25 Mar 2021
avatar PhilETaylor PhilETaylor - change - 25 Mar 2021
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 25 Mar 2021
Category Administration com_config Language & Strings
avatar PhilETaylor PhilETaylor - change - 25 Mar 2021
Labels Added: ? ?
avatar PhilETaylor PhilETaylor - change - 25 Mar 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 25 Mar 2021
avatar zero-24
zero-24 - comment - 25 Mar 2021

I think that should be merged up once merged into 3.x but will let that up to @wilsonge and @rdeutz

avatar PhilETaylor
PhilETaylor - comment - 25 Mar 2021

This one is slightly different as it has the protection on the new /api endpoint as well.

Anything I can do to make it easier for @wilsonge to "merge up" I will do, easier for him just to hit a merge button :)

avatar PhilETaylor PhilETaylor - change - 25 Mar 2021
Title
[4] Correctly allow use of IP headers behind Load Balancers, and Not
[4][Security] Correctly allow use of IP headers behind Load Balancers, and Not
avatar PhilETaylor PhilETaylor - edited - 25 Mar 2021
43cdd2a 25 Mar 2021 avatar PhilETaylor tabs
d21a4d2 25 Mar 2021 avatar PhilETaylor Az
710fc76 26 Mar 2021 avatar PhilETaylor aA
avatar PhilETaylor
PhilETaylor - comment - 28 Mar 2021

Code blocks rearranged to satisfy comments on the Joomla 3 version of this PR.

avatar PhilETaylor PhilETaylor - change - 28 Mar 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 28 Mar 2021
avatar richard67 richard67 - test_item - 3 Apr 2021 - Tested successfully
avatar richard67
richard67 - comment - 3 Apr 2021

I have tested this item successfully on b5a00e5

The PR fixes the issue by not allowing IP override when the new option "Behind Load Balancer" is switched off (default).

When the option is switched on, IP override is still allowed (and has to be, otherwise the load balancer or similar would not work).

Tested with help of Firefox' developer tools.

I think we should use this PR as it is and consider to make enhancements like mentioned here #32866 (comment) with future PR's. For those I am open for "softening" the new feature policy and consider them for 4.0, as they can be considered to be security enhancements, as long as fully b/c. But that's just my personal opinion, I don't speak for anyone else.

Questions: Should there be a hint in release notes to switch the new option on with a clear description of when it has to be done and when not?


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

avatar richard67
richard67 - comment - 7 Apr 2021

A postinstall message about the new configuration option will be added by the J3 PR #32866 . This will be merged up into 3.10-dev, too, and so still will be there when people have updated their 3.10 to 4. So nothing more to do here, this PR is fine as it is, as far as I can see.

avatar anibalsanchez
anibalsanchez - comment - 23 Apr 2021

Hi,

The rest of the fields don't have a description.

Why this particular field need this description "If your site is behind a load balancer or reverse proxy (CloudFlare, Sucuri etc.) enable this setting so that IP addresses and other configurations within Joomla automatically take this into account."?

a. We have a description to all fields2
b. We don't have a description unless there is a very good reason. ("Behind Load Balancer" is a border case).


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

avatar PhilETaylor
PhilETaylor - comment - 23 Apr 2021

Because this is a complex new setting I guess we just need to expound it.

"CloudFlare, Sucuri " have been removed from the Joomla 3 version of this PR and probably will be from this one too

avatar anibalsanchez
anibalsanchez - comment - 23 Apr 2021

It is weird at the UX level to have a single field for a border case with a detailed description (even if it a cool description ;-) ).

I mean we could easily argue that most of the fields in the Global Configuration require knowledge about what you are doing.

avatar richard67
richard67 - comment - 23 Apr 2021

I feel somehow like sitting in the middle of you now, listening you, and thinking you are both right somehow.

Yes, it's not consistent to have descriptions there.

But yes, I think this setting is one of those where I personally need a description.

avatar PhilETaylor
PhilETaylor - comment - 23 Apr 2021

Fact is that maintainers were happy with it having a description for merging into Joomla 3....

... but then one would hope this is not so "new a feature" in Joomla 4 that people would not need it spelling out to them?

avatar richard67
richard67 - comment - 23 Apr 2021

... but then one would hope this is not so "new a feature" in Joomla 4 that people would not need it spelling out to them?

That could be right, too. I'm ok with both, with or without description in J4.

avatar PhilETaylor
PhilETaylor - comment - 27 Apr 2021

Closing this as its already been merged into Joomla 3, and so will "eventually" make its way into Joomla 4

At that time (depending on my mood) I will revisit the /api endpoint. The rest is already in Joomla 3.

avatar PhilETaylor PhilETaylor - change - 27 Apr 2021
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2021-04-27 16:38:15
Closed_By PhilETaylor
avatar PhilETaylor PhilETaylor - close - 27 Apr 2021
avatar wilsonge
wilsonge - comment - 3 May 2021

This has now made it's way into J4. I believe I have also sorted the api endpoint whilst i was doing the conflicts

avatar PhilETaylor
PhilETaylor - comment - 3 May 2021

Thanks - looks to be there correctly and I have tested it and it works as expected both behind a proxy and without a proxy.

Add a Comment

Login with GitHub to post a comment