summaryrefslogtreecommitdiff
path: root/libk/stack_protector.c
blob: 78d0302ecb16c094e787fb1292ac5507a9267b75 (plain)
1
2
3
4
5
6
7
8
9
10
11
#include <kernel/panic.h>
#include <stdint.h>
#include <stddef.h>

#define STACK_CHK_GUARD 0x32E3429E

uintptr_t __stack_chk_guard = STACK_CHK_GUARD;

__attribute__((noreturn)) void __stack_chk_fail(void) {
        panic("STACK SMASHING IN KERNEL ADDRESS SPACE");
}