Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO

How to resolve java.security.NoSuchAlgorithmException: Unsupported passphrase algorithm: DES-EDE3-CFB

0 votes
58 views
asked Aug 18 in Java FTP by kevntrace (120 points)
I am new employee at a software vendor that has embedded your java pro library into our product.  I am trying to set up an sftp connection in our product to CoreFTPServer running on the same box.  I have configured CoreFTP client and confirmed I can connect using sftp.

Unfortunately I do not have easy access to the folks who build our software to understand the dynamics of the relationship/contract/agreement with EnterpriseDT, so thought I would come on here to ask, since the Java stack trace shows the error is in your classes.

We are using Sun/Oracle JRE 8 on Windows Server 2012.  I have no idea which version of the EnterpriseDT library we are using.  I did see a message from 2008 on this site that you were going to add support for DES-EDE3-CFB so I find it hard to believe you haven't done that already.  I used a newer version of openssh to generate a different RSA private/public keypair encrypted with AES-128-CBC but I get the same error.

I am at a loss of how to resolve this and would appreciate some insight.
commented Aug 18 by Admin (2,230 points)
What is the error that you're seeing?
commented Aug 18 by kevntrace (120 points)
com.appresso.ds.dp.modules.adapter.ftp.InvalidPrivateKeyException: Format of the private key file or passphrase of the private key file is invalid.
    at com.appresso.ds.dp.modules.adapter.ftp.edtftpj.FTPClientFactory.a(Unknown Source)
    at com.appresso.ds.dp.modules.adapter.ftp.edtftpj.FTPClientFactory.createFTPClient(Unknown Source)
    at com.appresso.ds.dp.modules.adapter.ftp.FTPAdapterResourceFactory$a.actionPerformed(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.c.actionPerformed(Unknown Source)
    at com.appresso.ds.common.spi.config.impl.ConfigElementImpl.actionPerformed(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.ap$10.process(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.RemoteDataProcessingUtil$1.run(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.session.DataSpiderSessionManagerImpl.doWithSession(Unknown Source)
    at sun.reflect.GeneratedMethodAccessor93.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at com.appresso.ds.kernel.c.a(Unknown Source)
    at com.appresso.ds.kernel.ai.a(Unknown Source)
    at com.appresso.ds.kernel.i$1.invoke(Unknown Source)
    at com.sun.proxy.$Proxy0.doWithSession(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.e.a(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.RemoteDataProcessingUtil.a(Unknown Source)
    at com.appresso.ds.kernel.modules.mgr.dpcon.ap.actionPerformed(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:323)
    at sun.rmi.transport.Transport$1.run(Transport.java:200)
    at sun.rmi.transport.Transport$1.run(Transport.java:197)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
    at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$256(TCPTransport.java:683)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682)
    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)
Caused by: com.enterprisedt.net.j2ssh.transport.publickey.InvalidSshKeyException: Can't read key due to cryptography problems
    at com.enterprisedt.net.j2ssh.openssh.OpenSSHPrivateKeyFormat.decryptKeyblob(OpenSSHPrivateKeyFormat.java:127)
    at com.enterprisedt.net.j2ssh.transport.publickey.SshPrivateKeyFile.toPrivateKey(SshPrivateKeyFile.java:245)
    at com.enterprisedt.net.ftp.ssh.SCPClient.setAuthentication(SCPClient.java:520)
    ... 35 more
Caused by: java.security.NoSuchAlgorithmException: Unsupported passphrase algorithm: AES-128-CBC
    at com.enterprisedt.net.j2ssh.openssh.PEMReader.decryptPayload(PEMReader.java:191)
    at com.enterprisedt.net.j2ssh.openssh.OpenSSHPrivateKeyFormat.decryptKeyblob(OpenSSHPrivateKeyFormat.java:99)
    ... 37 more
commented Aug 18 by support2 (143,750 points)
DES-EDE3-CFB and AES-128-CBC are both supported. It might be that your vendor is using a very old version of edtFTPj/PRO that is prior to these being implemented.

If that's the case, you probably need to use DES-EDE3-CBC.

Please log in or register to answer this question.

...