aboutsummaryrefslogtreecommitdiffstats
path: root/vm/gce
diff options
context:
space:
mode:
authorAleksandr Nogikh <nogikh@google.com>2021-09-30 15:05:40 +0000
committerAleksandr Nogikh <wp32pw@gmail.com>2021-09-30 17:32:21 +0200
commit1d849ab4d892af13a249f75628790b47e42b7c74 (patch)
treee5c02fb5301afb3824c3fcd9c7015036dce9f1be /vm/gce
parentb70d9504587d0ea0ce5c966abf0fc53a79688fff (diff)
vm/gce: allow ssh-rsa from Run()
Allow ssh-rsa not only from getSerialPortOutput(), but also from Run().
Diffstat (limited to 'vm/gce')
-rw-r--r--vm/gce/gce.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/vm/gce/gce.go b/vm/gce/gce.go
index 46e7326a6..93a96c5e8 100644
--- a/vm/gce/gce.go
+++ b/vm/gce/gce.go
@@ -224,6 +224,8 @@ func (inst *instance) Run(timeout time.Duration, stop <-chan bool, command strin
conAddr := fmt.Sprintf("%v.%v.%v.syzkaller.port=1@ssh-serialport.googleapis.com",
inst.GCE.ProjectID, inst.GCE.ZoneID, inst.name)
conArgs := append(vmimpl.SSHArgs(inst.debug, inst.gceKey, 9600), conAddr)
+ // TODO: remove this later (see also a comment in getSerialPortOutput).
+ conArgs = append(conArgs, "-o", "HostKeyAlgorithms=+ssh-rsa")
con := osutil.Command("ssh", conArgs...)
con.Env = []string{}
con.Stdout = conWpipe