Bug 155312 - Save document fails with Libreoffice 7.5 and Webdav behind HAProxy
Summary: Save document fails with Libreoffice 7.5 and Webdav behind HAProxy
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: filters and storage (show other bugs)
Version:
(earliest affected)
7.5.2.2 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL: https://lists.apache.org/thread/sd8v2...
Whiteboard:
Keywords:
Depends on:
Blocks: Network
  Show dependency treegraph
 
Reported: 2023-05-15 08:39 UTC by jmreymond
Modified: 2023-11-30 16:04 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description jmreymond 2023-05-15 08:39:13 UTC
I have a tomcat server under Ubuntu 22.04 that presents documents with the Webdav protocol.

If my tomcat server is behind apache2, I can open and save a document with LibreOffice on Ubuntu 22.04 and MS Office on Mac.

If my tomcat server is behind HAProxy, I can open a document with LibreOffice under Ubuntu 22.04 and MS Office on Mac but I can't save it with Ubuntu 22.04 while it's OK with MS Office on Mac

The message is "Error while saving the template-CRA2 document: impossible to create the object in the directory https://cloud.exemple.com/WebDav/NESTOR/jmax"; translated from french" "Erreur lors de l'enregistrement du document template-CRA2: impossible de créer l'objet dans le répertoire https://cloud.exemple.com/WebDav/NESTOR/jmax";

I have traces in the tomcat servlet but I didn't notice an error code, all PROPFIND return 20x.

I have checked that all Webdav directories on the server have write permissions.

I can reproduce with

sudo mount -t davfs https://cloud1.exemple.com/WebDav/NESTOR/GERARD /mnt/webdav

and open a document with libreoffice in /mnt/webdav.
Open the document is OK but save failed with this message

Error while saving document template-CRA2
The object is not accessible
Impossible to access the object
because the user rights are insufficient.

It is ok with gedit, the text editor of my Ubuntu distribution.
Comment 1 jmreymond 2023-05-15 09:27:17 UTC
idem with
Version: 7.5.3.2 (X86_64) / LibreOffice Community
Build ID: 50(Build:2)
CPU threads: 8; OS: Linux 5.19; UI render: default; VCL: gtk3
Locale: fr-FR (fr_FR.UTF-8); UI: fr-FR
Ubuntu package version: 4:7.5.3~rc2-0ubuntu0.22.04.1~lo1
Calc: threaded
Comment 2 Stéphane Guillou (stragu) 2023-05-30 14:49:30 UTC
JM: does the same configuration work in a previous version, like LO 7.4?

László: any idea what the issue might be here? Looks like Curl 8 didn't help.
Comment 3 László Németh 2023-05-30 16:03:13 UTC
I suggest to check it with a daily build, or at latest with version 7.5.3.2 or 7.4.7.2, because the last fix in the area was Bug 155004.
Comment 4 Stéphane Guillou (stragu) 2023-05-30 17:10:31 UTC
(In reply to László Németh from comment #3)
> I suggest to check it with a daily build, or at latest with version 7.5.3.2
> or 7.4.7.2, because the last fix in the area was Bug 155004.

JM has the same issue in 7.5.3.2 in comment 1
Comment 5 jmreymond 2023-05-31 12:42:07 UTC
I can test with another version of LO, a suggestion ?
is there a tool to trace the dialogue between the webdav server and LO ?
Comment 6 jmreymond 2023-10-29 10:55:30 UTC
cannot reproduce with a dedicated server and apache2/webdav
Comment 7 jmreymond 2023-10-29 10:56:31 UTC Comment hidden (obsolete)
Comment 8 Stéphane Guillou (stragu) 2023-10-29 12:48:01 UTC
Thank you for re-testing and reporting back!
Marking as "works for me" as we're not sure what solved it.
Which version do you use now?
Comment 9 jmreymond 2023-11-29 10:21:01 UTC
haproxy is not involved.
tomcat9 is serving webdav requests.

running centos9 and ubuntu, cheking differents tomcat

9.0.31 OK
9.0.36 KO
9.0.58 KO
9.0.69 KO

I don't know if it's libreoffice that's no good on the webdav exchange or a bug introduced in tomcat9.
changelog of tomcat9:
https://tomcat.apache.org/tomcat-9.0-doc/changelog.html
9.0.35 Add: 64386: WebdavServlet does not send "getlastmodified" property for resource collections. (michaelo)
Comment 10 jmreymond 2023-11-29 10:25:55 UTC
with tomcat9 9.0.31, it works with
Libreoffice 7.6.3.2 and LibreOffice 7.3.7.2

with tomcat9 9.0.35, it DOES NOT work with
Libreoffice 7.6.3.2 and LibreOffice 7.3.7.2
Comment 11 jmreymond 2023-11-29 19:23:23 UTC
tomcat developer write in thread 
https://lists.apache.org/thread/sd8v2fg1n86pbw83mys7qwt2z41yffo1

Reason phrase is an optional element of the HTTP response. This looks 
like a bug in whichever WebDAV client library is being used by LibreOffice.
Comment 12 jmreymond 2023-11-30 05:57:18 UTC
as suggested by the thread https://lists.apache.org/thread/sd8v2fg1n86pbw83mys7qwt2z41yffo1, it's a libreoffice bug that needs to be fixed
Comment 13 Stéphane Guillou (stragu) 2023-11-30 07:55:22 UTC
Let's set back to "unconfirmed" then. ("Reopened" is for when there was an attempt to fix it.)

Relevant tomcat commit: https://github.com/apache/tomcat/commit/147fee447e27ec14e3001d9c727db1dcd4cb930c