Class SshAgentSessionFactory
- java.lang.Object
-
- org.eclipse.jgit.transport.SshSessionFactory
-
- org.eclipse.jgit.transport.JschConfigSessionFactory
-
- com.github.danielflower.mavenplugins.release.SshAgentSessionFactory
-
public class SshAgentSessionFactory extends org.eclipse.jgit.transport.JschConfigSessionFactorySSH-Agent enabler. A JschConfigSessionFactory which sets the Preferred authentication method to Publickey, and tries to use a NetCat Socket Factory to reach a ssh-agent process via it's Unix Socket as identified by environment var SSH_AUTH_SOCK. Note that this requires the 'nc' binary installed and available on PATH!- Author:
- Johan Ström johan@pistonlabs.com
-
-
Constructor Summary
Constructors Constructor Description SshAgentSessionFactory(org.apache.maven.plugin.logging.Log log, String knownHostsOrNull, String identityFile, String passphraseOrNull)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidconfigure(org.eclipse.jgit.transport.OpenSshConfig.Host host, com.jcraft.jsch.Session sn)protected com.jcraft.jsch.JSchcreateDefaultJSch(org.eclipse.jgit.util.FS fs)-
Methods inherited from class org.eclipse.jgit.transport.JschConfigSessionFactory
configureJSch, createSession, getJSch, getSession, getType
-
-
-
-
Method Detail
-
configure
protected void configure(org.eclipse.jgit.transport.OpenSshConfig.Host host, com.jcraft.jsch.Session sn)- Overrides:
configurein classorg.eclipse.jgit.transport.JschConfigSessionFactory
-
createDefaultJSch
protected com.jcraft.jsch.JSch createDefaultJSch(org.eclipse.jgit.util.FS fs) throws com.jcraft.jsch.JSchException- Overrides:
createDefaultJSchin classorg.eclipse.jgit.transport.JschConfigSessionFactory- Throws:
com.jcraft.jsch.JSchException
-
-