Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sga-ssh does not work with custom port #21

Open
lluchs opened this issue Sep 24, 2018 · 2 comments
Open

sga-ssh does not work with custom port #21

lluchs opened this issue Sep 24, 2018 · 2 comments

Comments

@lluchs
Copy link

lluchs commented Sep 24, 2018

I'm trying to use sga-ssh to connect to a git repository on a custom port.

With the environment variables from sga-env.sh, this fails with:

fatal: ssh variant 'simple' does not support setting port

Adding export GIT_SSH_VARIANT=ssh fixes this issue on the git side, but now sga-ssh just hangs.

This is the debug output:

% sga-ssh --debug [email protected] -p7999 git-upload-pack                       
2018/09/24 07:01:09 handshake.go:355: kex loop
2018/09/24 07:01:09 handshake.go:360: kex inner loop
2018/09/24 07:01:09 handshake.go:370: select exit: <-requestKex
2018/09/24 07:01:09 handshake.go:393: !sent: sending kexInit
2018/09/24 07:01:09 handshake.go:360: kex inner loop
2018/09/24 07:01:09 handshake.go:368: select exit: <-t.startKex
2018/09/24 07:01:09 handshake.go:416: entering keyexchange
2018/09/24 07:01:09 common.go:139: host key algorithms: server: [none], client: [none]
2018/09/24 07:01:09 delegated_client.go:582: KexCallback called
2018/09/24 07:01:09 handshake.go:355: kex loop
2018/09/24 07:01:09 handshake.go:360: kex inner loop
2018/09/24 07:01:12 delegated_client.go:634: [email protected] request denied, continuing
2018/09/24 07:01:12 delegated_client.go:641: Initiating Handoff Key Exchange
2018/09/24 07:01:12 handshake.go:326: requestKeyExchange, t.deferHostKeyVerification: %!b(bool=false)
2018/09/24 07:01:12 handshake.go:370: select exit: <-requestKex
2018/09/24 07:01:12 handshake.go:393: !sent: sending kexInit
2018/09/24 07:01:12 handshake.go:360: kex inner loop
2018/09/24 07:01:12 delegated_client.go:539: Finished copying transport data to agent
2018/09/24 07:01:12 handshake.go:368: select exit: <-t.startKex
2018/09/24 07:01:12 handshake.go:416: entering keyexchange
2018/09/24 07:01:12 common.go:139: host key algorithms: server: [ssh-rsa], client: [[email protected] [email protected] [email protected] [email protected] [email protected] [email protected] ecdsa-sha2-nistp256 ecdsa-sha2-nistp384 ecdsa-sha2-nistp521 ssh-rsa ssh-dss ssh-ed25519]                                                                    
@dimakogan
Copy link
Collaborator

dimakogan commented Sep 24, 2018

Thanks for reporting. Do you perhaps know what git/ssh version the server is running?
To get the ssh version string, you can run ssh [email protected] -v 2>&1 | grep Remote

@lluchs
Copy link
Author

lluchs commented Sep 25, 2018

The server is Bitbucket Server v4.8.6, which I believe uses some Java SSH implementation. It identifies as SSH-2.0-SSHD-UNKNOWN (output from your command: debug1: Remote protocol version 2.0, remote software version SSHD-UNKNOWN).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants