#1787 SFTP + Java 1.8 = com.jcraft.jsch.JSchException: Auth Cancel

None
closed-wont-fix
nobody
5
2015-01-25
2014-05-07
Alan Ezust
No

Using JEdit 5.2pre1, FTP 1.1.0, and Oracle Java 8 (jdk1.8.0_05) on Linux, I was unable to make any sftp connections. I was repeatedly getting "Auth Cancel" exceptions thrown.
Switching back to Java 1.7 makes the problem go away.

I had JCE strong encryption installed, but I am using 2048 bit DSA keys. It is the high keystrength that is causing problems. 2048 bit DSA keys are no longer possible to create with ssh-keygen. Creating a new keypair with a newer ssh-keygen also makes the problem go away.

java.io.IOException: com.jcraft.jsch.JSchException: Auth cancel
at ftp.SFtpConnection.<init>(SFtpConnection.java:148)
at ftp.ConnectionManager.getConnection(ConnectionManager.java:524)
at ftp.FtpVFS.getConnection(FtpVFS.java:529)
at ftp.FtpVFS._listFiles(FtpVFS.java:222)
at org.gjt.sp.jedit.browser.ListDirectoryBrowserTask._run(ListDirectoryBrowserTask.java:74)
at org.gjt.sp.util.Task.run(Task.java:64)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

Discussion

  • Alan Ezust
    Alan Ezust
    2014-05-09

    After committing a recent change to FTP in SVN, I get a more complete stack trace:
    com.jcraft.jsch.JSchException: Auth cancel
    at com.jcraft.jsch.Session.connect(Session.java:511)
    at ftp.SFtpConnection.<init>(SFtpConnection.java:138)
    at ftp.ConnectionManager.getConnection(ConnectionManager.java:524)
    at ftp.FtpVFS.getConnection(FtpVFS.java:529)
    at ftp.FtpVFS._listFiles(FtpVFS.java:222)
    at org.gjt.sp.jedit.browser.ListDirectoryBrowserTask._run(ListDirectoryBrowserTask.java:74)
    at org.gjt.sp.util.Task.run(Task.java:64)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)

     
  • Just reporting: I'm having the same using jEdit 5.1 and 5.2pre1 (installed it to check if that's not 5.1 bug :/) ...
    Both running on Oracle Java 1.7.0_17.

     
  • Alan Ezust
    Alan Ezust
    2014-11-28

    • status: open --> closed-wont-fix