Sorry, you don’t have access to this page creating documents in SharePoint

We encountered the issue where people were receiving access denied errors when uploading documents while having contribute permissions for a specific document library. Create a document worked most of the time but access was denied for some tries with the error “Sorry, you don’t have access to this page”

The user clicked on “New document” and was presented with the “Create a new document” pop-up.

The below error occurred after click on OK

The below was available in the ULS Log.

Access Denied. Exception: Access denied., StackTrace:  at Microsoft.SharePoint.Library.SPRequestInternalClass.GetFileAndFolderProperties(String bstrUrl, String bstrStartUrl, ListDocsFlags ListDocsFlags, Boolean bThrowException, Int32& phrStatus, Object& pvarFiles, Object& pvarDirs, UInt32& pdwNumberOfFiles, UInt32& pdwNumberOfDirs)    at Microsoft.SharePoint.Library.SPRequest.GetFileAndFolderProperties(String bstrUrl, String bstrStartUrl, ListDocsFlags ListDocsFlags, Boolean bThrowException, Int32& phrStatus, Object& pvarFiles, Object& pvarDirs, UInt32& pdwNumberOfFiles, UInt32& pdwNumberOfDirs).

Access Denied for <SiteName>/_layouts/15/CreateNewDocument.aspx?id=https://xxxx etc etc

Solution

The user had the permissions to upload documents and create documents given by the members group. This library was setup that users were not able to view other peoples documents. After troubleshooting we found that the document name already existed in the library but the user doesn’t have permissions to view this document metadata and receives the access denied error. The error changes to “Sorry, something went wrong” should the user be able to view the document with an better message saying “A file with the name <DocName> exists.”

Sorry, something went wrong while browsing to the Central Administration: Parameter name: encodedValue

We encountered the “Sorry, something went wrong” while browsing to the Central Administration of a SharePoint 2013 environment. We analyzed the logs using the ULSViewer and found the following errors referenced by the correlation ID.

Application error when access /, Error=Exception of type ‘System.ArgumentException’ was thrown. Parameter name: encodedValue at Microsoft.SharePoint.Administration.Claims.SPClaimEncodingManager.DecodeClaimFromFormsSuffix(String encodedValue)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(IClaimsIdentity claimsIdentity, String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.ApplicationRuntime.SPHeaderManager.AddIsapiHeaders(HttpContext context, String encodedUrl, NameValueCollection headers)  at Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.PreRequestExecuteAppHandler(Object oSender, EventArgs ea)  at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()  at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

System.ArgumentException: Exception of type ‘System.ArgumentException’ was thrown. Parameter name: encodedValue  at Microsoft.SharePoint.Administration.Claims.SPClaimEncodingManager.DecodeClaimFromFormsSuffix(String encodedValue)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(IClaimsIdentity claimsIdentity, String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.ApplicationRuntime.SPHeaderManager.AddIsapiHeaders(HttpContext context, String encodedUrl, NameValueCollection headers)  at Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.PreRequestExecuteAppHandler(Object oSender, EventArgs ea)  at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()  at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

Getting Error Message for Exception System.ArgumentException: Exception of type ‘System.ArgumentException’ was thrown. Parameter name: encodedValue  at Microsoft.SharePoint.Administration.Claims.SPClaimEncodingManager.DecodeClaimFromFormsSuffix(String encodedValue)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(IClaimsIdentity claimsIdentity, String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.Administration.Claims.SPClaimProviderManager.GetProviderUserKey(String encodedIdentityClaimSuffix)  at Microsoft.SharePoint.ApplicationRuntime.SPHeaderManager.AddIsapiHeaders(HttpContext context, String encodedUrl, NameValueCollection headers)

There are a few blogs regarding this issue on the web which mentions it occurs due to a misconfiguration in FBA (Forms Based Authentication). We do not have FBA enabled for our Central Administration but the error indicates that’s something is wrong with the authentication as it specifies the SPClaimEncodingManager. There are a few possible solutions to fix this issue where number 3 has resolved it for us.

  1. First try to resolve this issue by restarting IIS or the server to verify it doesn’t have something to do with the servers memory or cache as “resetting” the server may sometimes solve the issue.
  2. It may have something to do with the IIS authentication settings for the Central Administration where it should look like the below
  3. In our case it was the way the Central Administration was setup at the customer. The SharePoint Central Administration icon navigates us to http://admin.<domain>.local but the link doesn’t add the port behind the URL where it was configured to 2720 in the Internet Information Services. We were able to connect to http://localhost:2720 and also when we used http://admin.<domain>.local:2720.You can change the Central Administration URL of the icon to match the configured IIS binding by editing the registry. Follow the following steps to modify the correct key:
    – First backup the registry just to be sure
    – Navigate to HKEY_LOCAL_MACHINE -> Software > Microsoft -> Shared Tools -> Web Server Extensions -> 14.0, 15.0 or 16.0 depending on your version -> WSS
    – Change the “CentralAdministrationURL” value to the correct URL

    The icon now redirects to the correct URL: