<?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 Check sudo Rights? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/check-sudo-rights/m-p/2515224#M22716</link>
    <description>Hello All!&lt;BR /&gt;&lt;BR /&gt;I would like to check via a script if the user running the script has rights to sudo (at all). I setup a script to do this originally using a version that could take the password from stdin. However the version I have on the system I am not using does not have this option. sudo version 1.6.2b1&lt;BR /&gt;&lt;BR /&gt;Before I could just `echo "" | sudo -l -S` and check the exit code/status. If it was 0 they the user has rights to some sudo'ing, otherwise they did not. &lt;BR /&gt;&lt;BR /&gt;There is not a precompiled binary of the newest version that has the -S option for HP/UX 11.00 that I know of. &lt;BR /&gt;&lt;BR /&gt;This there any why to get the same thing using sudo version 1.6.2b1?&lt;BR /&gt;&lt;BR /&gt;Without the -S option sudo always prompts for the password for users who do not have any sudo rights. I want it to just fail and allow me to check via the exit status.&lt;BR /&gt;&lt;BR /&gt;- Justin&lt;BR /&gt;</description>
    <pubDate>Mon, 09 Apr 2001 17:11:02 GMT</pubDate>
    <dc:creator>Justin Willoughby</dc:creator>
    <dc:date>2001-04-09T17:11:02Z</dc:date>
    <item>
      <title>Check sudo Rights?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/check-sudo-rights/m-p/2515224#M22716</link>
      <description>Hello All!&lt;BR /&gt;&lt;BR /&gt;I would like to check via a script if the user running the script has rights to sudo (at all). I setup a script to do this originally using a version that could take the password from stdin. However the version I have on the system I am not using does not have this option. sudo version 1.6.2b1&lt;BR /&gt;&lt;BR /&gt;Before I could just `echo "" | sudo -l -S` and check the exit code/status. If it was 0 they the user has rights to some sudo'ing, otherwise they did not. &lt;BR /&gt;&lt;BR /&gt;There is not a precompiled binary of the newest version that has the -S option for HP/UX 11.00 that I know of. &lt;BR /&gt;&lt;BR /&gt;This there any why to get the same thing using sudo version 1.6.2b1?&lt;BR /&gt;&lt;BR /&gt;Without the -S option sudo always prompts for the password for users who do not have any sudo rights. I want it to just fail and allow me to check via the exit status.&lt;BR /&gt;&lt;BR /&gt;- Justin&lt;BR /&gt;</description>
      <pubDate>Mon, 09 Apr 2001 17:11:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/check-sudo-rights/m-p/2515224#M22716</guid>
      <dc:creator>Justin Willoughby</dc:creator>
      <dc:date>2001-04-09T17:11:02Z</dc:date>
    </item>
  </channel>
</rss>

