How to give myself full control over a newly-created subdirectory and its contents on Windows 10 (NTFS)












1















Context: Windows 10 pro, NTFS, no networking involved, my own computer, I'm the only user.



After installing Vagrant in d:vagrant, I created a subdirectory (d:vagrantguests), then discovered that it unexpectedly has the following inherited permissions:



SYSTEM: full control (everything allowed, nothing denied)



Administrators: same as System



Users: Read & Execute, List folder contents, and Read are checked... nothing else is allowed, nothing is denied.



I want to give myself full control over that newly-created subdirectory and everything that ultimately gets created in it... WITHOUT having to always explicitly run Vagrant as administrator, and without changing the default permissions granted to members of "Users".



Put another way, what is the Windows equivalent of chmod 755 d:vagrantguests



Implied details that might or might not be significant: d:vagrant was created by Vagrant's .msi installer; d:vagrantguests was created by me in a non-elevated cmd.exe shell; my user is the one Windows presumably regards as "Administrator" (created at installation time, the only user on the system).










share|improve this question



























    1















    Context: Windows 10 pro, NTFS, no networking involved, my own computer, I'm the only user.



    After installing Vagrant in d:vagrant, I created a subdirectory (d:vagrantguests), then discovered that it unexpectedly has the following inherited permissions:



    SYSTEM: full control (everything allowed, nothing denied)



    Administrators: same as System



    Users: Read & Execute, List folder contents, and Read are checked... nothing else is allowed, nothing is denied.



    I want to give myself full control over that newly-created subdirectory and everything that ultimately gets created in it... WITHOUT having to always explicitly run Vagrant as administrator, and without changing the default permissions granted to members of "Users".



    Put another way, what is the Windows equivalent of chmod 755 d:vagrantguests



    Implied details that might or might not be significant: d:vagrant was created by Vagrant's .msi installer; d:vagrantguests was created by me in a non-elevated cmd.exe shell; my user is the one Windows presumably regards as "Administrator" (created at installation time, the only user on the system).










    share|improve this question

























      1












      1








      1








      Context: Windows 10 pro, NTFS, no networking involved, my own computer, I'm the only user.



      After installing Vagrant in d:vagrant, I created a subdirectory (d:vagrantguests), then discovered that it unexpectedly has the following inherited permissions:



      SYSTEM: full control (everything allowed, nothing denied)



      Administrators: same as System



      Users: Read & Execute, List folder contents, and Read are checked... nothing else is allowed, nothing is denied.



      I want to give myself full control over that newly-created subdirectory and everything that ultimately gets created in it... WITHOUT having to always explicitly run Vagrant as administrator, and without changing the default permissions granted to members of "Users".



      Put another way, what is the Windows equivalent of chmod 755 d:vagrantguests



      Implied details that might or might not be significant: d:vagrant was created by Vagrant's .msi installer; d:vagrantguests was created by me in a non-elevated cmd.exe shell; my user is the one Windows presumably regards as "Administrator" (created at installation time, the only user on the system).










      share|improve this question














      Context: Windows 10 pro, NTFS, no networking involved, my own computer, I'm the only user.



      After installing Vagrant in d:vagrant, I created a subdirectory (d:vagrantguests), then discovered that it unexpectedly has the following inherited permissions:



      SYSTEM: full control (everything allowed, nothing denied)



      Administrators: same as System



      Users: Read & Execute, List folder contents, and Read are checked... nothing else is allowed, nothing is denied.



      I want to give myself full control over that newly-created subdirectory and everything that ultimately gets created in it... WITHOUT having to always explicitly run Vagrant as administrator, and without changing the default permissions granted to members of "Users".



      Put another way, what is the Windows equivalent of chmod 755 d:vagrantguests



      Implied details that might or might not be significant: d:vagrant was created by Vagrant's .msi installer; d:vagrantguests was created by me in a non-elevated cmd.exe shell; my user is the one Windows presumably regards as "Administrator" (created at installation time, the only user on the system).







      windows permissions ntfs






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Jan 24 at 19:35









      Bitbang3rBitbang3r

      1911213




      1911213






















          1 Answer
          1






          active

          oldest

          votes


















          0














          Your user created at install time is part of Administrators goup - it is not the Administrator.



          If you want to have access to a directory owned by another without security prompts then you need to take ownership and give yourself full authority. You can then change ownership back it you want.



          Take ownership with takeown :



          takeown /f "d:vagrantguests" /r



          Then grant the authority you want with icacls,



          Reset to default to get rid of any previous changes (/t means recurse)



          icacls "d:vagrantguests" /reset /t


          Give yourself full authority :



          icacls "d:vagrantguests" /grant "%USERDOMAIN%%USERNAME%":(F) /t


          Make sure inheritance is enabled :



          icacls "d:vagrantguests" /inheritance:e /t


          Now perhaps you want to remove some group authority (but perhaps not)



          icacls "d:vagrantguests" /remove:g "BUILTINAdministrators" /t
          icacls "d:vagrantguests" /remove:g "NT AUTHORITYSYSTEM" /t
          icacls "d:vagrantguests" /remove:g "NT AUTHORITYAuthenticated Users" /t


          Then check :



          icacls "d:vagrantguests" /t


          Then if you want change ownership back



          icacls "d:vagrantguests" /setowner "BUILTINAdministrators" /t





          share|improve this answer
























            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "3"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1398048%2fhow-to-give-myself-full-control-over-a-newly-created-subdirectory-and-its-conten%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Your user created at install time is part of Administrators goup - it is not the Administrator.



            If you want to have access to a directory owned by another without security prompts then you need to take ownership and give yourself full authority. You can then change ownership back it you want.



            Take ownership with takeown :



            takeown /f "d:vagrantguests" /r



            Then grant the authority you want with icacls,



            Reset to default to get rid of any previous changes (/t means recurse)



            icacls "d:vagrantguests" /reset /t


            Give yourself full authority :



            icacls "d:vagrantguests" /grant "%USERDOMAIN%%USERNAME%":(F) /t


            Make sure inheritance is enabled :



            icacls "d:vagrantguests" /inheritance:e /t


            Now perhaps you want to remove some group authority (but perhaps not)



            icacls "d:vagrantguests" /remove:g "BUILTINAdministrators" /t
            icacls "d:vagrantguests" /remove:g "NT AUTHORITYSYSTEM" /t
            icacls "d:vagrantguests" /remove:g "NT AUTHORITYAuthenticated Users" /t


            Then check :



            icacls "d:vagrantguests" /t


            Then if you want change ownership back



            icacls "d:vagrantguests" /setowner "BUILTINAdministrators" /t





            share|improve this answer




























              0














              Your user created at install time is part of Administrators goup - it is not the Administrator.



              If you want to have access to a directory owned by another without security prompts then you need to take ownership and give yourself full authority. You can then change ownership back it you want.



              Take ownership with takeown :



              takeown /f "d:vagrantguests" /r



              Then grant the authority you want with icacls,



              Reset to default to get rid of any previous changes (/t means recurse)



              icacls "d:vagrantguests" /reset /t


              Give yourself full authority :



              icacls "d:vagrantguests" /grant "%USERDOMAIN%%USERNAME%":(F) /t


              Make sure inheritance is enabled :



              icacls "d:vagrantguests" /inheritance:e /t


              Now perhaps you want to remove some group authority (but perhaps not)



              icacls "d:vagrantguests" /remove:g "BUILTINAdministrators" /t
              icacls "d:vagrantguests" /remove:g "NT AUTHORITYSYSTEM" /t
              icacls "d:vagrantguests" /remove:g "NT AUTHORITYAuthenticated Users" /t


              Then check :



              icacls "d:vagrantguests" /t


              Then if you want change ownership back



              icacls "d:vagrantguests" /setowner "BUILTINAdministrators" /t





              share|improve this answer


























                0












                0








                0







                Your user created at install time is part of Administrators goup - it is not the Administrator.



                If you want to have access to a directory owned by another without security prompts then you need to take ownership and give yourself full authority. You can then change ownership back it you want.



                Take ownership with takeown :



                takeown /f "d:vagrantguests" /r



                Then grant the authority you want with icacls,



                Reset to default to get rid of any previous changes (/t means recurse)



                icacls "d:vagrantguests" /reset /t


                Give yourself full authority :



                icacls "d:vagrantguests" /grant "%USERDOMAIN%%USERNAME%":(F) /t


                Make sure inheritance is enabled :



                icacls "d:vagrantguests" /inheritance:e /t


                Now perhaps you want to remove some group authority (but perhaps not)



                icacls "d:vagrantguests" /remove:g "BUILTINAdministrators" /t
                icacls "d:vagrantguests" /remove:g "NT AUTHORITYSYSTEM" /t
                icacls "d:vagrantguests" /remove:g "NT AUTHORITYAuthenticated Users" /t


                Then check :



                icacls "d:vagrantguests" /t


                Then if you want change ownership back



                icacls "d:vagrantguests" /setowner "BUILTINAdministrators" /t





                share|improve this answer













                Your user created at install time is part of Administrators goup - it is not the Administrator.



                If you want to have access to a directory owned by another without security prompts then you need to take ownership and give yourself full authority. You can then change ownership back it you want.



                Take ownership with takeown :



                takeown /f "d:vagrantguests" /r



                Then grant the authority you want with icacls,



                Reset to default to get rid of any previous changes (/t means recurse)



                icacls "d:vagrantguests" /reset /t


                Give yourself full authority :



                icacls "d:vagrantguests" /grant "%USERDOMAIN%%USERNAME%":(F) /t


                Make sure inheritance is enabled :



                icacls "d:vagrantguests" /inheritance:e /t


                Now perhaps you want to remove some group authority (but perhaps not)



                icacls "d:vagrantguests" /remove:g "BUILTINAdministrators" /t
                icacls "d:vagrantguests" /remove:g "NT AUTHORITYSYSTEM" /t
                icacls "d:vagrantguests" /remove:g "NT AUTHORITYAuthenticated Users" /t


                Then check :



                icacls "d:vagrantguests" /t


                Then if you want change ownership back



                icacls "d:vagrantguests" /setowner "BUILTINAdministrators" /t






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Jan 24 at 21:36









                lx07lx07

                646411




                646411






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Super User!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1398048%2fhow-to-give-myself-full-control-over-a-newly-created-subdirectory-and-its-conten%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Paul Cézanne

                    UIScrollView CustomStickyHeader Resize height generates problems when scroll is too fast

                    Angular material date-picker (MatDatepicker) auto completes the date on focus out