xrdp log created with wrong permissions

Bug #1937024 reported by Jose Mari

This bug report will be marked for expiration in 33 days if no further activity occurs. (find out why)

10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
xrdp (Ubuntu)
Incomplete
Undecided
Unassigned

Bug Description

When xrdp (and their dependencies) are installed and running, the log permissions are:

root@host01~# ls -l /var/log/xrdp*
-rw-r----- 1 xrdp adm 33138 jul 20 09:45 /var/log/xrdp.log
-rw-r----- 1 root adm 18608 jul 20 09:45 /var/log/xrdp-sesman.log

But if logs are removed (backup, logrotate, etc.), when restart, xrdp creates logs with wrong permissions:

root@host01~# ls -l /var/log/xrdp*
-rw------- 1 root root 587 jul 20 11:46 /var/log/xrdp-sesman.log

And xrdp-sesman crashes. When permissions are set, xrdp runs normally.

Steps to reproduce it:

* install: sudo apt install -y xrdp
* start: sudo systemctl start xrdp
* test ok: sudo xrdp localhost
* stop: sudo systemctl stop xrdp
* remove logs: sudo rm -f /var/log/xrdp*
* start: sudo systemctl start xrdp
* test fail: xrdp localhost

Logs attached.
tested wich package: xrdp/focal 0.9.12-1 amd64

Tags: xrdp
Revision history for this message
Jose Mari (fmor) wrote :
description: updated
description: updated
Revision history for this message
Chris Guiver (guiverc) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. Please execute the following command only once, as it will automatically gather debugging information, in a terminal:

apport-collect 1937024

When reporting bugs in the future please use apport by using 'ubuntu-bug' and the name of the package affected. You can learn more about this functionality at https://wiki.ubuntu.com/ReportingBugs.

Jose Mari (fmor)
description: updated
affects: xubuntu-meta (Ubuntu) → xrdp (Ubuntu)
Jose Mari (fmor)
description: updated
Jose Mari (fmor)
description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xrdp (Ubuntu):
status: New → Confirmed
Revision history for this message
Lenin (gagarin) wrote :

can you retest with 24.04?

Changed in xrdp (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Jose Mari (fmor) wrote :

Hi,

Please, mark it as solved.

I've tested in 24.04 (desktop) and has been corrected: xrdp does not start if log not correctly configured (permissions).

root@ubuntu:/var/log# ls -l xrdp*
-rw-r----- 1 root adm 2322 May 3 10:09 xrdp-sesman.log
-rw-r----- 1 xrdp adm 9139 May 3 10:08 xrdp.log

toot@ubuntu:/var/log# systemctl restart xrdp
Job for xrdp.service failed because the control process exited with error code.
See "systemctl status xrdp.service" and "journalctl -xeu xrdp.service" for details.

root@ubuntu:/var/log# journalctl -xeu xrdp.service
(...)
░░ The job identifier is 3708.
May 03 10:10:06 ubuntu xrdp[9049]: Could not start log
May 03 10:10:06 ubuntu xrdp[9049]: Could not start log
May 03 10:10:06 ubuntu xrdp[9049]: error opening log file [The log is not properly started]. quitting.
May 03 10:10:06 ubuntu systemd[1]: xrdp.service: Control process exited, code=exited, status=1/FAILURE
(...)

Thanks!!!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.