Bug 1954693 - rlwrap compiled as debug, causing /tmp/rlwrap.debug to be written
Summary: rlwrap compiled as debug, causing /tmp/rlwrap.debug to be written
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: rlwrap
Version: epel8
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Michel Lind
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-04-28 15:34 UTC by Christian Wissel
Modified: 2022-02-11 01:21 UTC (History)
4 users (show)

Fixed In Version: rlwrap-0.45.2-1.el9 rlwrap-0.45.2-1.el8 rlwrap-0.45.2-1.fc34 rlwrap-0.45.2-1.fc35 rlwrap-0.45.2-1.el7
Clone Of:
Environment:
Last Closed: 2022-02-11 00:26:27 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Christian Wissel 2021-04-28 15:34:08 UTC
Description of problem:
rlwrap has a built-in debug log, IF compiled with debug enabled, as describe here https://github.com/hanslub42/rlwrap/blob/master/BUGS
This causes rlwrap to write a debug log in /tmp/rlwrap.debug on invocation.

This log is not deleted on exit and can't be written to by other users who might be running rlwrap, due to default umask of 0022 creating the file with 0644 permissions.

Version-Release number of selected component (if applicable):
rlwrap-0.44-1.el8.x86_64

How reproducible:
Always

Steps to Reproduce:
1. invoke rlwrap as user 1
2. invoke rlwrap as user 2

Actual results:
rlwrap: error: Cannot open  debug log /tmp/rlwrap.debug for appending: Permission denied


Expected results:
no error

Additional info:
Possible workarounds:
- Change umask to 0002, if users are in a common group
- Leave the debug log in place and change its permissions to 0664 or 0666.

Comment 1 Jan "Yenya" Kasprzak 2021-11-23 12:04:36 UTC
Hello,

this is a large security hole. Can this be fixed soon? I'd like to use rlwrap on multiuser RHEL and CentOS hosts, but I cannot because of this. It was reported half a year ago, and it is still unfixed. Thanks!

Comment 2 Adrien Mahieux 2021-11-24 09:33:47 UTC
Hello,

We hit this bug too.

The bug is fixed upstream in (partially in v0.45.1, fully in v0.45.2), released 5 months ago.
Can you just trigger a rebuild?

Another possible workaround in the meantime:  "ln -s /dev/null /tmp/rlwrap.debug"


Thanks.

Comment 3 Michel Lind 2022-02-02 16:41:33 UTC
Sorry for the delay! 0.45.2 coming soon. The release monitoring was broken as a git commit that looks newer than all the releases was not filtered out, but that's also fixed.

Comment 4 Fedora Update System 2022-02-02 20:04:13 UTC
FEDORA-2022-8761120127 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2022-8761120127

Comment 5 Fedora Update System 2022-02-02 20:04:15 UTC
FEDORA-2022-15decf791f has been submitted as an update to Fedora 35. https://bodhi.fedoraproject.org/updates/FEDORA-2022-15decf791f

Comment 6 Fedora Update System 2022-02-02 20:04:16 UTC
FEDORA-EPEL-2022-ff9adfa937 has been submitted as an update to Fedora EPEL 8. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-ff9adfa937

Comment 7 Fedora Update System 2022-02-02 20:04:16 UTC
FEDORA-EPEL-2022-c6e9e4be6b has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-c6e9e4be6b

Comment 8 Fedora Update System 2022-02-02 20:04:17 UTC
FEDORA-EPEL-2022-765a9edc57 has been submitted as an update to Fedora EPEL 9. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-765a9edc57

Comment 9 Fedora Update System 2022-02-03 00:20:47 UTC
FEDORA-EPEL-2022-c6e9e4be6b has been pushed to the Fedora EPEL 7 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-c6e9e4be6b

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2022-02-03 00:21:25 UTC
FEDORA-EPEL-2022-ff9adfa937 has been pushed to the Fedora EPEL 8 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-ff9adfa937

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 11 Fedora Update System 2022-02-03 01:20:08 UTC
FEDORA-2022-8761120127 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2022-8761120127`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-8761120127

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 12 Fedora Update System 2022-02-03 01:28:02 UTC
FEDORA-EPEL-2022-765a9edc57 has been pushed to the Fedora EPEL 9 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2022-765a9edc57

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 13 Fedora Update System 2022-02-03 01:35:50 UTC
FEDORA-2022-15decf791f has been pushed to the Fedora 35 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2022-15decf791f`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-15decf791f

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 14 Fedora Update System 2022-02-11 00:26:27 UTC
FEDORA-EPEL-2022-765a9edc57 has been pushed to the Fedora EPEL 9 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 15 Fedora Update System 2022-02-11 00:47:56 UTC
FEDORA-EPEL-2022-ff9adfa937 has been pushed to the Fedora EPEL 8 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 16 Fedora Update System 2022-02-11 01:10:19 UTC
FEDORA-2022-8761120127 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 17 Fedora Update System 2022-02-11 01:21:10 UTC
FEDORA-2022-15decf791f has been pushed to the Fedora 35 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 18 Fedora Update System 2022-02-11 01:21:28 UTC
FEDORA-EPEL-2022-c6e9e4be6b has been pushed to the Fedora EPEL 7 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.