1

We are using ADFS to authenticate SharePoint 2016 website. Once authenticated 'authToken' stay part of the query string as follow. This is only happening first authenticated page. If I click on another page the 'authToken' query string disappeared.

https://www.example.com/page.aspx?authToken=ADFSToken

If I used that URL in a different browser or someone else computer, user will be logged in directly.

Does anyone know how to remove 'authToken' from authenticated SharePoint page?

  • Did you try to use IIS URL rewriting to remove the query string? – user3186258 Nov 11 '16 at 9:55
0

You could use IIS URL rewriting for hiding the parameter.

e.g.

  <rule name="Remove paging parameters" stopProcessing="true">
  <match url="(.*)?$" />
  <conditions trackAllCaptures="true">
    <add input="{QUERY_STRING}" pattern="authtoken=(*.)" />
  </conditions>
  <action type="Redirect" url="{R:1}" appendQueryString="false" />

IIS Rewrite would remove authtoken and redirect to the original requested host.

Based on the idea of https://stackoverflow.com/questions/22234604/iis-rewrite-to-remove-certain-querystring-parameters-and-redirect-to-the-origina

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.