<?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: By pass Portal web map authentication in JavaScript 3.23 in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/by-pass-portal-web-map-authentication-in/m-p/363004#M33645</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Kishore, since you are using JS 3.23 the IdentityManager -registerToken method should have the server parameter as Portal URL only not a rest end url. Your syntax for JS 4.x&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #f6f6f6;"&gt;var tokenProp = { expires: parseInt(globalPSObj.expires),&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 11.5pt; color: #3d3d3d; background: yellow;"&gt;server: Configs.portalurl&lt;/SPAN&gt;&lt;SPAN style="background-color: #f6f6f6;"&gt;, ssl: globalPSObj.ssl, token: globalPSObj.Token, userId: globalPSObj.userId };&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 03 Apr 2018 16:32:11 GMT</pubDate>
    <dc:creator>BalajiVeera</dc:creator>
    <dc:date>2018-04-03T16:32:11Z</dc:date>
    <item>
      <title>By pass Portal web map authentication in JavaScript 3.23</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/by-pass-portal-web-map-authentication-in/m-p/363003#M33644</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;Goal:&lt;/STRONG&gt;&amp;nbsp;Develop a web application using ArcGIS JavaScript API that has a single login experience for the end user and that enables them to edit feature layers hosted on Portal for ArcGIS.&lt;/P&gt;&lt;P style="background-color: rgba(248, 248, 248, 0.6);"&gt;&lt;STRONG&gt;Setup:&lt;/STRONG&gt;&amp;nbsp;We are using OpenText Coordys development environment. The GIS HTML Javascript application is in X-Form (Iframe) of the Coordys sytem. The web map consumed by the application from Portal for ArcGIS 10.5.1 and ArcGIS Server 10.5.1&lt;/P&gt;&lt;P&gt;The &lt;STRONG&gt;ArcGIS Enterprise environment is 10.5.1&lt;/STRONG&gt; (ArcGIS Server is federated and hosted) and exposed to internet using reverse proxy from organization. We are using &lt;STRONG&gt;ArcGIS JavaScript 3.23&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The web map is shared only with a group and a technical user has the access to this group.&lt;/P&gt;&lt;P&gt;Whoever access the coordys application should be able to view the GIS map without asking authentication. The technical user is configured in Coordys to &lt;STRONG&gt;&lt;EM&gt;generate the token directly from portal and pas the token details to GIS map viewer&lt;/EM&gt;&lt;/STRONG&gt; with a service.&lt;/P&gt;&lt;P&gt;We are able to get the token before creating the map and utilized in Identity manager to register. However, while creating the map the error returned in JS and map is not creating.&lt;/P&gt;&lt;P&gt;The code is:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;require([&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/map",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/toolbars/navigation",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/layers/FeatureLayer",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/PopupTemplate",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/InfoTemplate",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/geometry/webMercatorUtils",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/layers/FeatureLayer",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/layers/LayerInfo",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; "esri/urlUtils",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/arcgis/utils",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/layers/Field",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/config",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/tasks/GeometryService",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/OverviewMap",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/Legend",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/LayerList",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/Scalebar",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/HomeButton",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/Search",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/BasemapGallery",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/Basemap",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/Measurement",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/dijit/LocateButton",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/geometry/Point",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; "esri/SpatialReference",&lt;/P&gt;&lt;P&gt;"esri/IdentityManager"&lt;/P&gt;&lt;P&gt;],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; function (Map, Navigation, FeatureLayer, PopupTemplate, InfoTemplate, webMercatorUtils, FeatureLayer, LayerInfo, urlUtils, arcgisUtils, Field, esriConfig, GeometryService, OverviewMap, Legend, LayerList, Scalebar, HomeButton, Search, BasemapGallery, Basemap, Measurement, LocateButton, Point, SpatialReference, esriId&lt;/P&gt;&lt;P&gt;) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parser.parse();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var tokenProp = { expires: parseInt(globalPSObj.expires), server: Configs.portalurl + "/sharing/rest", ssl: globalPSObj.ssl, token: globalPSObj.Token, userId: globalPSObj.userId };&lt;/P&gt;&lt;P&gt;esriId. registerToken(tokenProp);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcgisUtils.arcgisUrl = Configs.portalurl + "/sharing/content/items";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcgisUtils.createMap(Configs.webmapid, "map").then(function (response) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var map = response.map;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var ProjectRequests, Estimates, ProposedProjects, PR_Point;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;});&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Please advice the approach I am following is correct or what is the best way to implement this to by pass the user login.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Apr 2018 11:40:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/by-pass-portal-web-map-authentication-in/m-p/363003#M33644</guid>
      <dc:creator>Chenna_KishoreMallemala</dc:creator>
      <dc:date>2018-04-03T11:40:47Z</dc:date>
    </item>
    <item>
      <title>Re: By pass Portal web map authentication in JavaScript 3.23</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/by-pass-portal-web-map-authentication-in/m-p/363004#M33645</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Kishore, since you are using JS 3.23 the IdentityManager -registerToken method should have the server parameter as Portal URL only not a rest end url. Your syntax for JS 4.x&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #f6f6f6;"&gt;var tokenProp = { expires: parseInt(globalPSObj.expires),&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 11.5pt; color: #3d3d3d; background: yellow;"&gt;server: Configs.portalurl&lt;/SPAN&gt;&lt;SPAN style="background-color: #f6f6f6;"&gt;, ssl: globalPSObj.ssl, token: globalPSObj.Token, userId: globalPSObj.userId };&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Apr 2018 16:32:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/by-pass-portal-web-map-authentication-in/m-p/363004#M33645</guid>
      <dc:creator>BalajiVeera</dc:creator>
      <dc:date>2018-04-03T16:32:11Z</dc:date>
    </item>
  </channel>
</rss>

