Barry wrote:
> On 7 Mar 2023, at 17:58, Patrick Dupre <pdupre(a)gmx.com>
wrote:
>
> I can run scilab as root user, but as a standard user, I get:
>
> /usr/bin/chcon: failed to change context of
'/usr/local/scilab/scilab-6.1.1/bin/scilab-bin' to
‘unconfined_u:object_r:execmem_exec_t:s0’: Operation not permitted
> Error: Cannot chcon 'scilab-bin'
>
> Can I fix this issue?
Are you running a setup/install script?
I would not expect chcon in an app start script.
And yet, the scilab command appears to do just that. :(
The code looks to come from here:
https://gitlab.com/search?search=chcon&nav_source=navbar&project_...
The chcon calls were added 11 years ago, in:
https://gitlab.com/scilab/scilab/-/commit/fde269e73db4705fb19804fdd23f318...
This added a function named `check_and_disable_selinux()`
with the comment "If enabled, disable se_linux."
That's just software which has not kept up with the times.
Is scilab from a Fedora RPM?
The /usr/local prefix makes that highly unlikely.
And `dnf provides /usr/local/scilab` doesn't return
anything.
I think this is an upstream issue and would be better asked
in their forums and/or bug tracker.
It shouldn't need to run chcon at all. If it must, it ought
to check that the file doesn't already have the desired
SELinux type, which would avoid the issue. Or you could
install it somewhere within your home directory instead of
in a root-owned location like /usr/local.
--
Todd