mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:17:35 +00:00
SymbolServer+bt: Symbolicate kernel addresses if /boot/Kernel available
The /boot directory is only accessible to root by default, but anyone wanting access to kernel symbols for development can get them by making /boot/Kernel accessible to the "symbol" user.
This commit is contained in:
parent
3ff7b0ebfe
commit
a5d89ca5df
2 changed files with 19 additions and 2 deletions
|
@ -49,6 +49,14 @@ int main(int, char**)
|
|||
return 1;
|
||||
}
|
||||
|
||||
// NOTE: Developers can opt into kernel symbolication by making /boot/Kernel accessible to the "symbol" user.
|
||||
if (access("/boot/Kernel", F_OK) == 0) {
|
||||
if (unveil("/boot/Kernel", "r") < 0) {
|
||||
perror("unveil");
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
if (unveil(nullptr, nullptr) < 0) {
|
||||
perror("unveil");
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue