Azure / azure-quickstart-templates

Azure Quickstart Templates
https://aka.ms/azqst
MIT License
14.06k stars 16.13k forks source link

Error "The security token service endpoint not found" in appredirect.aspx using the default addin project provided by VS2022 templates #13646

Open frompedro opened 11 months ago

frompedro commented 11 months ago

SharePoint 2019 adfs

Error "The security token service endpoint not found" on appredirect.aspx when deploying the PHA project provided by Visual Studio 2022

V2022 Version

VS2022 image

Repro steps

  1. The SharePoint 2019 Adfs successfully installed on Azure
  2. Open VS2022 > From the templates > select "SharePoint Addins" > and follow the steps as described in the microsoft documentation.
  3. GitHub Repo for the addin
  4. On the SharePoint Farm > Create new Site collection > and register the addin on appregnew.aspx page
  5. package and copy the Web Code into the IIS
  6. Check web.config for the appropriate ClientId and ClientSecret image
  7. Install "testphaappnow" add in on the site collection 9.When i start the application with the link: "http://spsites/sites/chs/_layouts/15/appredirect.aspx?instance_id={1487ACF3-5D9D-46EF-8B9B-8156E6D793AD}" > it redirects successfully to https://sp:20443/?SPHostUrl=http%3A%2F%2Fspsites%2Fsites%2Fchs&SPLanguage=en%2DUS&SPClientTag=0&SPProductNumber=16%2E0%2E10337%2E12109&SPAppWebUrl=http%3A%2F%2Faddin%2D8cb62f1868d330%2EsharepointApps%2Elocal%2Fsites%2Fchs%2Ftestphaappnow

Download the Logs.csv

Yvand commented 8 months ago

@frompedro sorry for the late reply. I see in your web.config that you set a client secret, which means that you created a low-trust add-in.

To run a low-trust add-in, SharePoint requires a trust between SharePoint and ACS.

The ARM template works as-is with high-trust add-ins, but they do not support using a client secret.