Want to know something about mlock or shmctl via SHMLOCK



Hi all:

If I mlock a chunk of memory in a user process and pass the address
of
that chunk of memory through ioctl to my kernel module. Then in my
kernel
module, can I just directly access that chunk of the memory from the
user
space address without using
copy_user_to/copy_user_from/get_user_pages/kmap/kmap_atomic?

Is that possible?

.



Relevant Pages

  • Re: [Vuln-Dev Challenge] - VulnDev1.c Summary
    ... meaning the chunk is allocated with mmap. ... turn calls munmap on an invalid memory address. ... > the Doug Lea algorithm as well has heap-based exploitation methods ... > the forward chunk, in our case buf2, is free. ...
    (Vuln-Dev)
  • The Malloc Maleficarum
    ... Glibc Malloc Exploitation Techniques ... the exploitation of overflowed dynamic memory chunks on Linux. ... I have the House of Prime. ... a malloc chunk. ...
    (Bugtraq)
  • [Full-disclosure] The Malloc Maleficarum
    ... Glibc Malloc Exploitation Techniques ... the exploitation of overflowed dynamic memory chunks on Linux. ... I have the House of Prime. ... a malloc chunk. ...
    (Full-Disclosure)
  • Re: [RFC v11][PATCH 05/13] Dump memory address space
    ... in one or more chunk: each chunk begins with a header that specifies ... should not change in the interim anyways, the locks protects us from, e.g. ... Even scanning over a large amount of memory, you aren't going to see a performance difference for accessing pgarr from an argument vs off of field in ctx which is going to be cache-hot. ... It is strictly necessary when it comes to handling shared memory. ...
    (Linux-Kernel)
  • Re: Communications kernel -> userland
    ... > form the kernel to the user process; ... > to the user process memory. ... > handle packets, perhaps ...
    (freebsd-hackers)