Issue 128413 - .desktop files installed by .deb archive in /opt/openoffice4/share/xdg are not executable
Summary: .desktop files installed by .deb archive in /opt/openoffice4/share/xdg are no...
Status: RESOLVED FIXED
Alias: None
Product: Installation
Classification: Application
Component: ui (show other issues)
Version: 4.1.8
Hardware: PC Linux 64-bit
: P5 (lowest) Normal (vote)
Target Milestone: 4.1.9
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-12 08:46 UTC by Arrigo Marchiori
Modified: 2021-01-05 22:47 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---
mseidel: 4.1.9_release_blocker+


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Arrigo Marchiori 2020-11-12 08:46:37 UTC
This report is about version 4.1.8 but I could not select it.

Files installed by .deb archive for x86_64 architecture are not "executable" by KDE because:
 1- they are not owned by root (but rather UID 500 and GID 500),
 2- they do not have the executable bit set.

This is happening on Ubuntu 18.04.5 LTS x86_64.

When clicking on any of the OpenOffice entries in the Applications -> Office KDE menu, a warning appears: "This will start the program: openoffice4 %U. If you do not trust this program, click Cancel".

When confirming, another error message appears:
"Unable to make the service OpenOffice 4.1.8 executable, aborting execution"

Two quick fixes are possible:
 - make all .desktop files in /opt/openoffice4/share/xdg executable, or
 - make all .desltop files in /opt/openoffice4/share/xdg owned by root.
Comment 1 Peter 2020-11-12 11:46:39 UTC
I used following command with out the issue you did describe:
sudo apt install ./*.deb ./desktop-integration/*.deb

What command(s) did you use?
Comment 2 Arrigo Marchiori 2020-11-12 12:12:37 UTC
Hello Peter,

I used "dpkg -i" instead of "apt install". However I tried your exact command and I got the same problem.

All the files in /opt/openoffice4 seem to be owned by user 500, group 500. I wonder if this is intentional?
Comment 3 Arrigo Marchiori 2020-11-12 12:14:41 UTC
By the way, the DEB's for OpenOffice 4.1.7 installed all files as owned by root:root. And it worked perfectly.
Comment 4 Peter 2020-11-12 13:22:52 UTC
I checked a bit closer. And I can see with an ll :
~/Downloads/de/DEBS/temp/usr/bin$ ll /opt/openoffice4 
insgesamt 72
drwxr-xr-x  7  500  500  4096 Nov 11 23:12 ./
drwxr-xr-x 12 root root  4096 Nov 11 23:12 ../
drwxr-xr-x  3  500  500  4096 Nov 11 23:12 help/
drwxr-xr-x 16  500  500  4096 Nov 11 23:12 presets/
drwxr-xr-x  6  500  500 20480 Nov 11 23:12 program/
-r--r--r--  1  500  500 12075 Okt 29 18:30 README
-r--r--r--  1  500  500 12707 Okt 29 18:30 README.html
drwxr-xr-x  2  500  500  4096 Nov 11 23:12 readmes/
drwxr-xr-x 22  500  500  4096 Nov 11 23:12 share/

which is strange. However I have no usage issue.

workaround:
sudo chown -R root /opt/openoffice4
sudo chgrp -R root /opt/openoffice4

However setting this issue to confirmed.
Comment 5 Arrigo Marchiori 2020-11-12 14:33:31 UTC
The fact that installed files are not owned by root is IMHO a bug.

According to (quite old) customs, UID 500 may be the first non-root user:
https://serverfault.com/questions/362943/who-is-user-500
and this is a security issue because the program is installed at system level.
Comment 6 Arrigo Marchiori 2020-12-12 14:08:16 UTC
I tried a very simple test case with the epm program on my openSUSE system.
Not being Debian-based, I had to install by hand the dpkg program.

When I tried to make a deb package I was given the following warning:

epm: Warning - file permissions and ownership may not be correct
     in Debian packages unless you run EPM as root or the 'fakeroot'
     command is available!

The generated deb file contained in fact wrong permissions, same as the OpenOffice 4.1.8 release archives.

After installing the fakeroot package, the warning message disappeared and the generated deb file was good.

Is it possible, then, that the OpenOffice build system does not have the 'fakeroot' program installed?

Please note I have used epm 5.0.0 for the above test. I cannot find the link to download the previous version.
Comment 7 Jim Jagielski 2020-12-27 16:01:13 UTC
This will be resolved in AOO 4.1.9
Comment 8 Keith N. McKenna 2021-01-05 21:03:59 UTC
Resolved by commit 4975252caf49bc46c383c6cef330cb927a635806