<?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: Cisco ISE and guest user API error in Network Access Control</title>
    <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171653#M591665</link>
    <description>&lt;P&gt;Ops, wrong category&lt;/P&gt;</description>
    <pubDate>Thu, 05 Sep 2024 12:22:17 GMT</pubDate>
    <dc:creator>trondaker</dc:creator>
    <dc:date>2024-09-05T12:22:17Z</dc:date>
    <item>
      <title>Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171650#M591664</link>
      <description>&lt;P&gt;Trying to get all guest users listed in an API-call, but the API responds with:&amp;nbsp;com.cisco.cpm.guestaccess.apiservices.exception.PortalSystemException: Sponsor users sponsor groups are not available any more"&lt;BR /&gt;&lt;BR /&gt;The API-call that throws me this error is:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;host = "1.1.1.1"&lt;BR /&gt;user = "user"&lt;BR /&gt;password = "passord"&lt;/P&gt;&lt;P&gt;conn = http.client.HTTPSConnection("{}:9060".format(host), context=ssl.SSLContext(ssl.PROTOCOL_TLSv1_2))&lt;/P&gt;&lt;P&gt;creds = str.encode(':'.join((user, password)))&lt;BR /&gt;encodedAuth = bytes.decode(base64.b64encode(creds))&lt;/P&gt;&lt;P&gt;headers = {&lt;BR /&gt;'accept': "application/json",&lt;BR /&gt;'content-type': "application/json",&lt;BR /&gt;'authorization': " ".join(("Basic",encodedAuth)),&lt;BR /&gt;'cache-control': "no-cache",&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;conn.request("GET", "/ers/config/guestuser", headers=headers)&lt;/P&gt;&lt;P&gt;res = conn.getresponse()&lt;BR /&gt;data = res.read()&lt;/P&gt;&lt;P&gt;print(data)&lt;BR /&gt;&lt;BR /&gt;Running 3.1 patch 9 - same issue here:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://community.cisco.com/t5/network-access-control/ise-2-4-guest-api-error/td-p/4129662" target="_blank" rel="noopener"&gt;https://community.cisco.com/t5/network-access-control/ise-2-4-guest-api-error/td-p/4129662&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;According to the API-doc this should work?&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 12:19:37 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171650#M591664</guid>
      <dc:creator>trondaker</dc:creator>
      <dc:date>2024-09-05T12:19:37Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171653#M591665</link>
      <description>&lt;P&gt;Ops, wrong category&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 12:22:17 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171653#M591665</guid>
      <dc:creator>trondaker</dc:creator>
      <dc:date>2024-09-05T12:22:17Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171674#M591667</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; -&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/81999"&gt;@trondaker&lt;/a&gt;&amp;nbsp;I moved it to the correct group ,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;M.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 12:53:53 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171674#M591667</guid>
      <dc:creator>Mark Elsen</dc:creator>
      <dc:date>2024-09-05T12:53:53Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171689#M591670</link>
      <description>&lt;P&gt;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/81999"&gt;@trondaker&lt;/a&gt;&amp;nbsp;there is an example here&amp;nbsp;&lt;A href="https://developer.cisco.com/docs/identity-services-engine/latest/get-all-guest-users/#execution" target="_blank"&gt;https://developer.cisco.com/docs/identity-services-engine/latest/get-all-guest-users/#execution&lt;/A&gt;&amp;nbsp;- if you share the error message this would help narrow down your issue.&lt;/P&gt;
&lt;P&gt;Hope this helps.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 13:20:13 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171689#M591670</guid>
      <dc:creator>bigevilbeard</dc:creator>
      <dc:date>2024-09-05T13:20:13Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171914#M591675</link>
      <description>&lt;P&gt;Ran the exact same code as the link above, replaced username/pass/host and got the following:&lt;BR /&gt;&lt;BR /&gt;Body:&lt;BR /&gt;{&lt;BR /&gt;"ERSResponse" : {&lt;BR /&gt;"operation" : "GET-getAll-guestuser",&lt;BR /&gt;"messages" : [ {&lt;BR /&gt;"title" : "com.cisco.cpm.guestaccess.apiservices.exception.PortalSystemException: Sponsor user's sponsor groups are not available any more",&lt;BR /&gt;"type" : "ERROR",&lt;BR /&gt;"code" : "CRUD operation exception"&lt;BR /&gt;} ],&lt;BR /&gt;"link" : {&lt;BR /&gt;"rel" : "related",&lt;BR /&gt;"href" : "https://x.x.x.x:9060/ers/config/guestuser/",&lt;BR /&gt;"type" : "application/xml"&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 17:38:15 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171914#M591675</guid>
      <dc:creator>trondaker</dc:creator>
      <dc:date>2024-09-05T17:38:15Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171979#M591684</link>
      <description>&lt;P&gt;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/81999"&gt;@trondaker&lt;/a&gt;&amp;nbsp;&lt;SPAN&gt;It looks like the script executed successfully, but the response from the server indicates an error, as you see.&amp;nbsp;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;It looks like server is indicating that the sponsor user's sponsor groups are no longer available, which is preventing the retrieval of guest users. You may need to investigate why the sponsor groups are no longer available or update the script to handle this error scenario.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Sep 2024 19:51:39 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5171979#M591684</guid>
      <dc:creator>bigevilbeard</dc:creator>
      <dc:date>2024-09-05T19:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192431#M591738</link>
      <description>&lt;P&gt;Hi again&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/352839"&gt;@bigevilbeard&lt;/a&gt;&amp;nbsp;!&lt;BR /&gt;I logged on to the sponsor portal and checked the sponsor-field, and it is empty for all accounts. This might be what the API is referring to, but im kind of lost as to how to retrieve all guest users when this field is empty? There seems to be no other way then the&lt;SPAN&gt;GET", "/ers/config/guestuser"-path. I tried to iterate through all users to set the sponsor-field, but i cant see a way to it. Any tips? Is there a way to delete all users, to start fresh? From the portal i would have to delete 10 users at a time, that would take forever.&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Sep 2024 06:32:26 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192431#M591738</guid>
      <dc:creator>trondaker</dc:creator>
      <dc:date>2024-09-10T06:32:26Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192503#M591748</link>
      <description>&lt;P&gt;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/81999"&gt;@trondaker&lt;/a&gt;&amp;nbsp;hmm so i guess you could update sponsor field for each guest user through the sponsor portal, however, as you mentioned, this can be a time consuming process.. I think you might be able to do this with the API, try&amp;nbsp;&lt;SPAN&gt;he&amp;nbsp;&lt;/SPAN&gt;&lt;CODE&gt;PUT /ers/config/guestuser/{id}&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;and&amp;nbsp;update a guest users information, which should include the sponsor field, your code will&amp;nbsp; need to iterate through each guest user and update the sponsor field here.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I dont know if there is a bulk delete endpoint in the ISE API. I would use the&amp;nbsp;&lt;CODE&gt;DELETE /ers/config/guestuser/{id}&lt;/CODE&gt;&amp;nbsp;and&amp;nbsp;delete individual guest users this way using a script to iterate through each guest user and delete them one by one, again this would still be a time consuming process, but it might be faster than doing it manually through the portal.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Sep 2024 09:12:27 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192503#M591748</guid>
      <dc:creator>bigevilbeard</dc:creator>
      <dc:date>2024-09-10T09:12:27Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192534#M591749</link>
      <description>&lt;P&gt;Thanks, ill try - but when iterating over the ids, is there any way to get those ids besides the call that doesnt work?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Sep 2024 10:09:26 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192534#M591749</guid>
      <dc:creator>trondaker</dc:creator>
      <dc:date>2024-09-10T10:09:26Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco ISE and guest user API error</title>
      <link>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192546#M591751</link>
      <description>&lt;P&gt;You might try and&amp;nbsp;&lt;SPAN&gt;use the API endpoint to retrieve a list of all users (not just guest users) and then filter out the non-guest users? It&amp;nbsp;might not be affected by the&amp;nbsp;&lt;CODE&gt;PortalSystemException&lt;/CODE&gt;&amp;nbsp;since it's not specific to guest users too, but thats a guess here.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Hope this helps.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Sep 2024 10:32:16 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-access-control/cisco-ise-and-guest-user-api-error/m-p/5192546#M591751</guid>
      <dc:creator>bigevilbeard</dc:creator>
      <dc:date>2024-09-10T10:32:16Z</dc:date>
    </item>
  </channel>
</rss>

