1

Topic: To adjust SSH for git - ububtu, phabricator

It turned out to launch at last phabricator on ububtu, and here access to a repository on SSH well does not turn out in any way. For access the user with a name git In etc/ssh  keys is used, public threw in home/git/.ssh under different names (simply tried different): authorized_keys, id_rsa.pub, ssh_hos_rsa_key.pub the Client under Windows Git extension with putty, but tried also others. I try to clone  with a private key  in putty a format. In /var/log/auth.log it is constant one and  an error ubuntu sshd [31066] Failed publickey for git from MojIP port 12514 ssh2: RSA SHA256:kS4uMSvchGCrTlY+zaRbIclkHteClcbzLeKVRtq843yas Keys do not coincide? Or where still to dig? With "" practically I do not work.

2

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> Keys do not coincide? Or where still to dig? With "" practically I do not work. To begin with, ssh-add <private_key_file> to Look, whether it was added ssh-add-l Then if it not the working machine that on it does not be private keys. Only on that computer from which you work: pageant (Win)/ssh-add (Lin) + an option "SSH Agent forwarding" on ssh connection with linux by machine. Forwarded key it should be shown in the same way on "ssh-add-l" the Frequent problem with git in Windows it pageant from  putty, and with git there is the pageant which friend about the friend know nothing

3

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> It turned out to launch at last phabricator on ububtu, and here access to a repository on SSH well does not turn out in any way. AN> for access the user with a name git AN> In etc/ssh  keys is used, public threw in home/git/.ssh under different names (simply tried different): authorized_keys, id_rsa.pub, ssh_hos_rsa_key.pub It is necessary only/home/git/.ssh/authorized_keys with the master git:git and  644. AN> the Client under Windows Git extension with putty, but tried also others. I try to clone  with a private key  in putty a format. On the client  keys, a public key you register on the server in/home/git/.ssh/authorized_keys, a private key you give putty (to this most pageant which as it has been truly noted, can be a little by the machine). It should suffice. Though what  putty with it  can  to  that?

4

Re: To adjust SSH for git - ububtu, phabricator

Hello, Vetal_ca, you wrote: V _> Hello, AlexNek, you wrote: AN>> Keys do not coincide? Or where still to dig? With "" practically I do not work. V _> to begin with, V _> ssh-add <private_key_file> V _> to Look, whether it was added V _> ssh-add-l V _> Then if it not the working machine that on it does not be private keys. Only on that computer from which you work: Here it as that not clearly commands similar on , and keys that should be on Windows, and there such command is not present. Or it is necessary temporarily on  to add? I will try thanks V _> pageant (Win)/ssh-add (Lin) + an option "SSH Agent forwarding" on ssh connection with linux by machine. Forwarded key it should be shown in the same way on "ssh-add-l" V _> the Frequent problem with git in Windows it pageant from  putty, and with git there is the pageant which friend about the friend know nothing In a folder  there are only three programs: bash.exe, git.exe, sh.exe

5

Re: To adjust SSH for git - ububtu, phabricator

Hello, aik, you wrote: aik> Hello, AlexNek, you wrote: AN>> It turned out to launch at last phabricator on ububtu, and here access to a repository on SSH well does not turn out in any way. AN>> for access the user with a name git AN>> In etc/ssh  keys is used, public threw in home/git/.ssh under different names (simply tried different): authorized_keys, id_rsa.pub, ssh_hos_rsa_key.pub aik> It is necessary only/home/git/.ssh/authorized_keys with the master git:git and  644. And everywhere write on/ssh 700, on authorized_keys 600 - and the Client under Windows Git extension with putty made AN>>, but tried also others. I try to clone  with a private key  in putty a format. aik> on the client  keys, a public key you register on the server in/home/git/.ssh/authorized_keys, a private key you give putty (to this most pageant which as it has been truly noted, can be a little by the machine). It should suffice. Though what  putty with it  can  to  that? I on the server  keys, at putty like a bit other format. In/etc/sshd too should be  a key? And at me more also there is nothing to check up on connection.

6

Re: To adjust SSH for git - ububtu, phabricator

Hello, Vetal_ca, you wrote: V _> Hello, AlexNek, you wrote: AN>> Keys do not coincide? Or where still to dig? With "" practically I do not work. V _> to begin with, V _> ssh-add <private_key_file> V _> to Look, whether it was added V _> ssh-add-l V _> Then if it not the working machine that on it does not be private keys. Only on that computer from which you work: V _> pageant (Win)/ssh-add (Lin) + an option "SSH Agent forwarding" on ssh connection with linux by machine. Forwarded key it should be shown in the same way on "ssh-add-l" ssh-add on mine ubuntu does not work, though and in  passed could not open a connection to your authentication agent. ssh localhost works, there is an overload. Whether truth only from session of that user under which came originally are necessary in "/etc/ssh/sshd_config" lines 1. HostKey/etc/ssh/ssh_host_rsa_key 2. PublicKeyAuthentication yes 3. AuthoriyedKeyFile.ssh/authorized_keys can still that is necessary?

7

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> ssh-add on mine ubuntu does not work, though and in  passed AN> could not open a connection to your authentication agent. AN> ssh localhost works, there is an overload. Truth only from session of that user under which came originally it is not necessary to guess, it is necessary to search purposefully. Here the first answer in Google on "could not open a connection to your authentication agent": https://stackoverflow.com/questions/178 … tion-agent There it is a lot of helpful information. In root it is not necessary to pass. Most likely because of it and a problem, since the stereotyped user. At me in the container, too so, more : if [-z "$SSH_AUTH_SOCK"]; then echo "ssh agent is not on" # run ssh-agent eval ` ssh-agent-s ` # add it to startup echo ' eval ` ssh-agent-s ` '>> ~/.bashrc fi AN> can still that is necessary? To use search and to read-read-read, differently one .

8

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> And everywhere write on/ssh 700, on authorized_keys 600 - and made And, well, I did not read, I looked as at me - works with 644 Generally, for authorized_keys should be  are public keys. AN>>> the client under Windows Git extension with putty, but tried also others. I try to clone  with a private key  in putty a format. aik>> on the client  keys, a public key you register on the server in/home/git/.ssh/authorized_keys, a private key you give putty (to this most pageant which as it has been truly noted, can be a little by the machine). It should suffice. Though what  putty with it  can  to  that? AN> I on the server  keys, at putty like a bit other format." openssh "this format, all support it. AN> in/etc/sshd too should be  a key? Yes, but it  at setting sshd on , you should not do anything. And with the password that you on the server start up? And on  in itself  start up? Type" ssh git@localhost "?

9

Re: To adjust SSH for git - ububtu, phabricator

Hello, Vetal_ca, you wrote: V _> Hello, AlexNek, you wrote: AN>> ssh-add on mine ubuntu does not work, though and in  passed AN>> could not open a connection to your authentication agent. AN>> ssh localhost works, there is an overload. Truth only from session of that user under which came originally V _> it is not necessary to guess, it is necessary to search purposefully. V _> here the first answer in Google on "could not open a connection to your authentication agent": V _> https://stackoverflow.com/questions/178 … tion-agent I Looked it, simply not there will be each 5 minutes that that new to write ssh agent similar that is launched, only it in any way does not help, the message remains too most V _> There a lot of helpful information. In root it is not necessary to pass. Most likely because of it and a problem, since the stereotyped user. So if with other users to do almost it is authorized nothing V _> At me in the container, too so, more : V _> V _> if [-z "$SSH_AUTH_SOCK"]; then V _> echo "ssh agent is not on" V _> # run ssh-agent V _> eval ` ssh-agent-s ` V _> # add it to startup V _> echo ' eval ` ssh-agent-s ` '>> ~/.bashrc V _> fi AN>> can still that is necessary? V _> to Use search and to read-read-read, differently one . So already there is more than week in the evenings I search, on which circle I go. There is no simply an understanding broad picture as all is interconnected. Same it is necessary permanently under "" to work.  I too  time tortured while earned. Especially in each answer a little different recommendations.

10

Re: To adjust SSH for git - ububtu, phabricator

Hello, aik, you wrote: aik> Hello, AlexNek, you wrote: AN>> And everywhere write on/ssh 700, on authorized_keys 600 - and made aik> And, well, I did not read, I looked as at me - works with 644 Generally, for authorized_keys should be  are public keys. AN>>>> the client under Windows Git extension with putty, but tried also others. I try to clone  with a private key  in putty a format. aik>>> on the client  keys, a public key you register on the server in/home/git/.ssh/authorized_keys, a private key you give putty (to this most pageant which as it has been truly noted, can be a little by the machine). It should suffice. Though what  putty with it  can  to  that? AN>> I on the server  keys, at putty like a bit other format. aik> "openssh" this format, all support it. The public key from Putti looks approximately so (contents of keys changed)--- BEGIN SSH2 PUBLIC KEY--- Comment: "imported-openssh-key" AAAAB3NzaC1yc2EAAAADAQABAAABAQCYzPEEh5OoM1R/KmsAKTxGEyJu2wIe4NCW AAAAB3NzaC1yc2EAAAADAQABAAABAQCYzPEEh5OoM1R/KmsAKTxGEyJu2wIe4NCW AAAAB3NzaC1yc2EAAAADAQABAAABAQCYzPEEh5OoM1R/KmsAKTxGEyJu2wIe4NCW rjQvgxufGUx5417gAv59N3N03c6GbVGB8f5l/8PSJy1igtIIiQTNR/rlBbQ/GEbL 7qgIuB3d1demGwVoiT1U/7/lEbKlezA7xtdbkpNLg+Dg7WBc0uYiwRSkdzSn20m0 TEQaxhKzU15tpAxVroAiR1Ve/IuZSnz7wSD4ucud8Iuv1uaxspCb--- END SSH2 PUBLIC KEY--- And with Ubuntu it is a little on another ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC+okQdCRGjxik0v5xQmWEaq5JTax6SnQDR5....qNOXPebuoQcfYjDVTqf3srPceyE4zz2PwoejQsdW7pUDMyG04Zaa2ctbrcZ9mHcSamxe9jUEcsRYukP7JUnv24iBqLg/vXQR6vx root@ubuntu AN>> In/etc/sshd too should be  a key? aik> yes, but it  at setting sshd on , you should not do anything. Anything there was not, any keys, yet , I under the password enter, on ssh while I am afraid. Easier system to me ready gave, there much that was wrong aik> And with the password that you on the server start up? And on  in itself  start up? Type "ssh git@localhost"? "ssh localhost" works, but only if I remain under the user from whom came. It I do not remember "ssh git@localhost" it is necessary to check up still, but like too worked.

11

Re: To adjust SSH for git - ububtu, phabricator

While solved with ready product to be played, want though times connection to receive https://bitnami.com/stack/phabricator/virtual-machine

12

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> So if with other users to do almost nothing It is authorized is not connected to access on the remote machine. Make a folder where  and work from it. home is but if in other place: my_dir = "/some_directory" sudo mkdir - parents $ {my_dir} sudo chown user: $ {my_dir} AN>>> can still that is necessary?  to check up access and all affairs: ssh-T git@bitbucket.org or ssh-T git@github.com With original private key in ssh-agent AN> Especially in each answer a little different recommendations. It not from harm and that independently reading will be easier to live. It is checked up on personal experience. A method " all buttons"and"to try all variants" - it is more difficult

13

Re: To adjust SSH for git - ububtu, phabricator

Hello, Vetal_ca, you wrote: Tried with ready , the link hardly gave earlier, the answer to. But there other problem Initialization Error Pull of ' Alextest ' failed: Command failed with error #128! COMMAND git ls-remote ' ******** ' STDOUT (empty) STDERR fatal: unable to access ' https://192.168.2.42/repository.git / ': SSL certificate problem: self signed certificate V _> Hello, AlexNek, you wrote: AN>>>> can still that is necessary? V _> Nea to check up access and all affairs: V _> ssh-T git@bitbucket.org V _> or V _> ssh-T git@github.com V _> With original private key in ssh-agent It I already too thought to make where that account AN>> Especially in each answer a little different recommendations. V _> it not from harm and that independently reading will be easier to live. It is checked up on personal experience. V _> a method " all buttons" and "to try all variants" - it is more difficult Well so such method I do not use. I find that that approaching and I try that write. Simply in the beginning the problem should be found

14

Re: To adjust SSH for git - ububtu, phabricator

Hello, AlexNek, you wrote: AN> It turned out to launch at last phabricator on ububtu, and here access to a repository on SSH well does not turn out in any way. Once while it turned out. Simply so never the reason would find. Began with learning of this link https://docs.bitnami.com/virtual-machin … entication And only the remarkable command sudo/usr/sbin/sshd-d-d-d-f/etc/ssh/sshd_config.phabricator and Which showed there got that there is a directory "/run/sshd" - created. Launched on Windows pagent, fed to it public key and earned! Thanks, who .