New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Owncloud 6 RC2 & RC1] WebDAV presumably broken and deactivated in OC6 RC2 & RC1 due to invalid XML #6119
Comments
Can you please try with disabled safe_mode and disabled open_basedir ? |
Can't reproduce here by the way. |
safe_mode is off :( |
I can confirm it with stable6, webDAV fails with the error log as report. |
@icewind1991 What do you think? |
WebDAV access works for me on openSUSE 13.1 and OC 6 RC 2. |
I see this behaviour in a plain stock OC 6 RC 2 without modifications to .htaccess. |
@blizzz which PHP versions ? I have this: Hmm 😦 What distro do you guys have the server on ? |
For me the problem unfortunately persists in RC2. P.S.: |
@PVince81 you need to provide the Apache PHP version, not the CLI one. Here it's on my dev machine, which runs Kubuntu 13.10. None of the mentioned XML libs is installed. Do we have new dependencies? |
P.S.: according to PHP Info xml, xmlreader, xmlwriter, libxml and SimpleXML are present and active/enabled. xmlrpc is also mentioned, but only in the authors action. No seperate packages however. |
PHP Apache version is the same as CLI for me: 5.3.17. |
libxml version is 2.7.6 |
libxml2 Version 2.9.1 (it's written in both ways, libxml and libxml2) |
Hmm, the parse error could also mean that a HTML error page came back instead of a XML content. |
Are you able to open the index.php by adding it into the URL directly ? |
Please also try to open this URL directly in the browser: http://yourhost/owncloud/remote.php/webdav |
which URL exactly? |
ah, you were faster |
@blizzz the first time I meant the index URL: http://yourhost/owncloud/index.php |
Erm, this will give me plain, old ownCloud… |
http://yourhost/owncloud/index.php: http://yourhost/owncloud/remote.php/webdav |
When I try to connect with cadaver it fails:
works with stable5 however. |
What do you guys mean with "plain old ownCloud" ? Does it mean ownCloud works or is it badly styled ? If what you meant is that it works correctly with index.php, then there might be a problem with the isWebDAVWorking() function in lib/private/util.php. Maybe it isn't requesting the correct URL ? Are you able to debug this @blizzz ? |
We mean that the URL is working just the way it would work without the added index.php |
I can't debug (unless you tell me how) - however - since I have a working OC6 Beta2 on the same webspace - I could copy the code of lib/private/util.php that was altered between OC6 Beta2 and OC6 RC2 and paste it in the form of code boxes - is that beneficial? |
Not sure what you mean. |
Yeah that is exactly what I meant - here you go!
|
FYI: |
There doesn't seem to be any changes related to isWebDAVWorking. It must be something else. i had a look again at your error log, and that message "CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set ". If I understand well, it means that the CURL call won't follow redirects. It seems that in some cases, if the "redirect" header is ignored, there will still be a HTML page with the message "moved permanently", which could explain the XML parse errors. Now what I don't understand is why there is a redirect in the first place. I tried the following URL, and there isn't any redirect on my side:
or
If you try this, you can see how it a redirect page looks like:
Unless the test code is using a different URL... Can you try these commands @blizzz @Niederfuchs ? |
If I am not mistaken you want me to run those commands from the console, right? Unfortunately I have no console - due to the fact that it is a simple webspace. If I got you all wrong however - I would need some help on where to run those commands. Or do you want me to exchange the URL within a certain file? P.S.: I am no programmer - I am sry - yet eager to help. P.P.S.: |
Yes, from the console. Sorry, might be harder in Windows. If that URL is accessible from the Internet you could send me the link and I can try on my side. |
Okay - I think you are on to something! |
So I am a noob but I ran your command followed by a (read that somewhere)
so it became
The result was the following file:
|
Nice! It says the magic quotes need to be disabled. Can you double check your .htaccess ? |
(I have no idea what magic quotes are 😬) |
Yeah!
I reentered them and now the WEBDAV message is gone. I will let you know as soon as I am sure that WEBDAV truly IS working ! |
I wonder why the error message didn't appear when accessing the index.php page where it would have been readable... |
Beats me. Maybe that's something you can forward to the right people. I for my part am happy that it is not a showstopper bug but one that is easily solved. Thanks again ! |
I'll try and see whether I can prevent remote.php to return HTML pages as errorrs... |
@blizzz can you confirm that you were having the magic quotes issues as well? |
Even when I try enabling magic quotes in .htaccess (putting those lines at the end of the file, with "On"), I still can't reproduce the issue 😦 |
According to get_magic_quotes_gpc() magic quotes are disabled. php-fpm (fastcgi) does not accept neither php_flag nor php_value, ends in a 500 when I put append them into the .htaccess |
@blizzz so if I understand well you probably have yet another issue ? Can you try the curl commands above to find out what the error page says ? |
just
but I hope this is not the reason for broken webdav :) |
@blizzz go on, check the permissions 😉 We definitely need a good way to reroute those message errors... |
No the permissions, are fine. But the config.php. If you set it up like this:
You cannot use webdav. If you set the original apps directory (exactly this) as writable => true, then webdav will work. That's stupid. I have similar setup in stable5 without problems. |
So the problem is indeed that the error message from WebDAV isn't correctly shown to the user ? |
@PVince81 the problem is that there is not problem with webdav in fact. but owncloud behves like this. |
Found a way to brutally reproduce this issue: remove the permissions of the "data" dir.
Instead of getting a SabreXML response you get an HTML page. That's a good base to work on a proper solution. |
@DeepDiver1975 the trouble with this is that in So far the only quick/hacky way I see is to hard code the detection of "remote.php/webdav" in the exception handler and output a preformatted exception XML. |
Closing in favor of #11834 |
Expected behaviour & Steps to reproduce
Expected: Working Owncloud instance with working Sabre-Webdav.
Actual behaviour
After installing the Owncloud 6 RC1 the WebDAV is reported to be presumably broken.
Error in owncloud log (from RC1):
Server configuration:
Operating system: Linux dd1320 2.6.32-53-server #115-Ubuntu SMP Wed Oct 23 07:54:54 UTC 2013 x86_64
Web server: Apache2
Database: MySQL v.5.1.70
PHP version: Version 5.3.18
ownCloud version: ownCloud 6.0 RC1 (testing)
Client configuration
Browser: Firefox 25.0.1
Operating system: Windows 8.1 Professional
Further Logs
ownCloud log from RC1 (data/owncloud.log):
The text was updated successfully, but these errors were encountered: