[CALUG] Putting a Oracle User ID and Password in the Perl Script.

Jason Dixon jason at dixongroup.net
Wed Mar 25 12:43:42 EDT 2009


On Wed, Mar 25, 2009 at 12:37:47PM -0400, William Kupersanin wrote:
> 
> On Wed, Mar 25, 2009 at 11:44 AM, Jason Dixon <jason at dixongroup.net> wrote:
> 
> > On Wed, Mar 25, 2009 at 08:41:27AM -0700, Rod Clayton wrote:
> > >
> > > I have a perl script that I would like people to be able to run but not
> > read.  It has an Oracle user ID and a password in the script.  I have tried
> > making it execute only, but then they get a permission denied when they try
> > to run the script.
> > >
> > > Is there a better way to handle This?
> >
> > Chown it to a secure user with 700 perms.  Give them sudo rights only to
> > run the
> > script as that user.
> 
> How about creating a limited user account. Put the password in a file owned
> and readable only by that account, and then making the Perl script setuid to
> that user, and have it read from the file.

That's what I meant by a "secure user".  There is no reason for a
separate password file if you chmod/chown it and use sudo as I
described.

-- 
Jason Dixon
DixonGroup Consulting
http://www.dixongroup.net/




More information about the CALUG mailing list