I have built an experimental patch to execute a user program from within the kernel by adding a flag to config.ini... I haven't worked out passing parameters to it but it seems to work with the viewer program... upload the viewer binary to somewhere on the empeg, chmod 755 it and then add a line to config.ini

[hijack]
; full path to execute... (no parameters available yet)
exec=/drive0/bin/viewer


I am trying to get the code to work for the kftpd SITE EXEC command but it doesn't seem to work yet... will keep working on it... For the moment this might be an easier way to run user programs rather than having to put a custom /sbin/init or /sbin/hijack on the root partition (which gets wiped with an upgrade)... I haven't tested it with many other executables but would be interested on hearing whether it works with user binaries other people have written... I don't think it will execute scripts at the moment... will work on that when I work out how to pass parameters...

Cheers

Kim

PS patch is against hijack v236


Attachments
77420-exec.patch (191 downloads)