aboutsummaryrefslogtreecommitdiff
path: root/src/module.c
diff options
context:
space:
mode:
authorkartofen <mladenovnasko0@gmail.com>2023-04-24 01:00:36 +0300
committerkartofen <mladenovnasko0@gmail.com>2023-04-24 01:00:36 +0300
commit2ca6677667af23ecb1e17479c5b5cc08efa53309 (patch)
tree37c4f62ac9f9ba124b37ca4767348c1f1ad74737 /src/module.c
init
Diffstat (limited to 'src/module.c')
-rw-r--r--src/module.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/module.c b/src/module.c
new file mode 100644
index 0000000..9c56d8b
--- /dev/null
+++ b/src/module.c
@@ -0,0 +1,21 @@
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/printk.h>
+
+static int __init init(void)
+{
+ pr_info("Hello, world 4\n");
+ return 0;
+}
+
+static void __exit exit(void)
+{
+ pr_info("Goodbye, world 4\n");
+}
+
+module_init(init_hello_4);
+module_exit(cleanup_hello_4);
+
+MODULE_LICENSE("GPL");
+MODULE_AUTHOR("Kartofen");
+MODULE_DESCRIPTION("A simple keylogger kernel module");