<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Ability to run script as root in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643087#M809405</link>
    <description>hi,&lt;BR /&gt;&lt;BR /&gt;have you considered also "sudo"?&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;yogeeraj</description>
    <pubDate>Thu, 06 Oct 2005 06:26:58 GMT</pubDate>
    <dc:creator>Yogeeraj_1</dc:creator>
    <dc:date>2005-10-06T06:26:58Z</dc:date>
    <item>
      <title>Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643084#M809402</link>
      <description>All,&lt;BR /&gt;&lt;BR /&gt;I hope somebody can help. I have a requirement to be able to empower our dba's to run their own backup script as root. The script runs commands as a number of different users within the script and only runs succesfully as root. Is there anything I can set on the permissions to enable the oracle user to run the script effectively as root? Sticky bit rings a bell???&lt;BR /&gt;&lt;BR /&gt;Cheers</description>
      <pubDate>Thu, 06 Oct 2005 05:50:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643084#M809402</guid>
      <dc:creator>Adam Noble</dc:creator>
      <dc:date>2005-10-06T05:50:07Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643085#M809403</link>
      <description>"man chmod"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Thu, 06 Oct 2005 06:11:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643085#M809403</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2005-10-06T06:11:45Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643086#M809404</link>
      <description>Thanks Pete!</description>
      <pubDate>Thu, 06 Oct 2005 06:14:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643086#M809404</guid>
      <dc:creator>Adam Noble</dc:creator>
      <dc:date>2005-10-06T06:14:15Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643087#M809405</link>
      <description>hi,&lt;BR /&gt;&lt;BR /&gt;have you considered also "sudo"?&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;yogeeraj</description>
      <pubDate>Thu, 06 Oct 2005 06:26:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643087#M809405</guid>
      <dc:creator>Yogeeraj_1</dc:creator>
      <dc:date>2005-10-06T06:26:58Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643088#M809406</link>
      <description>I'm still trying to find the answer in the man page of chmod....Ha ha so if anyone can tell me please do!!!</description>
      <pubDate>Thu, 06 Oct 2005 06:28:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643088#M809406</guid>
      <dc:creator>Adam Noble</dc:creator>
      <dc:date>2005-10-06T06:28:01Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643089#M809407</link>
      <description>Adam,&lt;BR /&gt;&lt;BR /&gt;See the sections on setuid: Set user ID on file execution.&lt;BR /&gt;&lt;BR /&gt;Make the file owned by root with informix access to it by group and then chmod 4000 to give it setuid.  It will run as root.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Thu, 06 Oct 2005 06:35:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643089#M809407</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2005-10-06T06:35:32Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643090#M809408</link>
      <description>From the man page of chmod&lt;BR /&gt;&lt;BR /&gt;permission  One or more of the following letters:&lt;BR /&gt;&lt;BR /&gt;                            r    Add or delete the read permission for who.&lt;BR /&gt;                            w    Add or delete the write permission for who.&lt;BR /&gt;                            x    Add or delete the execute file (search&lt;BR /&gt;                                 directory) permission for who.&lt;BR /&gt;                            s    Add or delete the set-owner-ID-on-file-                                 execution or set-group-ID-on-file-execution                                  permission for who.  Useful only if u or g                                  is expressed or implied in who.&lt;BR /&gt;</description>
      <pubDate>Thu, 06 Oct 2005 06:36:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643090#M809408</guid>
      <dc:creator>Marco Santerre</dc:creator>
      <dc:date>2005-10-06T06:36:02Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643091#M809409</link>
      <description>Ok chaps cheers! I'm afraid I've never really needed to do this previously so is new to me. I like a bit of Sarcasm anyway so cheers all!!!</description>
      <pubDate>Thu, 06 Oct 2005 06:38:20 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643091#M809409</guid>
      <dc:creator>Adam Noble</dc:creator>
      <dc:date>2005-10-06T06:38:20Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643092#M809410</link>
      <description>By default scripts will not have executiong permission. Check with ls -l &lt;FILE&gt;. Then change the execution permission with chmod command as,&lt;BR /&gt;&lt;BR /&gt; chmod u+x &lt;FILE&gt; user permission&lt;BR /&gt; chmod g+x &lt;FILE&gt; group permission&lt;BR /&gt; chmod o+x &lt;FILE&gt; others permission&lt;BR /&gt;&lt;BR /&gt; Or else you can execute as,&lt;BR /&gt;&lt;BR /&gt; sh &lt;FILENAME&gt;&lt;BR /&gt;&lt;BR /&gt;hth.&lt;BR /&gt;&lt;/FILENAME&gt;&lt;/FILE&gt;&lt;/FILE&gt;&lt;/FILE&gt;&lt;/FILE&gt;</description>
      <pubDate>Thu, 06 Oct 2005 06:40:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643092#M809410</guid>
      <dc:creator>Muthukumar_5</dc:creator>
      <dc:date>2005-10-06T06:40:12Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643093#M809411</link>
      <description>I think "sudo" will be better option.</description>
      <pubDate>Thu, 06 Oct 2005 06:40:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643093#M809411</guid>
      <dc:creator>Vibhor Kumar Agarwal</dc:creator>
      <dc:date>2005-10-06T06:40:47Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643094#M809412</link>
      <description>I hope i have partially read your question. sudo is suitable. You can use expect script which will do your requirement also.&lt;BR /&gt;&lt;BR /&gt;If you do normally as,&lt;BR /&gt;&lt;BR /&gt;$ su root&lt;BR /&gt;Enter Passwd: &lt;BR /&gt;&lt;BR /&gt;with expect scripting it will give input by expecting Enter Passwd: strings.&lt;BR /&gt;&lt;BR /&gt;Another way is piping telnet login to localhost as simply as,&lt;BR /&gt;&lt;BR /&gt;(&lt;BR /&gt;  sleep 1&lt;BR /&gt;  echo "root"&lt;BR /&gt;  sleep 1&lt;BR /&gt;  echo "&lt;PASSWD&gt;"&lt;BR /&gt;  sleep 1&lt;BR /&gt;  echo "command to run"&lt;BR /&gt;  sleep 1&lt;BR /&gt;  echo "exit"&lt;BR /&gt;) | telnet localhost&lt;BR /&gt;&lt;BR /&gt;change username of root and passwd accordingly to user.&lt;BR /&gt;&lt;BR /&gt;hth. &lt;BR /&gt;&lt;/PASSWD&gt;</description>
      <pubDate>Thu, 06 Oct 2005 06:51:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643094#M809412</guid>
      <dc:creator>Muthukumar_5</dc:creator>
      <dc:date>2005-10-06T06:51:07Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643095#M809413</link>
      <description>Hello all,&lt;BR /&gt;&lt;BR /&gt;Unless I'm mistaken, you can't set up a script as SUID. It is such a big security hole that they set it up so SUID is ignored on shell scripts. &lt;BR /&gt;&lt;BR /&gt;I think if you put a C wrapper around your script and set up SUID on that, it might work. &lt;BR /&gt;&lt;BR /&gt;Your best bet is sudo.&lt;BR /&gt;&lt;BR /&gt;David</description>
      <pubDate>Thu, 06 Oct 2005 07:53:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643095#M809413</guid>
      <dc:creator>David Child_1</dc:creator>
      <dc:date>2005-10-06T07:53:37Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643096#M809414</link>
      <description>Running a script as root is a common requirement but is an extreme risk to your system's stability and security. The reason is that even if you carefully write the script to prevent getting to a shell prompt, a user can gain unlimited root access. Yes, you can set the SUID bit on the script, change the ownership to root and the script will run as root. You can prevent SUID programs and scripts from running by adding the mount option: nosuid to selected mountpoints. DO NOT use nosuid on /, /usr, /opt since SUID is mandatory for many HP-UX programs. But directories that allow users to create files (/var, /home) should not allow SUID scripts and programs.</description>
      <pubDate>Thu, 06 Oct 2005 08:07:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643096#M809414</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2005-10-06T08:07:43Z</dc:date>
    </item>
    <item>
      <title>Re: Ability to run script as root</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643097#M809415</link>
      <description>Would this make sense in your environment?&lt;BR /&gt;&lt;BR /&gt;Restrict the script to root only and place it in the root crontab.  Set it to run hourly (or whatever makes sense)to look for a file trigger.  If the trigger file exists, then the backup starts.  The users can create the trigger file.  If the users must supply options, then the option can be placed in (and read from) the trigger file.  The file can be removed as part of the backup script.&lt;BR /&gt;&lt;BR /&gt;Using this technique allows you to maintain security.</description>
      <pubDate>Fri, 07 Oct 2005 08:39:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/ability-to-run-script-as-root/m-p/3643097#M809415</guid>
      <dc:creator>Steve McClendon_1</dc:creator>
      <dc:date>2005-10-07T08:39:38Z</dc:date>
    </item>
  </channel>
</rss>

