Why run a service as a system user?What are the different ways to set file permissions etc on gnu/linuxChanging user and group ID system wide (including file system attributes)?Is it possible to log in in a host with an user created for programs like apache or postgreSQL?OpenSSH, chroot user: Root needs to own the user directory, is there any consequence?Proper location to install servicesWhat mechanism prevents any user from accessing any other user's files via root?Why does transmission adds a new user to the system?Why isn't the var directory user-specific?Cron shell ignores runuser command - why?Why can't regular users create and manage user groups?Reading home folder of old computer in a new computer

How can I make sure my players' decisions have consequences?

Considerations when providing money to one child now, and the other later?

Why is DC so, so, so Democratic?

How can Kazakhstan perform MITM attacks on all HTTPS traffic?

Area of parallelogram = Area of square. Shear transform

Are glider winch launches rarer in the USA than in the rest of the world? Why?

USA: Can a witness take the 5th to avoid perjury?

Why must API keys be kept private?

how to add 1 milliseconds on a datetime string?

Why did modems have speakers?

In a script how can I signal who's winning the argument?

Is it possible to eat quietly in Minecraft?

Is the statement "I/we am/are pressing charges" incorrect?

My current job follows "worst practices". How can I talk about my experience in an interview without giving off red flags?

What was the rationale behind 36 bit computer architectures?

Film where a boy turns into a princess

Why does the salt in the oceans not sink to the bottom?

Why is chess failing to attract big name sponsors?

Can I pay with HKD in Macau or Shenzhen?

Who has jurisdiction for a crime committed in an embassy?

Idioms: Should it be " the internet is a seemingly infinite well of information" or "the internet is a seemingly infinite wealth of information"

How can I tell if there was a power cut when I was out?

How to repair basic cable/wire issue for household appliances

Sextortion with actual password not found in leaks



Why run a service as a system user?


What are the different ways to set file permissions etc on gnu/linuxChanging user and group ID system wide (including file system attributes)?Is it possible to log in in a host with an user created for programs like apache or postgreSQL?OpenSSH, chroot user: Root needs to own the user directory, is there any consequence?Proper location to install servicesWhat mechanism prevents any user from accessing any other user's files via root?Why does transmission adds a new user to the system?Why isn't the var directory user-specific?Cron shell ignores runuser command - why?Why can't regular users create and manage user groups?Reading home folder of old computer in a new computer






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








18















I have a general question about the UNIX world.



I am currently running Ubuntu at home and installed Transmission on a device and it runs as and saves files as the transmission-debian user. I am wondering if it makes sense for me to change this to my own user, so it is easier to interact with files and I don't need to sudo? Why would this be a bad idea to do?










share|improve this question






























    18















    I have a general question about the UNIX world.



    I am currently running Ubuntu at home and installed Transmission on a device and it runs as and saves files as the transmission-debian user. I am wondering if it makes sense for me to change this to my own user, so it is easier to interact with files and I don't need to sudo? Why would this be a bad idea to do?










    share|improve this question


























      18












      18








      18


      3






      I have a general question about the UNIX world.



      I am currently running Ubuntu at home and installed Transmission on a device and it runs as and saves files as the transmission-debian user. I am wondering if it makes sense for me to change this to my own user, so it is easier to interact with files and I don't need to sudo? Why would this be a bad idea to do?










      share|improve this question
















      I have a general question about the UNIX world.



      I am currently running Ubuntu at home and installed Transmission on a device and it runs as and saves files as the transmission-debian user. I am wondering if it makes sense for me to change this to my own user, so it is easier to interact with files and I don't need to sudo? Why would this be a bad idea to do?







      ubuntu files users transmission






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Jul 15 at 22:22









      Peter Mortensen

      9486 silver badges9 bronze badges




      9486 silver badges9 bronze badges










      asked Jul 14 at 22:00









      ScipioAfricanusScipioAfricanus

      966 bronze badges




      966 bronze badges




















          1 Answer
          1






          active

          oldest

          votes


















          39














          The main reason for the recommendation of running Transmission as its own dedicated system user rather than your user is that, if the software has a vulnerability that allows exploits that will expose files outside of its configured directory, then it will not end up exposing the possibly sensitive files from your home directory, since Linux itself will prevent that kind of access through the basic permissions.



          In order to make it easier to manage the files in Transmission's directory with your regular user, you should consider adding your user to the debian-transmission group, which is the group that owns the files in the Transmission directory, and has (or at least should have) read/write access to that directory and the files within it.



          The Ubuntu howto suggests this command (slightly adapted to get your user from an environment variable):



          sudo usermod -a -G debian-transmission "$USER"


          (Remember to log out and log in again after running usermod, as it will not affect the groups of any existing process.)



          Hopefully this will make it easier for you to manage the files downloaded with Transmission, while still keeping it running under its own dedicated system user, for better security.






          share|improve this answer




















          • 1





            I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

            – Alko
            Jul 15 at 9:04






          • 3





            You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

            – ctrl-alt-delor
            Jul 15 at 9:29






          • 1





            Hey, thanks a lot.

            – ScipioAfricanus
            Jul 16 at 16:29













          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          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: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          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%2funix.stackexchange.com%2fquestions%2f530154%2fwhy-run-a-service-as-a-system-user%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









          39














          The main reason for the recommendation of running Transmission as its own dedicated system user rather than your user is that, if the software has a vulnerability that allows exploits that will expose files outside of its configured directory, then it will not end up exposing the possibly sensitive files from your home directory, since Linux itself will prevent that kind of access through the basic permissions.



          In order to make it easier to manage the files in Transmission's directory with your regular user, you should consider adding your user to the debian-transmission group, which is the group that owns the files in the Transmission directory, and has (or at least should have) read/write access to that directory and the files within it.



          The Ubuntu howto suggests this command (slightly adapted to get your user from an environment variable):



          sudo usermod -a -G debian-transmission "$USER"


          (Remember to log out and log in again after running usermod, as it will not affect the groups of any existing process.)



          Hopefully this will make it easier for you to manage the files downloaded with Transmission, while still keeping it running under its own dedicated system user, for better security.






          share|improve this answer




















          • 1





            I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

            – Alko
            Jul 15 at 9:04






          • 3





            You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

            – ctrl-alt-delor
            Jul 15 at 9:29






          • 1





            Hey, thanks a lot.

            – ScipioAfricanus
            Jul 16 at 16:29















          39














          The main reason for the recommendation of running Transmission as its own dedicated system user rather than your user is that, if the software has a vulnerability that allows exploits that will expose files outside of its configured directory, then it will not end up exposing the possibly sensitive files from your home directory, since Linux itself will prevent that kind of access through the basic permissions.



          In order to make it easier to manage the files in Transmission's directory with your regular user, you should consider adding your user to the debian-transmission group, which is the group that owns the files in the Transmission directory, and has (or at least should have) read/write access to that directory and the files within it.



          The Ubuntu howto suggests this command (slightly adapted to get your user from an environment variable):



          sudo usermod -a -G debian-transmission "$USER"


          (Remember to log out and log in again after running usermod, as it will not affect the groups of any existing process.)



          Hopefully this will make it easier for you to manage the files downloaded with Transmission, while still keeping it running under its own dedicated system user, for better security.






          share|improve this answer




















          • 1





            I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

            – Alko
            Jul 15 at 9:04






          • 3





            You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

            – ctrl-alt-delor
            Jul 15 at 9:29






          • 1





            Hey, thanks a lot.

            – ScipioAfricanus
            Jul 16 at 16:29













          39












          39








          39







          The main reason for the recommendation of running Transmission as its own dedicated system user rather than your user is that, if the software has a vulnerability that allows exploits that will expose files outside of its configured directory, then it will not end up exposing the possibly sensitive files from your home directory, since Linux itself will prevent that kind of access through the basic permissions.



          In order to make it easier to manage the files in Transmission's directory with your regular user, you should consider adding your user to the debian-transmission group, which is the group that owns the files in the Transmission directory, and has (or at least should have) read/write access to that directory and the files within it.



          The Ubuntu howto suggests this command (slightly adapted to get your user from an environment variable):



          sudo usermod -a -G debian-transmission "$USER"


          (Remember to log out and log in again after running usermod, as it will not affect the groups of any existing process.)



          Hopefully this will make it easier for you to manage the files downloaded with Transmission, while still keeping it running under its own dedicated system user, for better security.






          share|improve this answer















          The main reason for the recommendation of running Transmission as its own dedicated system user rather than your user is that, if the software has a vulnerability that allows exploits that will expose files outside of its configured directory, then it will not end up exposing the possibly sensitive files from your home directory, since Linux itself will prevent that kind of access through the basic permissions.



          In order to make it easier to manage the files in Transmission's directory with your regular user, you should consider adding your user to the debian-transmission group, which is the group that owns the files in the Transmission directory, and has (or at least should have) read/write access to that directory and the files within it.



          The Ubuntu howto suggests this command (slightly adapted to get your user from an environment variable):



          sudo usermod -a -G debian-transmission "$USER"


          (Remember to log out and log in again after running usermod, as it will not affect the groups of any existing process.)



          Hopefully this will make it easier for you to manage the files downloaded with Transmission, while still keeping it running under its own dedicated system user, for better security.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Jul 15 at 20:42









          ilkkachu

          66.1k10 gold badges110 silver badges192 bronze badges




          66.1k10 gold badges110 silver badges192 bronze badges










          answered Jul 14 at 23:43









          filbrandenfilbranden

          12.9k2 gold badges25 silver badges54 bronze badges




          12.9k2 gold badges25 silver badges54 bronze badges







          • 1





            I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

            – Alko
            Jul 15 at 9:04






          • 3





            You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

            – ctrl-alt-delor
            Jul 15 at 9:29






          • 1





            Hey, thanks a lot.

            – ScipioAfricanus
            Jul 16 at 16:29












          • 1





            I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

            – Alko
            Jul 15 at 9:04






          • 3





            You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

            – ctrl-alt-delor
            Jul 15 at 9:29






          • 1





            Hey, thanks a lot.

            – ScipioAfricanus
            Jul 16 at 16:29







          1




          1





          I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

          – Alko
          Jul 15 at 9:04





          I was just having the same issue myself and have been considering changing the service to regular user. This is a lot better. Thanks!

          – Alko
          Jul 15 at 9:04




          3




          3





          You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

          – ctrl-alt-delor
          Jul 15 at 9:29





          You can also but default permissions on the directory, to give you permission, using setfacl. see unix.stackexchange.com/questions/101263/…

          – ctrl-alt-delor
          Jul 15 at 9:29




          1




          1





          Hey, thanks a lot.

          – ScipioAfricanus
          Jul 16 at 16:29





          Hey, thanks a lot.

          – ScipioAfricanus
          Jul 16 at 16:29

















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Unix & Linux Stack Exchange!


          • 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%2funix.stackexchange.com%2fquestions%2f530154%2fwhy-run-a-service-as-a-system-user%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

          Category:9 (number) SubcategoriesMedia in category "9 (number)"Navigation menuUpload mediaGND ID: 4485639-8Library of Congress authority ID: sh85091979ReasonatorScholiaStatistics

          Circuit construction for execution of conditional statements using least significant bitHow are two different registers being used as “control”?How exactly is the stated composite state of the two registers being produced using the $R_zz$ controlled rotations?Efficiently performing controlled rotations in HHLWould this quantum algorithm implementation work?How to prepare a superposed states of odd integers from $1$ to $sqrtN$?Why is this implementation of the order finding algorithm not working?Circuit construction for Hamiltonian simulationHow can I invert the least significant bit of a certain term of a superposed state?Implementing an oracleImplementing a controlled sum operation

          Magento 2 “No Payment Methods” in Admin New OrderHow to integrate Paypal Express Checkout with the Magento APIMagento 1.5 - Sales > Order > edit order and shipping methods disappearAuto Invoice Check/Money Order Payment methodAdd more simple payment methods?Shipping methods not showingWhat should I do to change payment methods if changing the configuration has no effects?1.9 - No Payment Methods showing upMy Payment Methods not Showing for downloadable/virtual product when checkout?Magento2 API to access internal payment methodHow to call an existing payment methods in the registration form?