diff options
-rw-r--r-- | src/main/java/com/gitblit/transport/ssh/SshDaemon.java | 6 | ||||
-rw-r--r-- | src/main/java/com/gitblit/transport/ssh/SshKeyAuthenticator.java (renamed from src/main/java/com/gitblit/transport/ssh/FileBasedPubKeyAuth.java) | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/main/java/com/gitblit/transport/ssh/SshDaemon.java b/src/main/java/com/gitblit/transport/ssh/SshDaemon.java index 2740e915..d0b7490e 100644 --- a/src/main/java/com/gitblit/transport/ssh/SshDaemon.java +++ b/src/main/java/com/gitblit/transport/ssh/SshDaemon.java @@ -96,8 +96,8 @@ public class SshDaemon { hostKeyPairProvider.setFiles(new String [] { rsaKeyStore.getPath(), dsaKeyStore.getPath(), dsaKeyStore.getPath() }); // Client public key authenticator - CachingPublicKeyAuthenticator keyAuthenticator = - new CachingPublicKeyAuthenticator(new FileBasedPubKeyAuth(gitblit.getPublicKeyManager(), gitblit)); + SshKeyAuthenticator keyAuthenticator = + new SshKeyAuthenticator(gitblit.getPublicKeyManager(), gitblit); // Configure the preferred SSHD backend String sshBackendStr = settings.getString(Keys.git.sshBackend, @@ -123,7 +123,7 @@ public class SshDaemon { sshd.setPort(addr.getPort()); sshd.setHost(addr.getHostName()); sshd.setKeyPairProvider(hostKeyPairProvider); - sshd.setPublickeyAuthenticator(keyAuthenticator); + sshd.setPublickeyAuthenticator(new CachingPublicKeyAuthenticator(keyAuthenticator)); sshd.setPasswordAuthenticator(new UsernamePasswordAuthenticator(gitblit)); sshd.setSessionFactory(new SshServerSessionFactory()); sshd.setFileSystemFactory(new DisabledFilesystemFactory()); diff --git a/src/main/java/com/gitblit/transport/ssh/FileBasedPubKeyAuth.java b/src/main/java/com/gitblit/transport/ssh/SshKeyAuthenticator.java index b6a52f9c..c28a2ed6 100644 --- a/src/main/java/com/gitblit/transport/ssh/FileBasedPubKeyAuth.java +++ b/src/main/java/com/gitblit/transport/ssh/SshKeyAuthenticator.java @@ -32,7 +32,7 @@ import com.google.common.base.Preconditions; * Authenticates an SSH session against a public key. * */ -public class FileBasedPubKeyAuth implements PublickeyAuthenticator { +public class SshKeyAuthenticator implements PublickeyAuthenticator { protected final Logger log = LoggerFactory.getLogger(getClass()); @@ -40,7 +40,7 @@ public class FileBasedPubKeyAuth implements PublickeyAuthenticator { protected final IAuthenticationManager authManager; - public FileBasedPubKeyAuth(IPublicKeyManager keyManager, IAuthenticationManager authManager) { + public SshKeyAuthenticator(IPublicKeyManager keyManager, IAuthenticationManager authManager) { this.keyManager = keyManager; this.authManager = authManager; } |