How to limit a folder's access?

ren 0 Reputation points
2024-04-08T20:47:00.27+00:00

Using icacls i want to make a folder(D:\AS) not be able to access anything outside it like if i have cmd open on the path of the folder i cant cd out of it or i cant list dir of d or i cant make a file outside it or a script cant do anything thats outside it

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,193 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Marcin Policht 10,845 Reputation points MVP
    2024-04-08T23:56:32.1033333+00:00

    You might want to reconsider your requirements - as stated, they don't make sense. A "folder" is not an active entity - it never attempts to access anything outside of it on its own.


    If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.

    hth

    Marcin


  2. Daisy Zhou 18,706 Reputation points Microsoft Vendor
    2024-04-09T07:02:17.51+00:00

    Hello ren,

    Thank you for posting in Q&A forum.

    You can try to set the permission on this folder to block any user or any group the specific permissions.

    Right click this folder and select Properties.
    Security tab and Advanced permission and add the user or group under "Permissions" tab.
    User's image

    Select "Type".
    Select "Applies to".
    Check the basic permissions and advanced permissions you want.
    User's image

    At last, you can check if the requirements you want is met.

    I hope the information above is helpful.

    If you have any questions or concerns, please feel free to let us know.

    Best Regards,

    Daisy Zhou

    ============================================

    If the Answer is helpful, please click "Accept Answer" and upvote it.

    0 comments No comments