From b58feaab7a22d8ddf49a6929fc4579929b7ee5bd Mon Sep 17 00:00:00 2001 From: Niklas Cathor Date: Wed, 8 Apr 2020 15:26:05 +0200 Subject: testing/memdump: new aport http://www.porcupine.org/forensics/tct.html utility to dump memory contents to standard output --- .../memdump/06-fall-back-to-default-dev-mem.patch | 23 ++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 testing/memdump/06-fall-back-to-default-dev-mem.patch (limited to 'testing/memdump/06-fall-back-to-default-dev-mem.patch') diff --git a/testing/memdump/06-fall-back-to-default-dev-mem.patch b/testing/memdump/06-fall-back-to-default-dev-mem.patch new file mode 100644 index 0000000000..c35f1e44ad --- /dev/null +++ b/testing/memdump/06-fall-back-to-default-dev-mem.patch @@ -0,0 +1,23 @@ +Description: Fall back to default /dev/(k)mem on linux + Some C libraries (e.g. musl c) don't set _PATH_MEM or _PATH_KMEM + in . If it is not set after including that file, fall + back to /dev/mem and /dev/kmem respectively. +Author: Niklas Cathor +Last-Update: 2020-04-08 +Index: memdump/memdump.c +=================================================================== +--- memdump/memdump.c.orig ++++ memdump/memdump.c +@@ -121,6 +121,12 @@ + #ifdef LINUX2 + #include + #define GETPAGESIZE getpagesize ++ ++#ifndef _PATH_MEM ++#define _PATH_MEM "/dev/mem" ++#define _PATH_KMEM "/dev/kmem" ++#endif ++ + #define SUPPORTED + #endif + -- cgit v1.2.3