CryptographicException in BaseClient.Connect()
Nessuno ha ancora preso questa issue.
- Lingua principale
- C#
- Stelle
- 4.4k
- Fork
- 993
- Merge medio
- 9g 21h
- PR unite (30g)
- 1
Descrizione
Using SSH.NET 2020.0.1, occasionally CryptographicException is thrown in call to BaseClient.Connect():
System.Security.Cryptography.CryptographicException: Hash not valid for use in specified state.
at System.Security.Cryptography.CryptographicException.ThrowCryptographicException(Int32 hr)
at System.Security.Cryptography.Utils.HashData(SafeHashHandle hHash, Byte[] data, Int32 cbData, Int32 ibStart, Int32 cbSize)
at System.Security.Cryptography.SHA1CryptoServiceProvider.HashCore(Byte[] rgb, Int32 ibStart, Int32 cbSize)
at System.Security.Cryptography.HashAlgorithm.ComputeHash(Byte[] buffer)
at Renci.SshNet.Security.Cryptography.CipherDigitalSignature.Sign(Byte[] input)
at Renci.SshNet.Security.KeyHostAlgorithm.Sign(Byte[] data)
at Renci.SshNet.PrivateKeyAuthenticationMethod.Authenticate(Session session)
at Renci.SshNet.ClientAuthentication.TryAuthenticate(ISession session, AuthenticationState authenticationState, String[] allowedAuthenticationMethods, SshAuthenticationException& authenticationException)
at Renci.SshNet.ClientAuthentication.Authenticate(IConnectionInfoInternal connectionInfo, ISession session)
at Renci.SshNet.ConnectionInfo.Authenticate(ISession session, IServiceFactory serviceFactory)
at Renci.SshNet.Session.Connect()
at Renci.SshNet.BaseClient.CreateAndConnectSession()
at Renci.SshNet.BaseClient.Connect()
Will try to gather more info and report back.
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Parti da BaseClient.Connect() e segui lo stack segnalato attraverso PrivateKeyAuthenticationMethod.Authenticate, KeyHostAlgorithm.Sign e CipherDigitalSignature.Sign. Riproduci la CryptographicException intermittente con SSH.NET 2020.0.1 ed esamina il flusso circostante di autenticazione e firma; il lavoro è completato quando la causa è stata identificata e la connessione non produce più questa eccezione.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- csharp
- Ambito
- security
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100