Anonymous Users get Credentials Prompt For Default “osssearchresults.aspx” Search Page on SharePoint Publishing Site

Posted on Updated on


Recently i came across a weird kind of issues..i have SharePoint 2013 farm with Several host header site collection.those site collections are enable to the public also, therefore all anonymous users can view those site collections.Except one site collection anonymous user can access “osssearchresults.aspx” default search page.all site collections are in the same web application.to verify the problem i created a separate web part page and inserted “Search Box” web part and “Search Result” Web part.still the same problem new page also prompting the user credentials for anonymous users.then i used fiddler to identify what are the pages that are prompting permission.actually it’s not pages. there are some “JS” files that required user credentials. reason is those files are not published properly.so what i did was i “checked in” all those “JS” files by publishing major version of those files.

*Note :- “Control_SearchBox.js and Control_SearchResult.js” are the two main files related to “osssearchresults.aspx” page..therefore make sure you publish/”check in” the major version of those two files.

below you can find two directories.you need to “check in”  all unpublished “JS” files in these two directories.using SharePoint designer navigate to these directories and publish/”check in” new version of it’s “JS” files.SharePoint use these “JS” files in “Search Box” and “Search Result” Web Parts.if these files are not publish/”check in” properly that means anonymous users cannot access these files.that’s why “Search Box” and “Search Result” web parts are prompting for credentials.

 

“Catelogs/masterpages/display template/search”

SearchBox

“Catelogs/masterpages/display template/finters “

SearchBox

if the problem still exist use “Fiddler” to identify remaining files which are still prompting for credentials .you can download Fiddler using this link.  Hope This is help to you.. 🙂

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s