Skip to content

Commit

Permalink
as per net/url, the .Host member can contain the portname
Browse files Browse the repository at this point in the history
this will throw off the ssh_config lookups as the target will be incorrectly
given the server:port string instead of simply server
  • Loading branch information
memetb committed Oct 29, 2024
1 parent 17a977d commit a5fc04c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libvirt/uri/ssh.go
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ func (u *ConnectionURI) dialSSH() (net.Conn, error) {
}

// configuration loaded, build tunnel
sshClient, err := u.dialHost(u.Host, sshcfg, 0)
sshClient, err := u.dialHost(u.Hostname(), sshcfg, 0)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit a5fc04c

Please sign in to comment.