Custom permission using WebDAVRSS

3 replies

Last post Jan 13, 2020 09:08 AM by ChrisVH1982

  • Custom permission using WebDAV

    Jan 06, 2020 10:49 AM|ChrisVH1982|LINK

    Dear community,

    I've been trying setting up custom permission on different directories for different users using Server 2019 and IIS10.

    I created a website for WebDAV, added virtual directories and then enabled WebDAV. Authoring rules were set at top level (Website). This is working fine for myself because I do have full permission to all virtual directories. However, I would like to grant individuals permission to specific directories and these should not have R/W permission to any other directory.

    It looks like I can grant a user permission to a virtual directory but that user is then not able/allowed to authenticate.

    In the below example, permission in RED is desired but won't work:

    • - WebDavRoot (Authoring: User 1 R/W/S)
    • -- VirtualDirectory1 (Authoring: User 1 inherited)
    • -- VirtualDirectory2 (Authoring: User 1 inherited | User 2 R/W/S)
    • -- VirtualDirectory3 (Authoring: User 1 inherited | User 3 R/W/S)
  • Re: Custom permission using WebDAV

    Jan 07, 2020 03:30 AM|Yuk Ding|LINK

    Hi ChrisVH1982,

    DId you set the authorize rule like this in applicationhost.config?

     <location path="Mysite">
            <system.webServer>
                <webdav>
                    <authoringRules>
                        <add users="user1" path="*" access="Read, Write, Source" />
                    </authoringRules>
                </webdav>
            </system.webServer>
        </location>

       <location path="MySite/VirtualDirectory2">
            <system.webServer>
                <webdav>
                    <authoringRules>
                        <add users="user2" path="*" access="Read, Write, Source" />
                    </authoringRules>
                </webdav>
            </system.webServer>
        </location>

    <location path="Mysite/VirtualDirectory3">
            <system.webServer>
                <webdav>
                    <authoringRules>
                        <add users="user2" path="*" access="Read, Write, Source" />
                    </authoringRules>
                </webdav>
            </system.webServer>
        </location>

    Best Regards,

    Jokies Ding

    Yuk Ding

    MSDN Community Support
    Please remember to "Mark as Answer" the responses that resolved your issue.
  • Re: Custom permission using WebDAV

    Jan 07, 2020 02:41 PM|ChrisVH1982|LINK

    Hi Yuk,

    It looks similar. I set these permission using MMC. In your example I would expect USER1 to see everything (Basically 2 directories) and USER2 just those two virtual directories which the users is granted permission to.

    I copied my configuration and replaced my usernames just. It looks similar. However, USER1 can see everything and USER2 cannot login. I am re-prompted for credentials when trying login as USER2.

    <location path="WebDAV">
    <system.webServer>
    <webdav>
    <authoringRules>
    <add roles="DOMAIN\GROUP1" path="*" access="Read, Write, Source" />
    <add users="DOMAIN\USER1" path="*" access="Read, Write, Source" />
    </authoringRules>
    <authoring enabled="true" />
    </webdav>
    <security>
    <requestFiltering>
    <fileExtensions applyToWebDAV="false" />
    <verbs applyToWebDAV="false" />
    <hiddenSegments applyToWebDAV="false" />
    </requestFiltering>
    <authentication>
    <anonymousAuthentication enabled="false" />
    <windowsAuthentication enabled="true" />
    <digestAuthentication enabled="false" />
    <basicAuthentication enabled="false" />
    </authentication>
    </security>
    </system.webServer>
    </location>
    <location path="WebDAV/Test_Local">
    <system.webServer>
    <webdav>
    <authoringRules>
    </authoringRules>
    </webdav>
    </system.webServer>
    </location>
    <location path="WebDAV/Mediathek">
    <system.webServer>
    <webdav>
    <authoringRules>
    <add users="DOMAIN\USER2" path="*" access="Read, Write, Source" />
    </authoringRules>
    </webdav>
    </system.webServer>
    </location>

  • Re: Custom permission using WebDAV

    Jan 13, 2020 09:08 AM|ChrisVH1982|LINK

    Nobody has any further ideas?