Services Partners Company
Knowledge Base


Article

Getting unauthorized exception when accessing the Document & Files with the user that is having permission to view the library

« Go Back

Information

 
EnvironmentProduct: Sitefinity
Version: 5.x, 6.x, 7.x, 8.x, 9.x, 10.x
OS: All supported OS versions
Database: All supported Microsoft SQL Server versions
Question/Problem Description
Accessing Document & Files throwing the unauthorized exception "You are not authorized to 'View document library' ('DocumentLibrary')" though the user has permissions to view one/more libraries.
Steps to Reproduce1. Set the Global Permissions for the Document Libraries to the following:

View document library (?) - Administrators

2. On a specific document library (Test Library), break the permissions inheritance and set a specific User/Role (non-admin, only BackendUser) to the View document library (?).

3. Access the Content -> Document & Files with the user (non-admin, only BackendUser) that is having permissions to view the document library throwing the following error:

You are not authorized to 'View document library' ('DocumentLibrary').
Clarifying Information
Error Message
Defect/Enhancement NumberBug 219362
Cause
For more information about Bug 219362, see https://feedback.telerik.com/Project/153/Feedback/Details/219362
Resolution
None at this time. Until the fix is available, use the workaround below.
Workaround
An example of a scenario: The project is having User A, and it has a DocsForUserA library for Documents & Files. The User A should be view only the DocsForUserA library.

1. Set the Global Permissions for the Document Libraries to the following:

View document library (?) - all Backend users

2. For each library except the DocsForUserA, set the Permissions for other libraries after clicking on Break inheritance and then Change button for View document library (?):

View document library (?) - Administrators only

or

View document library (?) - User that is entitled to access library accordingly (e.g. User B for DocsForUserB library)

3. For the library DocsForUserA, Set the following permissions:

View document (?) - Everyone
Modify library and manage documents (?) - User A
Change document owner (?) - User A
Change document permissions (?) - Administrators only
View this document library (?) - User A
Delete this document library (?) - User A
Change this document library's owner (?) - User A
Change this document library's permissions (?) - Administrators only

4. Enable filterQueriesByViewPermissions for the libraries provider according to the following article 000074827: Filter content items by permission

5. Restart the project

With the above implementation, the User A will be able to view and edit only the DocsForUserA library and its documentations.
Notes
The amount of votes an item in the feedback portal has is taken into consideration when determining its priority. Vote for the item using the Like and Dislike buttons in the right-hand side menu to affect the priority it has. By casting a vote the voter will also be subscribed to a mailing list to receive notifications about changes of the item such as when it is fixed or implemented.
Attachment 
Last Modified Date6/20/2017 2:55 AM
Disclaimer

The origins of the information on this site may be internal or external to Progress Software Corporation (“Progress”). Progress Software Corporation makes all reasonable efforts to verify this information. However, the information provided is for your information only. Progress Software Corporation makes no explicit or implied claims to the validity of this information.

Any sample code provided on this site is not supported under any Progress support program or service. The sample code is provided on an "AS IS" basis. Progress makes no warranties, express or implied, and disclaims all implied warranties including, without limitation, the implied warranties of merchantability or of fitness for a particular purpose. The entire risk arising out of the use or performance of the sample code is borne by the user. In no event shall Progress, its employees, or anyone else involved in the creation, production, or delivery of the code be liable for any damages whatsoever (including, without limitation, damages for loss of business profits, business interruption, loss of business information, or other pecuniary loss) arising out of the use of or inability to use the sample code, even if Progress has been advised of the possibility of such damages.



Feedback
 
Was this article helpful?

   

Your feedback is appreciated.

Please tell us how we can make this article more useful.



Characters Remaining: 255