dmesg is not restricted in linux-raspi kernel

Bug #1902934 reported by Dave Jones
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux-raspi (Ubuntu)
Fix Released
Undecided
Unassigned
Groovy
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

The CONFIG_SECURITY_DMESG_RESTRICT option is not set on the Ubuntu Pi kernels, resulting in dmesg being accessible to ordinary users.

This is in contrast to PC installs, where dmesg is now restricted to the "root" user in 20.10 onwards. The following messages from the ubuntu-devel list cover the original proposal (which proposed limiting dmesg to root:adm), and earlier discussion from 2011 (which proposed limiting dmesg to root alone, which is what was implemented in groovy):

https://lists.ubuntu.com/archives/ubuntu-devel/2020-June/041063.html

https://lists.ubuntu.com/archives/ubuntu-devel/2011-May/033240.html

[Test Case]

$ dmesg > /dev/null
$ echo $?
0

Should be:
$ dmesg
dmesg: read kernel buffer failed: Operation not permitted

[Regression Potential]

Ordinary users might still be able to execute dmesg and read the kernel logs.

CVE References

Juerg Haefliger (juergh)
Changed in linux-raspi (Ubuntu Groovy):
status: New → Triaged
Changed in linux-raspi (Ubuntu Hirsute):
status: New → Triaged
Juerg Haefliger (juergh)
description: updated
Juerg Haefliger (juergh)
Changed in linux-raspi (Ubuntu Groovy):
status: Triaged → Fix Committed
no longer affects: linux-raspi (Ubuntu Hirsute)
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (7.0 KiB)

This bug was fixed in the package linux-raspi - 5.8.0-1011.14

---------------
linux-raspi (5.8.0-1011.14) groovy; urgency=medium

  * groovy/linux-raspi: 5.8.0-1011.14 -proposed tracker (LP: #1907562)

  * dmesg is not restricted in linux-raspi kernel (LP: #1902934)
    - [Config] raspi: SECURITY_DMESG_RESTRICT=y

  [ Ubuntu: 5.8.0-34.37 ]

  * groovy/linux: 5.8.0-34.37 -proposed tracker (LP: #1907576)
  * Packaging resync (LP: #1786013)
    - update dkms package versions
  * [Ubuntu 21.04 FEAT] mpt3sas: Request to include the patch set which supports
    topology where zoning is enabled in expander (LP: #1899802)
    - scsi: mpt3sas: Define hba_port structure
    - scsi: mpt3sas: Allocate memory for hba_port objects
    - scsi: mpt3sas: Rearrange _scsih_mark_responding_sas_device()
    - scsi: mpt3sas: Update hba_port's sas_address & phy_mask
    - scsi: mpt3sas: Get device objects using sas_address & portID
    - scsi: mpt3sas: Rename transport_del_phy_from_an_existing_port()
    - scsi: mpt3sas: Get sas_device objects using device's rphy
    - scsi: mpt3sas: Update hba_port objects after host reset
    - scsi: mpt3sas: Set valid PhysicalPort in SMPPassThrough
    - scsi: mpt3sas: Handling HBA vSES device
    - scsi: mpt3sas: Add bypass_dirty_port_flag parameter
    - scsi: mpt3sas: Handle vSES vphy object during HBA reset
    - scsi: mpt3sas: Add module parameter multipath_on_hba
    - scsi: mpt3sas: Bump driver version to 35.101.00.00
  * CVE-2020-12912
    - hwmon: (amd_energy) modify the visibility of the counters
  * Intel Tiger Lake IDs supplement (LP: #1904521)
    - mtd: spi-nor: intel-spi: Add support for Intel Tiger Lake-H SPI serial flash
    - pinctrl: tigerlake: Add support for Tiger Lake-H
  * [i915] Noise-like lines of graphics corruption when moving windows in Xorg
    sessions (LP: #1896091)
    - Revert "UBUNTU: SAUCE: drm/i915: Synchronize active and retire callbacks"
  * Fix no headset sound after S3 on Intel HDA (LP: #1904595)
    - ALSA: hda: Refactor codec PM to use direct-complete optimization
    - ALSA: hda: Separate runtime and system suspend
    - ALSA: hda: Reinstate runtime_allow() for all hda controllers
  * Ask 8821C Bluetooth controller to drop old firmware (LP: #1904221)
    - Bluetooth: btrtl: Ask 8821C to drop old firmware
    - Bluetooth: btrtl: fix incorrect skb allocation failure check
  * Use ACPI S5 for reboot (LP: #1904225)
    - PM: ACPI: reboot: Use S5 for reboot
  * Groovy update: v5.8.18 upstream stable release (LP: #1904941)
    - netfilter: nftables_offload: KASAN slab-out-of-bounds Read in
      nft_flow_rule_create
    - io_uring: don't run task work on an exiting task
    - io_uring: allow timeout/poll/files killing to take task into account
    - io_uring: move dropping of files into separate helper
    - io_uring: stash ctx task reference for SQPOLL
    - io_uring: unconditionally grab req->task
    - io_uring: return cancelation status from poll/timeout/files handlers
    - io_uring: enable task/files specific overflow flushing
    - io_uring: don't rely on weak ->files references
    - io_uring: reference ->nsproxy for file table commands
    - io_wq: Make io_wqe::lock a raw_spinlock_t...

Read more...

Changed in linux-raspi (Ubuntu Groovy):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (15.6 KiB)

This bug was fixed in the package linux-raspi - 5.8.0-1011.14+21.04.1

---------------
linux-raspi (5.8.0-1011.14+21.04.1) hirsute; urgency=medium

  * hirsute/linux-raspi: 5.8.0-1011.14+21.04.1 -proposed tracker (LP: #1907561)

  [ Ubuntu: 5.8.0-1011.14 ]

  * groovy/linux-raspi: 5.8.0-1011.14 -proposed tracker (LP: #1907562)
  * dmesg is not restricted in linux-raspi kernel (LP: #1902934)
    - [Config] raspi: SECURITY_DMESG_RESTRICT=y
  * groovy/linux: 5.8.0-34.37 -proposed tracker (LP: #1907576)
  * Packaging resync (LP: #1786013)
    - update dkms package versions
  * [Ubuntu 21.04 FEAT] mpt3sas: Request to include the patch set which supports
    topology where zoning is enabled in expander (LP: #1899802)
    - scsi: mpt3sas: Define hba_port structure
    - scsi: mpt3sas: Allocate memory for hba_port objects
    - scsi: mpt3sas: Rearrange _scsih_mark_responding_sas_device()
    - scsi: mpt3sas: Update hba_port's sas_address & phy_mask
    - scsi: mpt3sas: Get device objects using sas_address & portID
    - scsi: mpt3sas: Rename transport_del_phy_from_an_existing_port()
    - scsi: mpt3sas: Get sas_device objects using device's rphy
    - scsi: mpt3sas: Update hba_port objects after host reset
    - scsi: mpt3sas: Set valid PhysicalPort in SMPPassThrough
    - scsi: mpt3sas: Handling HBA vSES device
    - scsi: mpt3sas: Add bypass_dirty_port_flag parameter
    - scsi: mpt3sas: Handle vSES vphy object during HBA reset
    - scsi: mpt3sas: Add module parameter multipath_on_hba
    - scsi: mpt3sas: Bump driver version to 35.101.00.00
  * CVE-2020-12912
    - hwmon: (amd_energy) modify the visibility of the counters
  * Intel Tiger Lake IDs supplement (LP: #1904521)
    - mtd: spi-nor: intel-spi: Add support for Intel Tiger Lake-H SPI serial flash
    - pinctrl: tigerlake: Add support for Tiger Lake-H
  * [i915] Noise-like lines of graphics corruption when moving windows in Xorg
    sessions (LP: #1896091)
    - Revert "UBUNTU: SAUCE: drm/i915: Synchronize active and retire callbacks"
  * Fix no headset sound after S3 on Intel HDA (LP: #1904595)
    - ALSA: hda: Refactor codec PM to use direct-complete optimization
    - ALSA: hda: Separate runtime and system suspend
    - ALSA: hda: Reinstate runtime_allow() for all hda controllers
  * Ask 8821C Bluetooth controller to drop old firmware (LP: #1904221)
    - Bluetooth: btrtl: Ask 8821C to drop old firmware
    - Bluetooth: btrtl: fix incorrect skb allocation failure check
  * Use ACPI S5 for reboot (LP: #1904225)
    - PM: ACPI: reboot: Use S5 for reboot
  * Groovy update: v5.8.18 upstream stable release (LP: #1904941)
    - netfilter: nftables_offload: KASAN slab-out-of-bounds Read in
      nft_flow_rule_create
    - io_uring: don't run task work on an exiting task
    - io_uring: allow timeout/poll/files killing to take task into account
    - io_uring: move dropping of files into separate helper
    - io_uring: stash ctx task reference for SQPOLL
    - io_uring: unconditionally grab req->task
    - io_uring: return cancelation status from poll/timeout/files handlers
    - io_uring: enable task/files specific overflow flushing
    - io_uring: don't rely on weak ->files references
    - io_...

Changed in linux-raspi (Ubuntu):
status: Triaged → Fix Released
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.