Commit graph

27 commits

Author SHA1 Message Date
Adam_pi3
d379e93c29
Move copy of THIS_MODULE to RO page. Fix the problem of 'block_modules' as being a parameter. 2020-03-12 00:21:21 -04:00
Adam_pi3
22941e818e
[CI] fix bug in a new code adding support for batch mode for *_JUMP_LABEL on kernels 5.3+ on x86 platform. 2020-01-20 02:29:04 +00:00
Adam_pi3
aea93dc9cc Introduce a P_CTRL macro for referencing control structure in RO-page 2019-12-20 18:52:06 -05:00
Adam_pi3
d5032b4376 This is a pretty big change in LKRG:
[1] Introducing a RO-page which keeps the most-critical internal structures
  [2] Moving internal control structure (configurable via sysctl interface) to the RO-page
  [3] Introducing a new structure which keeps all dynamically resolved pointers
  [4] Moving a new structure with dynamic pointers to the RO-page
  [5] Refactoring the entire code to be compatible with the new design
  [6] Adding appropriate messages when a new sysctl option is put in place
  [7] A few more minor changes
2019-12-20 15:44:21 -05:00
Adam_pi3
29867f6ecd [1] Add support for JUMP_LABEL batch mode (support for kernels 5.3+)
[2] Some minor fixes
2019-11-02 04:48:55 +00:00
Adam_pi3
b4fbad4989 [1] Add beta version support for ARM32, tested on raspberry pi 3 (model B)
[2] Refactor initialization logic
[3] Some minor fixes
2019-10-31 14:29:46 -04:00
Adam_pi3
66b2042851 Re-enable self-hashing for CI 2019-05-25 00:23:26 +00:00
Adam_pi3
1be9ad649b Cleanups:
[1] Mask exporting global CFLAGS since it might be incompatible when LKRG is part of the bigger build project
 [2] Add default path for UMH when CONFIG_STATIC_USERMODEHELPER is used
 [3] Mask the most noisy STRONG_DEBUG output - doesn't have as much value. It can be always unmasked if needed.
 [4] Add support for the kernels without enabled CONFIG_DYNAMIC_DEBUG
 [5] Add support for the kernels without enabled CONFIG_ACPI
2019-05-23 18:46:52 +00:00
Adam_pi3
fcf720967b [1] Add potential debug compilation option to Makefile
[2] Fix 'colors' issue when systemd service installation fails
[3] [CI] Fix race condition with *_JUMP_LABEL engine resulting potential deadlock when LKRG is initialized parallel with other heavy kernel module (un)loading events
[4] [ED] Rewrite internal logic how LKRG synchronizes with the task's resources - big change
[5] [ED] Filter our kernel threads and system-init process when validation is performed bypassing threads iteration
[6] [ED] Disable IRQ in most cases when ED's pids DB lock is taken. Otherwise, we might have potential race and deadlock with kprobe engine itself, and SoftIRQs might deadlock with pCFI
2019-04-29 19:38:04 +00:00
Adam_pi3
3a9ef66437 [1] Refactor LKRG's code to support various CPU architecture
[2] Add beta version support for ARM64
[3] [ED] Fix FP (race condition) in pCFI in glitching scenario during process update and add memory barrier
[4] [ED] Fix potential FP during LKRG unloading procedure and add memory barrier
[5] [ED] Create own version of user_access_begin() function compatible across various kernel versions and leverage it for argument extraction for *init_module/delete_module
[6] [ED] Fix logic for *init_module/delete_module for kernel with CONFIG_ARCH_HAS_SYSCALL_WRAPPER
2019-04-20 19:17:00 +01:00
Adam_pi3
6a8e3cbe7c Add support for kernels 5.1.x 2019-03-23 02:05:23 +03:00
Adam_pi3
110360ac89 [1] Introduce a new LKRG sysctl interface lkrg.smep_panic enabled by default. [2] Introduce a new LKRG sysctl interface lkrg.umh_lock disabled by default [3] Add SMEP/WP bit verification in a new various places. [4] Enfore Stack Pointer validation on lookup_fast function 2019-02-20 18:35:27 -08:00
Adam_pi3
a214f6eb3e [CI] Complete rewrite of *_JUMP_LABEL support. New logic simplifies some internal algorithms, removes whitelisting logic (not needed anymore) and significantly reduce memory footprint. It's a huge change! 2019-02-15 06:52:21 -08:00
Adam_pi3
06757e0b1f [CI] Propagate errors when kzalloc() fails 2019-01-02 09:20:42 -08:00
Adam_pi3
d17deeb974 Refactor wrapper code 2018-11-13 19:06:13 -05:00
Adam_pi3
72fd62278b Fix code comments and some messages 2018-11-11 11:39:09 -05:00
Adam_pi3
7a91c22e1d [CI] Introduce optional panic() on LKRG CI verification failure. 2018-09-21 20:30:09 -04:00
Adam_pi3
eaab5ec34e [CI] Add *_JUMP_LABEL support for kernel modules - very big and heavy change. 2018-09-04 17:25:37 -07:00
Adam_pi3
3c8047c122 Fix potential deadlock caused by get_online_cpus() function which under-the-hood might-sleep if CONFIG_PREEMPT_VOLUNTARY=y. It was only possible during intensive module-notification being executed parallel with integrity routing executing after module_mutex and kernfs_mutex being unlocked. 2018-03-19 22:10:54 -07:00
Adam_pi3
bd5c151113 Fix possible race condition issue during initialization if LKRG is a boot driver. Thanks goes to Andrei Lavreniyuk 2018-03-16 12:07:36 -07:00
Adam_pi3
fc59cf7c2f Add new sysctl to control LKRG verification on the random events in the system. [CI] Fix database erroring - forgoten goto instruction. 2018-03-06 14:31:49 -08:00
Adam_pi3
575507f44e Add support for virtualization drivers (tested on VBox) 2018-02-02 19:52:21 -08:00
Adam_pi3
d83a339834 1. [ED] Change how the keyrings are supported 2. [ED] Add new logic for 'off' flag 3. [ED] Re-enable 'off_count' 4. [ED] Add ptrace interception 5. Fix typos... 2018-01-31 13:36:52 -08:00
Adam_pi3
1f729a1c11 1. Add new sysctl to silent 'clean' message regardless log_level 2. [ED] Add support for keyctl 3. [ED] Add support for COMPAT 2018-01-17 22:16:43 -08:00
Adam_pi3
51c60bbbc7 Replace SuperFastHash algorithm with SipHash 2017-12-20 20:45:46 -08:00
Adam_pi3
e5924c419a Chane 'unhide' option to be 'hide' and reverse the logic. 2017-10-28 15:03:45 -07:00
Adam_pi3
45cf3846d0 Initial LKRG-main 2017-10-26 22:29:49 -07:00