Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
K
koko
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
koko
Commits
fe737ee9
Commit
fe737ee9
authored
Jun 25, 2019
by
Eric
Committed by
Eric_Lee
Jun 25, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bugs: parse privatekey
parent
f2d5a7d7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
connmanager.go
pkg/srvconn/connmanager.go
+1
-1
No files found.
pkg/srvconn/connmanager.go
View file @
fe737ee9
...
...
@@ -58,7 +58,7 @@ func (sc *SSHClientConfig) Config() (config *gossh.ClientConfig, err error) {
}
}
if
sc
.
PrivateKey
!=
""
{
if
signer
,
err
:=
gossh
.
ParsePrivateKey
([]
byte
(
sc
.
PrivateKey
));
err
!=
nil
{
if
signer
,
err
:=
gossh
.
ParsePrivateKey
WithPassphrase
([]
byte
(
sc
.
PrivateKey
),[]
byte
(
sc
.
Password
));
err
!=
nil
{
err
=
fmt
.
Errorf
(
"parse private key error: %s"
,
err
)
return
config
,
err
}
else
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment