<?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: Setting shared key in Federated scenario in ArcGIS Enterprise Portal Questions</title>
    <link>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676046#M9168</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There's no need to modify the shared key of distinct federated Server sites. You'd really only need to do that if you're setting up siloed ArcGIS Server sites, which you can't federate anyway.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://enterprise.arcgis.com/en/server/latest/install/windows/single-machine-high-availability-active-passive-deployment.htm" title="https://enterprise.arcgis.com/en/server/latest/install/windows/single-machine-high-availability-active-passive-deployment.htm"&gt;Single-machine high-availability (active-passive) deployment—ArcGIS Server (Windows) Installation Guide (10.5) | ArcGI…&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/410588_pastedImage_2.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 04 Jun 2018 22:03:41 GMT</pubDate>
    <dc:creator>JonathanQuinn</dc:creator>
    <dc:date>2018-06-04T22:03:41Z</dc:date>
    <item>
      <title>Setting shared key in Federated scenario</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676045#M9167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a setup of 10.6 with Portal + 2 Sites: Federated Site and Hosting Site. Each component has its own, different shared key. Should I make sure all actually have the same shared key?&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Jun 2018 17:47:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676045#M9167</guid>
      <dc:creator>SzymonPiskula1</dc:creator>
      <dc:date>2018-06-03T17:47:04Z</dc:date>
    </item>
    <item>
      <title>Re: Setting shared key in Federated scenario</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676046#M9168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There's no need to modify the shared key of distinct federated Server sites. You'd really only need to do that if you're setting up siloed ArcGIS Server sites, which you can't federate anyway.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://enterprise.arcgis.com/en/server/latest/install/windows/single-machine-high-availability-active-passive-deployment.htm" title="https://enterprise.arcgis.com/en/server/latest/install/windows/single-machine-high-availability-active-passive-deployment.htm"&gt;Single-machine high-availability (active-passive) deployment—ArcGIS Server (Windows) Installation Guide (10.5) | ArcGI…&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/410588_pastedImage_2.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Jun 2018 22:03:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676046#M9168</guid>
      <dc:creator>JonathanQuinn</dc:creator>
      <dc:date>2018-06-04T22:03:41Z</dc:date>
    </item>
    <item>
      <title>Re: Setting shared key in Federated scenario</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676047#M9169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jonathan. What I have observed is that if our Shared Key is different between Portal, Hosting and the Federated sites then in Server Logs i see:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE style="background-color: #ffffff;"&gt;&lt;TBODY&gt;&lt;TR class="" style="background-color: #f1e1e1;"&gt;&lt;TD style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;DEBUG&lt;/TD&gt;&lt;TD class="" style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;&lt;DIV&gt;Exception caught while validating token. Could not decrypt token. Token may not be valid.&lt;/DIV&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After&amp;nbsp; this there&amp;nbsp;occurs multiple errors of this&amp;nbsp;form&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE style="background-color: #ffffff;"&gt;&lt;TBODY&gt;&lt;TR class=""&gt;&lt;TD style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;DEBUG&lt;/TD&gt;&lt;TD class="" style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;&lt;DIV&gt;&lt;SPAN&gt;java.io.IOException: com.esri.arcgis.discovery.admin.security.InvalidTokenException: com.esri.arcgis.discovery.admin.security.AGSSecurityException: com.esri.arcgis.discovery.admin.security.AGSSecurityException: Server machine '&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fportal" rel="nofollow" target="_blank"&gt;https://portal&lt;/A&gt;&lt;SPAN&gt;.&amp;lt;HOST&amp;gt;.com/portal/sharing/rest/community/self' returned an error. 'User does not exist or is inaccessible.'&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I set the keys to be the same the above go away.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I observe this when I acquire a (portal exchanged) token via the DotNet proxy &amp;amp; AppID and AppSecret and make calls with the token to access resources on ArcGIS Server Federated site, where our maps are. I have set up an Application as a Portal Item under the (SAML) account that owns some map services in the Mapping Federated site. When i&amp;nbsp; try to reach to that mapping service via the proxy (and the AppID)&amp;nbsp;I do get the token itself&amp;nbsp; generated OK, but it is detected as invalid:&lt;/P&gt;&lt;TABLE style="background-color: #ffffff;"&gt;&lt;TBODY&gt;&lt;TR class="" style="background-color: #f1e1e1;"&gt;&lt;TD style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;DEBUG&lt;/TD&gt;&lt;TD class="" style="font-weight: bold; font-size: 0.9em; margin: 0px 0px 3px; padding: 3px 11px 5px 0px;"&gt;&lt;DIV&gt;Exception caught while validating token. Invalid token.&lt;/DIV&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I think that also might be important is that our system uses SAML. Even if i use an Application that was created as Portal primary Site Admin this still does not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the shared keys dont need to be the same how can the Federated Site decrypt the token?&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jun 2018 07:29:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676047#M9169</guid>
      <dc:creator>SzymonPiskula1</dc:creator>
      <dc:date>2018-06-05T07:29:25Z</dc:date>
    </item>
    <item>
      <title>Re: Setting shared key in Federated scenario</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676048#M9170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;After some investigation I am thinking now that it is crucial that the shared keys are different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF the shared keys are the same i think that server performs different validation:it acts as if&amp;nbsp; token was generated by server itself, hence expects different token structure (can be seen after token decryption)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF keys are different then debug logs of the Federated Server DO&amp;nbsp; report an error, but then pass on to the section that causes this error:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; background-color: #ffffff; font-weight: bold; font-size: 14.4px;"&gt;&lt;SPAN&gt;java.io.IOException: com.esri.arcgis.discovery.admin.security.InvalidTokenException: com.esri.arcgis.discovery.admin.security.AGSSecurityException: com.esri.arcgis.discovery.admin.security.AGSSecurityException: Server machine '&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fportal" rel="nofollow" target="_blank"&gt;https://portal&lt;/A&gt;&lt;SPAN&gt;.&amp;lt;HOST&amp;gt;.com/portal/sharing/rest/community/self' returned an error. 'User does not exist or is inaccessible.'&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;This could mean that the token is passed back by server internally to portal (where original encryption has happened, with the different key). Only then Portal decides if the token is valid or not.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;For reason i cannot determine my tokens generated with AppID get rejected with&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #000000; font-weight: bold; font-size: 14.4px;"&gt;'User does not exist or is inaccessible.'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;After token (not acces_token, but the one that my proxy uses to talk to server!) decryption I can see that it contains:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;{"s":"9f22","t":"a","c":1528196962495,"d":"&amp;lt;Federated-Site-Id&amp;gt;","e":true,"g":"&amp;lt;App-ID&amp;gt;","h":"0123456789ABCDEF","l":0,"m":0}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;Federated-Site-Id IS the ArcGIS Server site that is federated with my portal and that i try to reach, so it matches overall&amp;nbsp;logic. This has no user info though, i suppose &amp;lt;AppID&amp;gt; plays its role?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;After seeing the above error in Server Logs,&amp;nbsp;I cannot see any meaningful&amp;nbsp;error in Portal logs that would indicate a crash or so.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;Am I missing some settings on the Application? I have shared it with everyone but did not help.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; color: #3d3d3d; font-weight: 400; font-size: 14.4px;"&gt;Szymon&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jun 2018 09:32:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-portal-questions/setting-shared-key-in-federated-scenario/m-p/676048#M9170</guid>
      <dc:creator>SzymonPiskula1</dc:creator>
      <dc:date>2018-06-05T09:32:41Z</dc:date>
    </item>
  </channel>
</rss>

