SSH login, how to set keys to user accounts





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







0















I have 3 people with 3 windows machine and 1 ubuntu 12.04 server. I have created each user account and added them to the sudo group. I have copied the public keys straight from puttygen straight into the authenticated_keys file.



I want to know how to tell each key to allow a specific user in. all the keys end in rsa-ssh "date". all the keys work for my account but not for any of the other accounts when I want one key to work for one account.



I have tried adding user@computername at the end of the key in the authenticated_keys files, but no luck. I just get No Supported Authentication methods available.



I have looked all over google but cant find a easy explanation.



Thank you for any help.










share|improve this question































    0















    I have 3 people with 3 windows machine and 1 ubuntu 12.04 server. I have created each user account and added them to the sudo group. I have copied the public keys straight from puttygen straight into the authenticated_keys file.



    I want to know how to tell each key to allow a specific user in. all the keys end in rsa-ssh "date". all the keys work for my account but not for any of the other accounts when I want one key to work for one account.



    I have tried adding user@computername at the end of the key in the authenticated_keys files, but no luck. I just get No Supported Authentication methods available.



    I have looked all over google but cant find a easy explanation.



    Thank you for any help.










    share|improve this question



























      0












      0








      0








      I have 3 people with 3 windows machine and 1 ubuntu 12.04 server. I have created each user account and added them to the sudo group. I have copied the public keys straight from puttygen straight into the authenticated_keys file.



      I want to know how to tell each key to allow a specific user in. all the keys end in rsa-ssh "date". all the keys work for my account but not for any of the other accounts when I want one key to work for one account.



      I have tried adding user@computername at the end of the key in the authenticated_keys files, but no luck. I just get No Supported Authentication methods available.



      I have looked all over google but cant find a easy explanation.



      Thank you for any help.










      share|improve this question
















      I have 3 people with 3 windows machine and 1 ubuntu 12.04 server. I have created each user account and added them to the sudo group. I have copied the public keys straight from puttygen straight into the authenticated_keys file.



      I want to know how to tell each key to allow a specific user in. all the keys end in rsa-ssh "date". all the keys work for my account but not for any of the other accounts when I want one key to work for one account.



      I have tried adding user@computername at the end of the key in the authenticated_keys files, but no luck. I just get No Supported Authentication methods available.



      I have looked all over google but cant find a easy explanation.



      Thank you for any help.







      ssh login






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 24 at 12:11









      anonymous2

      3,38242149




      3,38242149










      asked Nov 5 '13 at 10:25









      DavidDavid

      1




      1






















          2 Answers
          2






          active

          oldest

          votes


















          1














          You have to copy the ssh public keys to each user account. Otherwise, the keys will only work for your account.




          ~/.ssh/authorized_keys



          Lists the public keys (DSA/ECDSA/RSA) that can be used for logging in as this user.




          So, every user that will use the keys to log in, needs their respective keys in each users ~/.ssh/authorized_keys.



          Related




          • https://security.stackexchange.com/q/34216/27973

          • https://apple.stackexchange.com/q/21959

          • How to use multiple ssh keys with different accounts and hosts






          share|improve this answer


























          • all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

            – David
            Nov 5 '13 at 10:58






          • 1





            @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

            – Braiam
            Nov 5 '13 at 11:12



















          0














          You'll put the keys (from putty) in the file ~/.ssh/authorized_keys not authenticated_keys.






          share|improve this answer
























          • spelling is not the problem

            – David
            Nov 5 '13 at 10:57












          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          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%2faskubuntu.com%2fquestions%2f371412%2fssh-login-how-to-set-keys-to-user-accounts%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          2 Answers
          2






          active

          oldest

          votes








          2 Answers
          2






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1














          You have to copy the ssh public keys to each user account. Otherwise, the keys will only work for your account.




          ~/.ssh/authorized_keys



          Lists the public keys (DSA/ECDSA/RSA) that can be used for logging in as this user.




          So, every user that will use the keys to log in, needs their respective keys in each users ~/.ssh/authorized_keys.



          Related




          • https://security.stackexchange.com/q/34216/27973

          • https://apple.stackexchange.com/q/21959

          • How to use multiple ssh keys with different accounts and hosts






          share|improve this answer


























          • all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

            – David
            Nov 5 '13 at 10:58






          • 1





            @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

            – Braiam
            Nov 5 '13 at 11:12
















          1














          You have to copy the ssh public keys to each user account. Otherwise, the keys will only work for your account.




          ~/.ssh/authorized_keys



          Lists the public keys (DSA/ECDSA/RSA) that can be used for logging in as this user.




          So, every user that will use the keys to log in, needs their respective keys in each users ~/.ssh/authorized_keys.



          Related




          • https://security.stackexchange.com/q/34216/27973

          • https://apple.stackexchange.com/q/21959

          • How to use multiple ssh keys with different accounts and hosts






          share|improve this answer


























          • all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

            – David
            Nov 5 '13 at 10:58






          • 1





            @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

            – Braiam
            Nov 5 '13 at 11:12














          1












          1








          1







          You have to copy the ssh public keys to each user account. Otherwise, the keys will only work for your account.




          ~/.ssh/authorized_keys



          Lists the public keys (DSA/ECDSA/RSA) that can be used for logging in as this user.




          So, every user that will use the keys to log in, needs their respective keys in each users ~/.ssh/authorized_keys.



          Related




          • https://security.stackexchange.com/q/34216/27973

          • https://apple.stackexchange.com/q/21959

          • How to use multiple ssh keys with different accounts and hosts






          share|improve this answer















          You have to copy the ssh public keys to each user account. Otherwise, the keys will only work for your account.




          ~/.ssh/authorized_keys



          Lists the public keys (DSA/ECDSA/RSA) that can be used for logging in as this user.




          So, every user that will use the keys to log in, needs their respective keys in each users ~/.ssh/authorized_keys.



          Related




          • https://security.stackexchange.com/q/34216/27973

          • https://apple.stackexchange.com/q/21959

          • How to use multiple ssh keys with different accounts and hosts







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Apr 13 '17 at 12:45









          Community

          1




          1










          answered Nov 5 '13 at 10:42









          BraiamBraiam

          52.6k20138223




          52.6k20138223













          • all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

            – David
            Nov 5 '13 at 10:58






          • 1





            @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

            – Braiam
            Nov 5 '13 at 11:12



















          • all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

            – David
            Nov 5 '13 at 10:58






          • 1





            @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

            – Braiam
            Nov 5 '13 at 11:12

















          all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

          – David
          Nov 5 '13 at 10:58





          all these links explain for one user account, i have 3 and 3 separate keys in the file, i want to know how to specify a key for a specific log in

          – David
          Nov 5 '13 at 10:58




          1




          1





          @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

          – Braiam
          Nov 5 '13 at 11:12





          @David those links are "related" but don't answer your question. I'm telling you that if you created 3 keys for each 3 accounts then the keys has to be in each users ~/.ssh/authorized_keys or to put it bluntly user1 key has to be in /home/user1/.ssh/authorized_keys, user2 key has to be in /home/user2/.ssh/authorized_keys, etc.

          – Braiam
          Nov 5 '13 at 11:12













          0














          You'll put the keys (from putty) in the file ~/.ssh/authorized_keys not authenticated_keys.






          share|improve this answer
























          • spelling is not the problem

            – David
            Nov 5 '13 at 10:57
















          0














          You'll put the keys (from putty) in the file ~/.ssh/authorized_keys not authenticated_keys.






          share|improve this answer
























          • spelling is not the problem

            – David
            Nov 5 '13 at 10:57














          0












          0








          0







          You'll put the keys (from putty) in the file ~/.ssh/authorized_keys not authenticated_keys.






          share|improve this answer













          You'll put the keys (from putty) in the file ~/.ssh/authorized_keys not authenticated_keys.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Nov 5 '13 at 10:42









          NoxvilleNoxville

          101




          101













          • spelling is not the problem

            – David
            Nov 5 '13 at 10:57



















          • spelling is not the problem

            – David
            Nov 5 '13 at 10:57

















          spelling is not the problem

          – David
          Nov 5 '13 at 10:57





          spelling is not the problem

          – David
          Nov 5 '13 at 10:57


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Ask Ubuntu!


          • 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%2faskubuntu.com%2fquestions%2f371412%2fssh-login-how-to-set-keys-to-user-accounts%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

          How did Captain America manage to do this?

          迪纳利

          南乌拉尔铁路局