Skip to content

exec_cmd - execute a user space program from the kernel space.

Notifications You must be signed in to change notification settings

dc-fukuoka/exec_cmd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 

Repository files navigation

exec_cmd - execute a user space program from the kernel space.
           kernel development package is required to build.
	   this was tested on linux kernel 4.4, some modifications could be required for newer kernel.
	   please note that the executor becomes root even if a normal user is used.
$ make
$ insmod exec_cmd.ko
$ echo "<commandline>" > /proc/exec_cmd
$ rmmod exec_cmd

ex)
$ cat /tmp/test.sh
#!/bin/sh
echo $* >> /tmp/log
$ echo "/tmp/test.sh this is a test." > /proc/exec_cmd
$ cat /tmp/log
this is a test.

if debug is needed, please do "echo 1 > /sys/module/exec_cmd/parameters/debug".
some debug messages will apear in dmesg.

About

exec_cmd - execute a user space program from the kernel space.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published