can't execute scripts compiled with shc

Posted by serilain on Super User See other posts from Super User or by serilain
Published on 2013-10-30T20:41:58Z Indexed on 2013/10/31 9:59 UTC
Read the original article Hit count: 289

Filed under:
|

I'm trying to use SHC to compile a shell script so that I can set the SUID bit on it and obfuscate what it's doing (I'm attempting to have it run as part of all new users' .bashrc).

As a test, I wrote a script that's simply:

#!/bin/bash
env

And compiled it using shc -r -f script.sh

However, when I try to run the resulting script by simply doing ./script.sh.x, even after setting it to 777 (just for testing purposes), I get "Operation not permitted; killed" unless I run it as sudo (which I don't want to have to do). Am I running afoul of some Ubuntu permissions that won't let me run binaries created by shc?

Thanks!

© Super User or respective owner

Related posts about shell

Related posts about permissions