1193 Commits (main)
 

Author SHA1 Message Date
Tomi Leppänen 338e69d20f [mapplauncherd] Set CAP_SYS_PTRACE to allow reading /proc/pid/exe. Fixes JB#53620
All other boosters must be changed as well.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
4 years ago
Tomi Leppänen 3cb9c45c41 [launcherlib] Add checks for invoker. Fixes JB#52956
Check that caller is from the same namespace as the booster and the
calling binary is /usr/bin/invoker.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
4 years ago
Raine Makelainen 92d182de05 Merge branch 'jb53620' into 'master'
[launcherlib] Revert: Add checks for invoker. JB#53620

See merge request mer-core/mapplauncherd!29
4 years ago
Raine Makelainen 75c156112a [launcherlib] Revert: Add checks for invoker. JB#53620
This reverts commit 88bf4689e4.
4 years ago
Tomi Leppänen b7de66d551 Merge branch 'jb52956_plug_the_hole' into 'master'
[launcherlib] Add checks for invoker. Fixes JB#52956

See merge request mer-core/mapplauncherd!28
4 years ago
Tomi Leppänen 88bf4689e4 [launcherlib] Add checks for invoker. Fixes JB#52956
Check that caller is from the same namespace as the booster and the
calling binary is /usr/bin/invoker.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
4 years ago
Tomi Leppänen 3c56c25256 Merge branch 'jb53097_simple_fix' into 'master'
[launcherlib] Correct single instance code for QML apps. Contributes to JB#53159

See merge request mer-core/mapplauncherd!27
4 years ago
Tomi Leppänen d2ee6f8617 [launcherlib] Correct single instance code for QML apps. Contributes to JB#53097
This makes sure that we retain the behaviour we had before for
non-sandboxed apps. This is done to ensure that locking uses appName()
when using for example QML based applications.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
5 years ago
Tomi Leppänen 46a89c4705 Fix changelog date 5 years ago
pvuorela 4fd919ca0e Merge branch 'musl' into 'master'
Fix Musl incompabilities

See merge request mer-core/mapplauncherd!16
5 years ago
Bart Ribbers 6d31938929 Fix Musl incompabilities
Without including libgen.h, basename is not available on Musl.
sourceArgv[0] is a const char* which can not be converted to char*, so
cast it instead
RTLD_DEEPBIND is not available on Musl, only on glibc (since 2.3.4)
ARG_MAX is already defined so it has to be renamed
Even according to glibc itself, <bits/socket.h> should never be included
directly and <sys/socket.h> should, which is already done anyway
5 years ago
Tomi Leppänen c2324d1984 Merge branch 'jb52187_sandboxed_cgroups' into 'master'
[launcherlib] Set cgroups of sandboxed apps correctly. Fixes JB#52187

See merge request mer-core/mapplauncherd!25
5 years ago
Tomi Leppänen 26c5406e63 [launcherlib] Set cgroups of sandboxed apps correctly. Fixes JB#52187
Separate cgroups of sandboxed apps. Previously they were all put to the
same group with this change they are in separate groups.

Looking at invoker.c appName and fileName are the same and can be used
interchangeably.

Also change --desktop-file to have a bit more accurate description.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
5 years ago
Tomi Leppänen 7091378e7d Merge branch 'jb52491_fix' into 'master'
[launcherlib] Use actual application name for sailjail'd apps. Fixes JB#52491

See merge request mer-core/mapplauncherd!24
5 years ago
Tomi Leppänen 5ae55df59e [launcherlib] Use actual application name for sailjail'd apps. Fixes JB#52491
Applications launched via sailjail have their appName set to
/usr/bin/sailjail and that is used to set single instance lock. That
results in not being able to launch multiple different applications
simultaneously via mapplauncher. Mitigate this by using actual
application name for single instance lock.

This implements a very simple way of deducing the application binary
path from sailjail's arguments. It works for most cases and the
remaining cases can be worked around.

Signed-off-by: Tomi Leppänen <tomi.leppanen@jolla.com>
5 years ago
Niels Breet 1b1d2c3798 Merge branch 'jb49681' into 'master'
[aarch64] Use macros, not hardcoded paths. Contributes to JB#49681

See merge request mer-core/mapplauncherd!21
5 years ago
Niels Breet e4cc3b8f79 [aarch64] Use macros, not hardcoded paths. Contributes to JB#49681 5 years ago
pvuorela 72f487f73a Merge branch 'master' into 'master'
[Packaging] Remove python2 requires

See merge request mer-core/mapplauncherd!20
5 years ago
Chupligin Sergey ef26653ca6 [Packaging] Remove python2 requires 5 years ago
Andrew Branson 3c78ac5d94 Merge branch 'jb49488' into 'master'
[priv] isPrivileged should return true if the file is listed with no privileges. JB#49488

See merge request mer-core/mapplauncherd!19
5 years ago
Andrew Branson e907e276f2 [priv] isPrivileged should return true if the file is listed with no privileges. JB#49488
Also remove leftover m_privileges member from Booster.
5 years ago
Andrew Branson 02bba3a3c6 Merge branch 'jb49488' into 'master'
[booster] Expose privilege values for use. JB#49488

See merge request mer-core/mapplauncherd!18
5 years ago
Andrew Branson a8dea6a958 [booster] Expose privilege values for use. JB#49488 5 years ago
Raine Makelainen 7e93b143a1 Merge branch 'jb49088' into 'master'
[booster] Always drop extra groups for non-privileged apps. Fixes JB#49088

See merge request mer-core/mapplauncherd!14
5 years ago
Igor Zhbanov 294cd4d37c [booster] Always drop extra groups for non-privileged apps. Fixes JB#49088
Don't trust to UID/GID received from untrusted invoker request when deciding
whether to drop extra groups for non-privileged apps. The application's
rights should depend only on the stated application's privileges and not
on the caller's process rights.

Drop setuid() because the boosters are launched under "nemo" user ID in
user session.

Signed-off-by: Igor Zhbanov <i.zhbanov@omprussia.ru>
5 years ago
Raine Makelainen f84e8e15e0 Bump version to 4.1.31 6 years ago
Raine Makelainen 16c9749dd6 Merge branch 'jb48847' into 'master'
[booster] Drop privileged SGID for non-privileged apps. Fixes JB#48847

See merge request mer-core/mapplauncherd!13
6 years ago
Igor Zhbanov b62ef0d2d4 [booster] Drop privileged SGID for non-privileged apps. Fixes JB#48847
Under Linux, setgid() is implemented like the POSIX version with the
_POSIX_SAVED_IDS feature. That means that after "setgid(nemo)" SGID
will be set to "privileged" instead of "nemo". So using "setresuid()"
instead.

Signed-off-by: Igor Zhbanov <i.zhbanov@omprussia.ru>
6 years ago
Andrew den Exter 6912348d5a Merge branch 'jb44214' into 'master'
[booster] Check for execute permissions before invoking a process. Fixes JB#44214

See merge request mer-core/mapplauncherd!12
7 years ago
Andrew den Exter a841302207 [booster] Check for execute permissions before invoking a process. Fixes JB#44214 7 years ago
Raine Makelainen db11a3a532 Merge branch 'jb42038' into 'master'
[mapplauncherd] Add booster cgroup mount service. Fixes MER#1916

See merge request mer-core/mapplauncherd!9
7 years ago
Aleksey Mikhaylov 2442117654 [mapplauncherd] Fixes MER#1916
Signed-off-by: Aleksey Mikhaylov <a.mikhaylov@omprussia.ru>
7 years ago
Raine Makelainen 6e72366257 Merge branch 'master' into 'master'
[mapplauncherd] Create cgroup for each process if possible. Fixes MER#1896

See merge request mer-core/mapplauncherd!7
7 years ago
Andrew den Exter 41a44c5ab4 Merge branch 'jb41671' into 'master'
[mapplauncherd] Fix race when in writing the daemon PID file and exiting. Contributes to JB#41671

See merge request mer-core/mapplauncherd!8
7 years ago
Andrew den Exter d57148540f [mapplauncherd] Fix race when in writing the daemon PID file and exiting. Contributes to JB#41671
The process forks twice when daemonizing, we need to wait for
the first fork to exit after it has written the PID of the second
fork before exiting the original process otherwise systemd may
try and read the file before it exists.
7 years ago
Aleksey Mikhaylov a480e5fd36 [mapplauncherd] Create cgroup for each process if possible. Fixes MER#1896
Signed-off-by: Aleksey Mikhaylov <a.mikhaylov@omprussia.ru>
7 years ago
Andrew den Exter 78d0dc16f1 Merge branch 'jb40880' into 'master'
[mapplauncherd] Support running boosters as forking systemd services. Contributes to JB#40880

See merge request mer-core/mapplauncherd!6
7 years ago
Andrew den Exter 95f0d02446 [mapplauncherd] Support running boosters as forking systemd services. Contributes to JB#40880
This enables the case where the booster itself is launcher via an
invoker.
7 years ago
pvuorela 6439643867 Merge branch 'master' into 'master'
Fix build with new systemd

See merge request !3
8 years ago
Slava Monich f35103e569 Version 4.1.24 8 years ago
Slava Monich b8170de1d4 Merge branch 'dir' into 'master'
Own the config directories

See merge request !4
8 years ago
Slava Monich b9c591ab8e [mapplauncherd] Own the config directories. Contributes to JB#38236 8 years ago
Sergey Chupligin fcac0eb973 Fix build with new systemd 9 years ago
Chris Adams 406794ce0c [mapplauncherd] Bump version with fix for MER#1607 9 years ago
chriadam 84ba4c7960 Merge branch 'master' into 'master'
Add support for multiple privileges file

Fixes MER#1607

See merge request !2
9 years ago
Lucien XU 3f64a9869e Add support for multiple privileges file
Fixes MER#1607
9 years ago
martinjones df3254d72e Merge branch 'jb34267' into 'master'
[mapplauncherd] Allow a list of booster types to be provided. Contributes to JB#34267

Allows fallback boosters to be specified, e.g.

invoker -s --type=silica-media,silica-qt5 /usr/bin/jolla-camera

See merge request !1
9 years ago
Martin Jones 627bc74e65 [mapplauncherd] Allow a list of booster types to be provided. Contributes to JB#34267
Allows fallback boosters to be specified, e.g.

invoker -s --type=silica-media,silica-qt5 /usr/bin/jolla-camera
9 years ago
Robin Burchell 45ed31bffd Merge pull request #34 from rburchell/master
Clean up some remnants of the single-process-applauncherd model.
10 years ago
Robin Burchell 0ee65f7fa9 [README] Update to match reality a little closer. 10 years ago