assistant: Fix ANNEX_SHELL_DIR written to ~/.ssh/authorized_keys in local pairing to be the absolute path to the repository, not "."
This was a reversion caused by the relative path changes in 5.20150113. Other uses of addAuthorizedKeys seem to be ok. If the user enters a directory like ~/annex, it writes GIT_ANNEX_SHELL_DIRECTORY=annex, and git-annex-shell assumes that's relative to HOME.
This commit is contained in:
parent
20edbf850c
commit
4af3dc72c1
2 changed files with 6 additions and 2 deletions
|
@ -25,8 +25,9 @@ import qualified Data.Text as T
|
|||
setupAuthorizedKeys :: PairMsg -> FilePath -> IO ()
|
||||
setupAuthorizedKeys msg repodir = case validateSshPubKey $ remoteSshPubKey $ pairMsgData msg of
|
||||
Left err -> error err
|
||||
Right pubkey ->
|
||||
unlessM (liftIO $ addAuthorizedKeys True repodir pubkey) $
|
||||
Right pubkey -> do
|
||||
absdir <- absPath repodir
|
||||
unlessM (liftIO $ addAuthorizedKeys True absdir pubkey) $
|
||||
error "failed setting up ssh authorized keys"
|
||||
|
||||
{- When local pairing is complete, this is used to set up the remote for
|
||||
|
|
3
debian/changelog
vendored
3
debian/changelog
vendored
|
@ -6,6 +6,9 @@ git-annex (5.20150618) UNRELEASED; urgency=medium
|
|||
use the ssh agent of a new login session.
|
||||
* assistant: Fix local pairing to not include newline in ssh pubkey,
|
||||
which is rejected on the other end for security reasons.
|
||||
* assistant: Fix ANNEX_SHELL_DIR written to ~/.ssh/authorized_keys
|
||||
in local pairing to be the absolute path to the repository, not "."
|
||||
This was a reversion caused by the relative path changes in 5.20150113.
|
||||
|
||||
-- Joey Hess <id@joeyh.name> Thu, 02 Jul 2015 12:31:14 -0400
|
||||
|
||||
|
|
Loading…
Reference in a new issue