File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -108,6 +108,7 @@ var (
108
108
StartBuiltinServer : false ,
109
109
Domain : "" ,
110
110
Port : 22 ,
111
+ ServerCiphers : []
string {
"aes128-ctr" ,
"aes192-ctr" ,
"aes256-ctr" ,
"[email protected] " ,
"arcfour256" ,
"arcfour128" },
111
112
KeygenPath : "ssh-keygen" ,
112
113
}
113
114
@@ -709,7 +710,10 @@ func NewContext() {
709
710
SSH .Domain = Domain
710
711
}
711
712
SSH .RootPath = path .Join (homeDir , ".ssh" )
712
- SSH .ServerCiphers = sec .Key ("SSH_SERVER_CIPHERS" ).Strings ("," )
713
+ serverCiphers := sec .Key ("SSH_SERVER_CIPHERS" ).Strings ("," )
714
+ if len (serverCiphers ) > 0 {
715
+ SSH .ServerCiphers = serverCiphers
716
+ }
713
717
SSH .KeyTestPath = os .TempDir ()
714
718
if err = Cfg .Section ("server" ).MapTo (& SSH ); err != nil {
715
719
log .Fatal (4 , "Failed to map SSH settings: %v" , err )
You can’t perform that action at this time.
0 commit comments