Nick
6 hours ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
3 additions and
1 deletions
-
common/version-control/src/main/java/org/thingsboard/server/service/sync/vc/GitRepository.java
|
|
@ -605,7 +605,9 @@ public class GitRepository { |
|
|
try { |
|
|
try { |
|
|
keyPairs = SecurityUtils.loadKeyPairIdentities(null, |
|
|
keyPairs = SecurityUtils.loadKeyPairIdentities(null, |
|
|
null, new ByteArrayInputStream(privateKeyContent.getBytes()), (session, resourceKey, retryIndex) -> password); |
|
|
null, new ByteArrayInputStream(privateKeyContent.getBytes()), (session, resourceKey, retryIndex) -> password); |
|
|
} catch (Exception e) {} |
|
|
} catch (Exception e) { |
|
|
|
|
|
log.error("Failed to load ssh private key", e); |
|
|
|
|
|
} |
|
|
if (keyPairs == null) { |
|
|
if (keyPairs == null) { |
|
|
throw new IllegalArgumentException("Failed to load ssh private key"); |
|
|
throw new IllegalArgumentException("Failed to load ssh private key"); |
|
|
} |
|
|
} |
|
|
|