? Pending

User tests: Successful: Unsuccessful:

avatar Bakual
Bakual
22 Sep 2017

Pull Request for Issue #18024 .

Summary of Changes

  • Adding a new method stream_register to the Joomla\CMS\Utility\BufferStreamHandler class.
  • Changing FtpClient to explicitely register the wrapper using that method.

Testing Instructions

Use with any extension that uses the FtpClient class and is currently broken.

Expected result

Works

Actual result

White Screen of Death

Documentation Changes Required

The new API has to be document and once we remove the B/C workaround (in 4.0) this has to be documented as well

@mbabker @laoneo What do you think? Would that work?

avatar joomla-cms-bot joomla-cms-bot - change - 22 Sep 2017
Category Libraries
avatar Bakual Bakual - open - 22 Sep 2017
avatar Bakual Bakual - change - 22 Sep 2017
Status New Pending
avatar brianteeman brianteeman - change - 22 Sep 2017
Title
Add ne wmethod BufferStreamHandler::stream_register()
Add new method BufferStreamHandler::stream_register()
avatar brianteeman brianteeman - edited - 22 Sep 2017
avatar nealrduncan
nealrduncan - comment - 26 Sep 2017

The solution in #18075 worked for us, but we did have to make the tmp directory owned by the ftp user and the web server group.

avatar wojsmol
wojsmol - comment - 27 Sep 2017

@nealrduncan Please add WeServer to PHP Interface value in next comment.


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

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 27 Sep 2017

@Bakual does Comment of @nealrduncan mean its an successfully Test which i can alter?

avatar wojsmol
wojsmol - comment - 27 Sep 2017

@franz-wohlkoenig Yes but I wont value of setting I mentioned in #18075 (comment). Please keep eye on it.

avatar franz-wohlkoenig franz-wohlkoenig - alter_testresult - 27 Sep 2017 - nealrduncan: Tested successfully
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 27 Sep 2017

altered successfully Test of @nealrduncan

avatar ReLater
ReLater - comment - 27 Sep 2017

but we did have to make the tmp directory owned by the ftp user and the web server group.

I don't think that it's a successful test then! The PR should solve the problem without any additional chown and/or chmod.

avatar wojsmol
wojsmol - comment - 27 Sep 2017

@ReLater It depends on WeServer to PHP Interface value and this is reason for my request #18075 (comment)
@franz-wohlkoenig must have this valiue added in comment.
cc @Webdongle

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 27 Sep 2017

must have this valiue added in comment

@wojsmol didn't get what this means.

avatar ReLater
ReLater - comment - 27 Sep 2017

didn't get what this means.

The "WebServer to PHP Interface" information is missing that you find under menu System > System Information > Tabulator "System Information".

avatar wojsmol
wojsmol - comment - 27 Sep 2017
avatar franz-wohlkoenig franz-wohlkoenig - alter_testresult - 27 Sep 2017 - nealrduncan: Tested unsuccessfully
avatar franz-wohlkoenig franz-wohlkoenig - alter_testresult - 27 Sep 2017 - nealrduncan: Not tested
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 27 Sep 2017

set back Test by @nealrduncan to not tested.

avatar nealrduncan
nealrduncan - comment - 27 Sep 2017

@wojsmol apache2handler


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

avatar wojsmol
wojsmol - comment - 27 Sep 2017

@nealrduncan Then this

but we did have to make the tmp directory owned by the ftp user and the web server group.

is expected by me.

avatar Webdongle
Webdongle - comment - 30 Sep 2017

@Bakual @wojsmol
Given

but we did have to make the tmp directory owned by the ftp user and the web server group.

#18075 (comment)

Then
Something is seriously wrong

avatar Bakual
Bakual - comment - 30 Sep 2017

Maybe, but not related to this PR then.

avatar wojsmol
wojsmol - comment - 30 Sep 2017

@Webdongle @Bakual this is related to php-fpm setup mater of 1 line in config file..

avatar Webdongle
Webdongle - comment - 30 Sep 2017

@Bakual
Yes

we did have to make the tmp directory owned by the ftp user and the web server group.

#18075 (comment)
Is related to this patch. If Joomla previously worked on a server but after apply the path the Ownership (of a folder) had to be changed to include group ... then the change made by the patch is forcing the server admin to use looser security. Or are you suggesting that the server was set incorrectly in the first place and that the patch just high-lighted an error in the server configuration ?

avatar Bakual
Bakual - comment - 1 Oct 2017

All this PR does is reinstating the registering of the buffer so the FtpClient class works again as before. Nothing in the code itself changes, the behavior is exactly the same as before.
So if there is a permission issue, it is a separate issue.

avatar Webdongle
Webdongle - comment - 1 Oct 2017

@Bakual @franz-wohlkoenig

All this PR does is reinstating the registering of the buffer so the FtpClient class

Does it use the exact same code/syntax to do that or is there a difference ?

the behavior is exactly the same as before.
So if there is a permission issue, it is a separate issue.

If the behavoiur is the same then why did the Group Ownership need to be changed ?

So even though it worked for @nealrduncan before without /tmp being Owned by the Group ... he should have have had the Group as Owner anyway ? Or did the Ownership need to be changed because it was a patch and not part of the original install ?

avatar wojsmol
wojsmol - comment - 1 Oct 2017

@Webdongle As you know I have few yours of expiriens a let's name this sysadmin. The company I work for has several dedicated servers. If I see that files and folders do not have chown user:user and files are not writable with chmod 644 and folders at 755 then I treat this as a server configuration error.
@mbabker Please comment.

avatar laoneo
laoneo - comment - 1 Oct 2017

Not sure, but perhaps you can try #18060 if that has the same behavior as before. It should even have the same as this one.

avatar Bakual
Bakual - comment - 1 Oct 2017

Please open a new issue for the ownership issue. It certainly hasn't to do with this PR.

avatar Webdongle
Webdongle - comment - 1 Oct 2017

@Bakual
Thanks for confirming that @nealrduncan comment was a result of the server not the patch

avatar nealrduncan
nealrduncan - comment - 2 Oct 2017

We also had to chmod 774 tmp. I just realized that when I patch another site. So...
site owned by user using ftp
chown user.webserver tmp
chmod 774 tmp
Not ideal, but it works.

avatar Bakual Bakual - change - 14 Oct 2017
Labels Added: ?
avatar Bakual
Bakual - comment - 14 Oct 2017

Changed the method to a static function and adjusted the calls to fit.

avatar mbabker mbabker - change - 27 Oct 2017
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-10-27 13:29:33
Closed_By mbabker
avatar mbabker mbabker - close - 27 Oct 2017
avatar mbabker mbabker - merge - 27 Oct 2017

Add a Comment

Login with GitHub to post a comment