<?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 Limitations of the  -cmddirname query options when creating new roles in ONTAP Discussions</title>
    <link>https://community.netapp.com/t5/ONTAP-Discussions/Limitations-of-the-cmddirname-query-options-when-creating-new-roles/m-p/147791#M32905</link>
    <description>&lt;P&gt;I have a customer who is interested in locking down some users to be able to access specific volumes and perform a limited set of operations on those volumes.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sounds like a perfect scenario to use a custom role.&amp;nbsp; I've done some lab on demand testing to sound out the requirements.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The requirements for the role are to have the following commands avaialble.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot create&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt; vol snapshot delete &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot show &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot restore &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;set -confirmations off&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;So far so good.&amp;nbsp; The second requirement is that of each user should only be able to perform the above options on a specific set of volumes.&amp;nbsp; To make it easy lets call them&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;produser - accessing volumes prod*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;testuser - accessing volumes test*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;devuser - accessing volumes dev*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The issue I've hit is with the snap restore command set.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can create a role with the following&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume -query "-volume prod*" -access all&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But this doesn't include the volume snapshot restore commands&amp;nbsp; So we add the follow&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume snapshot -query "-volume prod*" -access all&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;again this doesn't include the volume snapshot restore commands.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So when we attempt to add this final extentionto the allowed commands&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume snapshot restore&amp;nbsp; -query "-volume prod*" -access all&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"which includes the snapshot promote command"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The wildcard on the query is rejected.&amp;nbsp; So we can only add a single volume here, with multiple volumes required.&amp;nbsp; Is there way to list a set of volumes we can allow the user to perform restores for?&amp;nbsp; Pipe and command seperation doen't seem to apply.&amp;nbsp; I can't see anything in the documentation that hints at adding mulitple valid queries.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The prod, test and dev volumes are on the same vserver so to get the granularity we require if possible we'ed need to lock down the command&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 04 Jun 2025 12:39:22 GMT</pubDate>
    <dc:creator>STEVEWILLSQ</dc:creator>
    <dc:date>2025-06-04T12:39:22Z</dc:date>
    <item>
      <title>Limitations of the  -cmddirname query options when creating new roles</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Limitations-of-the-cmddirname-query-options-when-creating-new-roles/m-p/147791#M32905</link>
      <description>&lt;P&gt;I have a customer who is interested in locking down some users to be able to access specific volumes and perform a limited set of operations on those volumes.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sounds like a perfect scenario to use a custom role.&amp;nbsp; I've done some lab on demand testing to sound out the requirements.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The requirements for the role are to have the following commands avaialble.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot create&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt; vol snapshot delete &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot show &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;vol snapshot restore &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;set -confirmations off&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;So far so good.&amp;nbsp; The second requirement is that of each user should only be able to perform the above options on a specific set of volumes.&amp;nbsp; To make it easy lets call them&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;produser - accessing volumes prod*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;testuser - accessing volumes test*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;devuser - accessing volumes dev*&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The issue I've hit is with the snap restore command set.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can create a role with the following&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume -query "-volume prod*" -access all&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But this doesn't include the volume snapshot restore commands&amp;nbsp; So we add the follow&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume snapshot -query "-volume prod*" -access all&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;again this doesn't include the volume snapshot restore commands.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So when we attempt to add this final extentionto the allowed commands&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;sec login role create -role prodrole -cmddirname volume snapshot restore&amp;nbsp; -query "-volume prod*" -access all&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"which includes the snapshot promote command"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The wildcard on the query is rejected.&amp;nbsp; So we can only add a single volume here, with multiple volumes required.&amp;nbsp; Is there way to list a set of volumes we can allow the user to perform restores for?&amp;nbsp; Pipe and command seperation doen't seem to apply.&amp;nbsp; I can't see anything in the documentation that hints at adding mulitple valid queries.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The prod, test and dev volumes are on the same vserver so to get the granularity we require if possible we'ed need to lock down the command&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 12:39:22 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Limitations-of-the-cmddirname-query-options-when-creating-new-roles/m-p/147791#M32905</guid>
      <dc:creator>STEVEWILLSQ</dc:creator>
      <dc:date>2025-06-04T12:39:22Z</dc:date>
    </item>
    <item>
      <title>Re: Limitations of the  -cmddirname query options when creating new roles</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Limitations-of-the-cmddirname-query-options-when-creating-new-roles/m-p/148717#M33096</link>
      <description>&lt;P&gt;Working with Netapp, this has been logged as the following BURT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://mysupport.netapp.com/NOW/cgi-bin/bol?Type=Detail&amp;amp;Display=1237037" target="_blank"&gt;https://mysupport.netapp.com/NOW/cgi-bin/bol?Type=Detail&amp;amp;Display=1237037&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 05 Jun 2019 12:21:27 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Limitations-of-the-cmddirname-query-options-when-creating-new-roles/m-p/148717#M33096</guid>
      <dc:creator>STEVEWILLSQ</dc:creator>
      <dc:date>2019-06-05T12:21:27Z</dc:date>
    </item>
  </channel>
</rss>

