<?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: REST API for DACLs Not Accurate in Network Access Control</title>
    <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4903600#M583387</link>
    <description>&lt;P&gt;Hello Thomas,&lt;/P&gt;&lt;P&gt;thank you for your script, it seams very useful, but i have question.&lt;/P&gt;&lt;P&gt;I am trying to use your python script "ise_get.py downloadableacl" or "ise_get_ers_resource.py downloadableacl" and it seems it give me 100 of records (we have approx 260 dACLs). How can get all dACLs or page through all pages with these scripts?&lt;/P&gt;</description>
    <pubDate>Fri, 11 Aug 2023 07:49:24 GMT</pubDate>
    <dc:creator>Daniel G.</dc:creator>
    <dc:date>2023-08-11T07:49:24Z</dc:date>
    <item>
      <title>REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833165#M474104</link>
      <description>&lt;P&gt;I don't open TAC cases for REST API issues because I don't have the time.&amp;nbsp; I am just posting to see if this is a known issue on 2.4 patch 6.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The current policy export XML file doesn't contain the contents of the DACLs (another issue that should get fixed) so I am trying to use the REST APIs to pull authorization profiles, tie them to DACL names and get the DACL contents.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can make the REST call to get all the authorization profiles:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;https://&amp;lt;Admin_Node&amp;gt;:9060/ers/config/authorizationprofile&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can then parse through that to get the IDs for each authorization profile and make calls to get the authorization profile contents:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;https://&amp;lt;Admin_Node&amp;gt;:9060/ers/config/authorizationprofile/00ec24a0-f2ad-11e8-8505-005056830148&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the results it will have the DACL name;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"daclName": "Vendor_DACL",&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The DACL name is useless because you can't do a filter by name when you make a DACL REST query (another problem that should be fixed):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;https://&amp;lt;Admin_Node&amp;gt;:9060/ers/config/downloadableacl?filter=name.EQ.Vendor_DAC&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So now I am forced to do a Get-All on the DACLs and parse my way through the result.&amp;nbsp; Not a problem except the Get-All is busted and doesn't return all the DACLs.&amp;nbsp; The first indicator of the problem is:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;{&lt;BR /&gt;"SearchResult": {&lt;BR /&gt;"total": 0,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Even though the query returned 20 DACLs to me.&amp;nbsp; Okay so it returned 20 DACLs out of my 110 DACLs maybe it is a paging issue.&amp;nbsp; If that were true there should be an HREF at the bottom of the output to the next page.&amp;nbsp; There is nothing for that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is this a known issue?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2019 17:10:59 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833165#M474104</guid>
      <dc:creator>paul</dc:creator>
      <dc:date>2019-04-05T17:10:59Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833169#M474106</link>
      <description>&lt;P&gt;This, sounds painful... And it's unfortunate to hear as I plan to use the API to present things like dacls to other teams since the RBAC controls in ISE GUI are so poor.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2019 17:16:43 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833169#M474106</guid>
      <dc:creator>anthonylofreso</dc:creator>
      <dc:date>2019-04-05T17:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833215#M474107</link>
      <description>Okay, I got a little father.  Even though the HREF to next page wasn't there in the general call I was able to work my way through the list by doing:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;https://&lt;ADMIN node=""&gt;:9060/ers/config/downloadableacl?page=1&amp;lt;&amp;gt;&lt;BR /&gt;&lt;BR /&gt;https:// &lt;ADMIN node=""&gt;:9060/ers/config/downloadableacl?page=2&amp;lt;&amp;gt;&lt;BR /&gt;&lt;BR /&gt;etc.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Because there is no count reported the only way you know you are finished is if you do a search of the result for "id:".  If that doesn't exist then no DACLs were in the output.  So at 110 DACLS and 20 a page I stopped seeing results on page 7.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Not great but something I can work with.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/ADMIN&gt;&lt;/ADMIN&gt;</description>
      <pubDate>Fri, 05 Apr 2019 18:32:33 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833215#M474107</guid>
      <dc:creator>paul</dc:creator>
      <dc:date>2019-04-05T18:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833238#M474108</link>
      <description>&lt;P&gt;Is there any way to change the default pagination value?&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2019 18:59:52 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/3833238#M474108</guid>
      <dc:creator>anthonylofreso</dc:creator>
      <dc:date>2019-04-05T18:59:52Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4847243#M582048</link>
      <description>&lt;P&gt;Yes use ?size=pageSize&lt;/P&gt;</description>
      <pubDate>Thu, 01 Jun 2023 22:21:44 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4847243#M582048</guid>
      <dc:creator>Jeffrey Ness</dc:creator>
      <dc:date>2023-06-01T22:21:44Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4856503#M582288</link>
      <description>&lt;P&gt;The default ISE ERS REST page size is 20 with a max of 100. See &lt;A href="https://developer.cisco.com/docs/identity-services-engine/latest/#!pagination" data-depth="1" data-tag="navigation-item" data-url="pagination" target="_blank"&gt;Pagination&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;You will need to page through all of the pages to get all of the dACL &lt;FONT face="courier new,courier"&gt;id&lt;/FONT&gt; attributes (UUIDs).&lt;/P&gt;
&lt;P&gt;The &lt;FONT face="courier new,courier"&gt;GET&amp;nbsp;/ers/config/downloadableacl&lt;/FONT&gt; only returns the id, name, and description attributes. To get the &lt;FONT face="courier new,courier"&gt;dacl&lt;/FONT&gt; attribute (contents), you will need to perform an additional &lt;FONT face="courier new,courier"&gt;GET&amp;nbsp;/ers/config/downloadableacl&lt;/FONT&gt;/&lt;FONT face="courier new,courier"&gt;{id}&lt;/FONT&gt; on each and every ACL as listed in the &lt;FONT face="courier new,courier"&gt;link.href&lt;/FONT&gt; attributes below.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;curl  --include  --insecure  --location \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --user $ISE_REST_USERNAME:$ISE_REST_PASSWORD \
  --request GET https://$ISE_HOSTNAME/ers/config/downloadableacl

HTTP/1.1 200

{
  "SearchResult" : {
    "total" : 4,
    "resources" : [ {
      "id" : "9825aa40-8c01-11e6-996c-525400b48521",
      "name" : "DENY_ALL_IPV4_TRAFFIC",
      "description" : "Deny all ipv4 traffic",
      "link" : {
        "rel" : "self",
        "href" : "https://ise.trust0.net/ers/config/downloadableacl/9825aa40-8c01-11e6-996c-525400b48521",
        "type" : "application/json"
      }
    }, {
      "id" : "380c6620-f532-11ed-8ed8-0050568fa0ed",
      "name" : "DENY_ALL_IPV6_TRAFFIC",
      "description" : "Deny all ipv6 traffic",
      "link" : {
        "rel" : "self",
        "href" : "https://ise.trust0.net/ers/config/downloadableacl/380c6620-f532-11ed-8ed8-0050568fa0ed",
        "type" : "application/json"
      }
    }, {
      "id" : "982498d0-8c01-11e6-996c-525400b48521",
      "name" : "PERMIT_ALL_IPV4_TRAFFIC",
      "description" : "Allow all ipv4 Traffic",
      "link" : {
        "rel" : "self",
        "href" : "https://ise.trust0.net/ers/config/downloadableacl/982498d0-8c01-11e6-996c-525400b48521",
        "type" : "application/json"
      }
    }, {
      "id" : "380a4340-f532-11ed-8ed8-0050568fa0ed",
      "name" : "PERMIT_ALL_IPV6_TRAFFIC",
      "description" : "Allow all ipv6 Traffic",
      "link" : {
        "rel" : "self",
        "href" : "https://ise.trust0.net/ers/config/downloadableacl/380a4340-f532-11ed-8ed8-0050568fa0ed",
        "type" : "application/json"
      }
    } ]
  }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;If it helps, I've written an &lt;A href="https://github.com/1homas/ISE_Python_Scripts/blob/main/ise_get.py" target="_self"&gt;&lt;FONT face="courier new,courier"&gt;ise_get.py&lt;/FONT&gt;&lt;/A&gt; Python script to make this fast and easy for you:&lt;/P&gt;
&lt;LI-CODE lang="python"&gt;❱ ise_get.py downloadableacl --details
{
  "downloadableacl": [
    {
      "id": "9825aa40-8c01-11e6-996c-525400b48521",
      "name": "DENY_ALL_IPV4_TRAFFIC",
      "description": "Deny all ipv4 traffic",
      "dacl": "deny ip any any",
      "daclType": "IPV4"
    },
    {
      "id": "380c6620-f532-11ed-8ed8-0050568fa0ed",
      "name": "DENY_ALL_IPV6_TRAFFIC",
      "description": "Deny all ipv6 traffic",
      "dacl": "deny ipv6 any any",
      "daclType": "IPV6"
    },
    {
      "id": "982498d0-8c01-11e6-996c-525400b48521",
      "name": "PERMIT_ALL_IPV4_TRAFFIC",
      "description": "Allow all ipv4 Traffic",
      "dacl": "permit ip any any",
      "daclType": "IPV4"
    },
    {
      "id": "380a4340-f532-11ed-8ed8-0050568fa0ed",
      "name": "PERMIT_ALL_IPV6_TRAFFIC",
      "description": "Allow all ipv6 Traffic",
      "dacl": "permit ipv6 any any",
      "daclType": "IPV6"
    }
  ]
}&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 16 Jun 2023 21:29:23 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4856503#M582288</guid>
      <dc:creator>thomas</dc:creator>
      <dc:date>2023-06-16T21:29:23Z</dc:date>
    </item>
    <item>
      <title>Re: REST API for DACLs Not Accurate</title>
      <link>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4903600#M583387</link>
      <description>&lt;P&gt;Hello Thomas,&lt;/P&gt;&lt;P&gt;thank you for your script, it seams very useful, but i have question.&lt;/P&gt;&lt;P&gt;I am trying to use your python script "ise_get.py downloadableacl" or "ise_get_ers_resource.py downloadableacl" and it seems it give me 100 of records (we have approx 260 dACLs). How can get all dACLs or page through all pages with these scripts?&lt;/P&gt;</description>
      <pubDate>Fri, 11 Aug 2023 07:49:24 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/rest-api-for-dacls-not-accurate/m-p/4903600#M583387</guid>
      <dc:creator>Daniel G.</dc:creator>
      <dc:date>2023-08-11T07:49:24Z</dc:date>
    </item>
  </channel>
</rss>

