Skip to content
This repository was archived by the owner on Oct 15, 2024. It is now read-only.

Commit 6139693

Browse files
FabianHennekemsfjarvis
authored andcommitted
Temporarily work around SSHJ compatibility issues (#1142)
Using ECDSA either as a key exchange or a host key algorithm fails with SSHJ 0.30.0 on Android, but should again become possible in 0.31.0. While we wait for the release, demote ECDSA in the list of key algorithms (as it should still be available for public key auth) and remove it from the list of key exchange algorithms. (cherry picked from commit 0d2788a)
1 parent c70c179 commit 6139693

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

app/src/main/java/com/zeapo/pwdstore/git/sshj/SshjConfig.kt

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -214,9 +214,6 @@ class SshjConfig : ConfigImpl() {
214214
keyExchangeFactories = listOf(
215215
Curve25519SHA256.Factory(),
216216
FactoryLibSsh(),
217-
ECDHNistP.Factory521(),
218-
ECDHNistP.Factory384(),
219-
ECDHNistP.Factory256(),
220217
DHGexSHA256.Factory(),
221218
// Sends "ext-info-c" with the list of key exchange algorithms. This is needed to get
222219
// rsa-sha2-* key types to work with some servers (e.g. GitHub).
@@ -230,10 +227,10 @@ class SshjConfig : ConfigImpl() {
230227
KeyAlgorithms.EdDSA25519(),
231228
KeyAlgorithms.RSASHA512(),
232229
KeyAlgorithms.RSASHA256(),
230+
KeyAlgorithms.SSHRSA(),
233231
KeyAlgorithms.ECDSASHANistp521(),
234232
KeyAlgorithms.ECDSASHANistp384(),
235233
KeyAlgorithms.ECDSASHANistp256(),
236-
KeyAlgorithms.SSHRSA(),
237234
).map {
238235
OpenKeychainWrappedKeyAlgorithmFactory(it)
239236
}

0 commit comments

Comments
 (0)