insecure W+X mapping

Bug #1905807 reported by Dimitri John Ledkov
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux-riscv (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

[ 19.051518] Freeing unused kernel memory: 308K
[ 19.062326] ------------[ cut here ]------------
[ 19.066219] riscv/mm: Found insecure W+X mapping at address (____ptrval____)/0xffffffdff8000000
[ 19.074930] WARNING: CPU: 0 PID: 1 at arch/riscv/mm/ptdump.c:200 note_page+0x24c/0x252
[ 19.082806] Modules linked in:
[ 19.085825] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.8.0-10-generic #12+21.04.1-Ubuntu
[ 19.094007] epc: ffffffe000208f18 ra : ffffffe000208f18 sp : ffffffe1f5b9fb30
[ 19.101104] gp : ffffffe001728ee0 tp : ffffffe1f5bedc00 t0 : ffffffe00173edf8
[ 19.108330] t1 : ffffffe00173ed90 t2 : 00000001feca5000 s0 : ffffffe1f5b9fb80
[ 19.115536] s1 : ffffffe1f5b9fe10 a0 : 0000000000000053 a1 : 0000000200000020
[ 19.122743] a2 : ffffffe1f5b9f870 a3 : 0000000000000000 a4 : ffffffe0016200f8
[ 19.129949] a5 : ffffffe0016200f8 a6 : 00000000000000c1 a7 : ffffffe0006f27fe
[ 19.137156] s2 : ffffffdff8001000 s3 : 0000000000000000 s4 : 0000000000000004
[ 19.144376] s5 : 0000000000000000 s6 : 0000000000000000 s7 : ffffffe1f5b9fd20
[ 19.151570] s8 : ffffffdff8001000 s9 : ffffffe00172a148 s10: ffffffdff8002000
[ 19.158775] s11: ffffffe000c16e20 t3 : 000000000003ce50 t4 : 000000000003ce50
[ 19.165980] t5 : 0000000000000000 t6 : ffffffe001739462
[ 19.171255] status: 0000000200000120 badaddr: 0000000000000000 cause: 0000000000000003
[ 19.179177] ---[ end trace 72fa85d58b123e2f ]---
[ 19.184544] Checked W+X mappings: failed, 513 W+X pages found
[ 19.189561] Run /init as init process

Not sure what that means. This is on
[ 0.000000] Linux version 5.8.0-10-generic (buildd@riscv64-qemu-lcy01-087) (gcc (Ubuntu 10.2.0-18ubuntu1) 10.2.0, GNU ld (GNU Binutils for Ubuntu) 2.35.1) #12+21.04.1-Ubuntu SMP Fri Nov 20 16:26:05 UTC 2020 (Ubuntu 5.8.0-10.12+21.04.1-generic 5.8.17)

will try to get full logs.

Revision history for this message
Paul Larson (pwlars) wrote :

I'm seeing something very similar to this with current focal images running on unmatched (5.8.0-29)
It looks like the image on july 24 worked, but ever since the july 25, 2021 image, it fails to boot
https://pastebin.canonical.com/p/c9czkm9x74/

Revision history for this message
Dimitri John Ledkov (xnox) wrote :

insecure W+X mapping is fixed in v5.13 series and in impish.
the changes to fix those will not be backported to hirsute, hence marking this bug as fix released.

The kernel panics that is shown in the pastebin is unrelated to the insecure W+X mapping.

Changed in linux-riscv (Ubuntu):
status: New → 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.