On Oct 6, 9:29 pm, |MKSM| <mksm.s... / gmail.com> wrote:
> Hello.
>
> I have written an app in Ruby for my company and I was the only one
> that had acess to read/execute it. I've hired someone to help me with
> daily work and that includes having him execute a set of those Ruby
> scripts.
>
> Is it possible to allow him to only execute the code and not give read
> permission? All boxes are running Linux.
>
> Regards,
>
> Ricardo Amorim
> mapaBRASIL.net

I guess that's not really a Ruby question, but I have an idea...

Sudo may be the best answer. Allow the user to sudo the Ruby app as
another user with read access to the script. You'll want to read the
sudoers man page as you'll need the no authentication option and other
tidbits. Then you can wrap up the sudo command (something like sudo -u
reading_user /path/to/app) with an alias or shell script that your
underling can call. There are still security concerns, but you have
more control than with the setuid option, I think.

Jeremy