public class JGitPublicKeyIterator extends org.apache.sshd.client.auth.pubkey.AbstractKeyPairIterator<org.apache.sshd.client.auth.pubkey.PublicKeyIdentity> implements Channel
UserAuthPublicKeyIterator
, which
in its constructor does some strange Stream
"magic"
that ends up loading keys prematurely. This class uses plain
Iterator
s instead to avoid that problem. Used in
JGitPublicKeyAuthentication
.Constructor and Description |
---|
JGitPublicKeyIterator(org.apache.sshd.client.session.ClientSession session,
org.apache.sshd.common.signature.SignatureFactoriesManager signatureFactories)
Creates a new
JGitPublicKeyIterator . |
Modifier and Type | Method and Description |
---|---|
void |
close() |
boolean |
hasNext() |
boolean |
isOpen() |
org.apache.sshd.client.auth.pubkey.PublicKeyIdentity |
next() |
getClientSession, getSession, remove, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
forEachRemaining
public JGitPublicKeyIterator(org.apache.sshd.client.session.ClientSession session, org.apache.sshd.common.signature.SignatureFactoriesManager signatureFactories) throws Exception
JGitPublicKeyIterator
.session
- we're trying to authenticatesignatureFactories
- to useException
- if an SshAgentFactory
is configured and getting
identities from the agent failspublic void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in interface Channel
IOException
public boolean hasNext()
Copyright © 2019 Eclipse JGit Project. All rights reserved.