You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by Jason Reilly <jd...@renci.org> on 2016/03/04 17:48:09 UTC

ssh access to Karaf 4.0.4

Hi all,

I am seeing an exception in the log when I try the following:

$ ssh -p 8101 -l karaf localhost

Connection reset by 127.0.0.1


 From the karaf.log file:

2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 | ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 | Exception caught

java.security.InvalidAlgorithmParameterException: parameter object not a ECParameterSpec

     at org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown Source)

     at java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45]

     at org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0]

     at org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0]

     at org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0]

     at org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0]

     at org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0]

     at org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0]
....


This is from a custom distribution of Karaf....when I try the same with 
a clean Karaf4 instance, I do not encounter this issue & am able to 
login successfully.  I figured it must be one of the etc/*.cfg files I 
messed up that's included in the custom distribution.  However, when I 
remove all the custom distribution's etc files, I still encounter the 
login problem.  Is there something else I can try?

Thanks
Jason

Re: ssh access to Karaf 4.0.4

Posted by Jason Reilly <jd...@renci.org>.
I figured this out.  I left off from the bottom of my bootFeatures a 
couple of features for some projects that I *thought* worked...meaning I 
didn't think they would not break anything.  One of them included the 
following:

<bundle>mvn:org.bouncycastle/com.springsource.org.bouncycastle.jce/1.39.0</bundle>

When I commented this out, I was able to log in successfully via the ssh 
command.

Thanks for the help,
Jason

On 03/04/2016 01:31 PM, Jason Reilly wrote:
> I did a diff of the fresh Karaf ('feature:list | grep -v Uninstalled | 
> sort') against my custom distribution & noticed I was not including 
> 'shell-compat'.  After adding that, I tried again to get the same error.
>
> Here is what my bootFeatures looks like from the pom.xml:
>
>         <feature>standard</feature>
>
>         <feature>feature</feature>
>
>         <feature>shell</feature>
>
>         <feature>shell-compat</feature>
>
>         <feature>bundle</feature>
>
>         <feature>config</feature>
>
>         <feature>diagnostic</feature>
>
>         <feature>instance</feature>
>
>         <feature>kar</feature>
>
>         <feature>jaas</feature>
>
>         <feature>log</feature>
>
>         <feature>package</feature>
>
>         <feature>service</feature>
>
>         <feature>system</feature>
>
>         <feature>ssh</feature>
>
>         <feature>management</feature>
>
>         <feature>deployer</feature>
>
>         <feature>obr</feature>
>
>         <feature>http</feature>
>
>         <feature>war</feature>
>
>         <feature>jetty</feature>
>
>         <feature>scr</feature>
>
>         <feature>jndi</feature>
>
>         <feature>pax-cdi</feature>
>
>         <feature>aries-blueprint</feature>
>
>         <feature>cxf</feature>
>
>         <feature>jdbc</feature>
>
>         <feature>transaction-api/1.2.0</feature>
>
>         <feature>transaction</feature>
>
>         <feature>jpa</feature>
>
>         <feature>jms</feature>
>
>         <feature>activemq</feature>
>
>
> Suggestions?
>
>
>
>
> On 03/04/2016 12:03 PM, Jean-Baptiste Onofré wrote:
>> Do you define the same default features set as in Karaf standard 
>> distro ? or did you remove some features/libs ?
>>
>> Regards
>> JB
>>
>> On 03/04/2016 05:57 PM, Jason Reilly wrote:
>>> Yes, I started with bin/karaf.  I was able to do as you did....just not
>>> with my custom distribution.  Something must be different, but I don't
>>> know what.
>>>
>>> On 03/04/2016 11:56 AM, Jean-Baptiste Onofré wrote:
>>>> Do you start Karaf with bin/karaf ?
>>>>
>>>> I just tried with a fresh Karaf 4.0.4:
>>>>
>>>> bin/karaf
>>>>
>>>> and on another terminal:
>>>>
>>>> jbonofre@latitude:~$ ssh -p 8101 karaf@localhost
>>>> Password authentication
>>>> Password:
>>>>         __ __                  ____
>>>>        / //_/____ __________ _/ __/
>>>>       / ,<  / __ `/ ___/ __ `/ /_
>>>>      / /| |/ /_/ / /  / /_/ / __/
>>>>     /_/ |_|\__,_/_/   \__,_/_/
>>>>
>>>>   Apache Karaf (4.0.4)
>>>>
>>>> Hit '<tab>' for a list of available commands
>>>> and '[cmd] --help' for help on a specific command.
>>>> Hit 'system:shutdown' to shutdown Karaf.
>>>> Hit '<ctrl-d>' or type 'logout' to disconnect shell from current 
>>>> session.
>>>>
>>>> karaf@root()>
>>>>
>>>>
>>>> Regards
>>>> JB
>>>>
>>>> On 03/04/2016 05:54 PM, Jason Reilly wrote:
>>>>> $ java -version
>>>>> java version "1.8.0_45"
>>>>> Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
>>>>> Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
>>>>>
>>>>>
>>>>> How do I check which JCE I am using?
>>>>>
>>>>>
>>>>> On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
>>>>>> Hi Jason,
>>>>>>
>>>>>> which JCE/JDK are you using (provider and version) ?
>>>>>>
>>>>>> Thanks,
>>>>>> Regards
>>>>>> JB
>>>>>>
>>>>>> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>>>>>>> Hi all,
>>>>>>>
>>>>>>> I am seeing an exception in the log when I try the following:
>>>>>>>
>>>>>>> $ ssh -p 8101 -l karaf localhost
>>>>>>>
>>>>>>> Connection reset by 127.0.0.1
>>>>>>>
>>>>>>>
>>>>>>>  From the karaf.log file:
>>>>>>>
>>>>>>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>>>>>>> ServerSession                    | 5 - org.apache.sshd.core - 
>>>>>>> 0.14.0 |
>>>>>>> Exception caught
>>>>>>>
>>>>>>> java.security.InvalidAlgorithmParameterException: parameter object
>>>>>>> not a
>>>>>>> ECParameterSpec
>>>>>>>
>>>>>>>      at
>>>>>>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown 
>>>>>>>
>>>>>>>
>>>>>>> Source)
>>>>>>>
>>>>>>>      at
>>>>>>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      at
>>>>>>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0] 
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ....
>>>>>>>
>>>>>>>
>>>>>>> This is from a custom distribution of Karaf....when I try the same
>>>>>>> with
>>>>>>> a clean Karaf4 instance, I do not encounter this issue & am able to
>>>>>>> login successfully.  I figured it must be one of the etc/*.cfg 
>>>>>>> files I
>>>>>>> messed up that's included in the custom distribution. However, 
>>>>>>> when I
>>>>>>> remove all the custom distribution's etc files, I still 
>>>>>>> encounter the
>>>>>>> login problem.  Is there something else I can try?
>>>>>>>
>>>>>>> Thanks
>>>>>>> Jason
>>>>>>
>>>>>
>>>>
>>>
>>
>


Re: ssh access to Karaf 4.0.4

Posted by Jason Reilly <jd...@renci.org>.
I did a diff of the fresh Karaf ('feature:list | grep -v Uninstalled | 
sort') against my custom distribution & noticed I was not including 
'shell-compat'.  After adding that, I tried again to get the same error.

Here is what my bootFeatures looks like from the pom.xml:

         <feature>standard</feature>

         <feature>feature</feature>

         <feature>shell</feature>

         <feature>shell-compat</feature>

         <feature>bundle</feature>

         <feature>config</feature>

         <feature>diagnostic</feature>

         <feature>instance</feature>

         <feature>kar</feature>

         <feature>jaas</feature>

         <feature>log</feature>

         <feature>package</feature>

         <feature>service</feature>

         <feature>system</feature>

         <feature>ssh</feature>

         <feature>management</feature>

         <feature>deployer</feature>

         <feature>obr</feature>

         <feature>http</feature>

         <feature>war</feature>

         <feature>jetty</feature>

         <feature>scr</feature>

         <feature>jndi</feature>

         <feature>pax-cdi</feature>

         <feature>aries-blueprint</feature>

         <feature>cxf</feature>

         <feature>jdbc</feature>

         <feature>transaction-api/1.2.0</feature>

         <feature>transaction</feature>

         <feature>jpa</feature>

         <feature>jms</feature>

         <feature>activemq</feature>


Suggestions?




On 03/04/2016 12:03 PM, Jean-Baptiste Onofré wrote:
> Do you define the same default features set as in Karaf standard 
> distro ? or did you remove some features/libs ?
>
> Regards
> JB
>
> On 03/04/2016 05:57 PM, Jason Reilly wrote:
>> Yes, I started with bin/karaf.  I was able to do as you did....just not
>> with my custom distribution.  Something must be different, but I don't
>> know what.
>>
>> On 03/04/2016 11:56 AM, Jean-Baptiste Onofré wrote:
>>> Do you start Karaf with bin/karaf ?
>>>
>>> I just tried with a fresh Karaf 4.0.4:
>>>
>>> bin/karaf
>>>
>>> and on another terminal:
>>>
>>> jbonofre@latitude:~$ ssh -p 8101 karaf@localhost
>>> Password authentication
>>> Password:
>>>         __ __                  ____
>>>        / //_/____ __________ _/ __/
>>>       / ,<  / __ `/ ___/ __ `/ /_
>>>      / /| |/ /_/ / /  / /_/ / __/
>>>     /_/ |_|\__,_/_/   \__,_/_/
>>>
>>>   Apache Karaf (4.0.4)
>>>
>>> Hit '<tab>' for a list of available commands
>>> and '[cmd] --help' for help on a specific command.
>>> Hit 'system:shutdown' to shutdown Karaf.
>>> Hit '<ctrl-d>' or type 'logout' to disconnect shell from current 
>>> session.
>>>
>>> karaf@root()>
>>>
>>>
>>> Regards
>>> JB
>>>
>>> On 03/04/2016 05:54 PM, Jason Reilly wrote:
>>>> $ java -version
>>>> java version "1.8.0_45"
>>>> Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
>>>> Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
>>>>
>>>>
>>>> How do I check which JCE I am using?
>>>>
>>>>
>>>> On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
>>>>> Hi Jason,
>>>>>
>>>>> which JCE/JDK are you using (provider and version) ?
>>>>>
>>>>> Thanks,
>>>>> Regards
>>>>> JB
>>>>>
>>>>> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>>>>>> Hi all,
>>>>>>
>>>>>> I am seeing an exception in the log when I try the following:
>>>>>>
>>>>>> $ ssh -p 8101 -l karaf localhost
>>>>>>
>>>>>> Connection reset by 127.0.0.1
>>>>>>
>>>>>>
>>>>>>  From the karaf.log file:
>>>>>>
>>>>>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>>>>>> ServerSession                    | 5 - org.apache.sshd.core - 
>>>>>> 0.14.0 |
>>>>>> Exception caught
>>>>>>
>>>>>> java.security.InvalidAlgorithmParameterException: parameter object
>>>>>> not a
>>>>>> ECParameterSpec
>>>>>>
>>>>>>      at
>>>>>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown 
>>>>>>
>>>>>>
>>>>>> Source)
>>>>>>
>>>>>>      at
>>>>>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>      at
>>>>>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0] 
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> ....
>>>>>>
>>>>>>
>>>>>> This is from a custom distribution of Karaf....when I try the same
>>>>>> with
>>>>>> a clean Karaf4 instance, I do not encounter this issue & am able to
>>>>>> login successfully.  I figured it must be one of the etc/*.cfg 
>>>>>> files I
>>>>>> messed up that's included in the custom distribution. However, 
>>>>>> when I
>>>>>> remove all the custom distribution's etc files, I still encounter 
>>>>>> the
>>>>>> login problem.  Is there something else I can try?
>>>>>>
>>>>>> Thanks
>>>>>> Jason
>>>>>
>>>>
>>>
>>
>


Re: ssh access to Karaf 4.0.4

Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Do you define the same default features set as in Karaf standard distro 
? or did you remove some features/libs ?

Regards
JB

On 03/04/2016 05:57 PM, Jason Reilly wrote:
> Yes, I started with bin/karaf.  I was able to do as you did....just not
> with my custom distribution.  Something must be different, but I don't
> know what.
>
> On 03/04/2016 11:56 AM, Jean-Baptiste Onofré wrote:
>> Do you start Karaf with bin/karaf ?
>>
>> I just tried with a fresh Karaf 4.0.4:
>>
>> bin/karaf
>>
>> and on another terminal:
>>
>> jbonofre@latitude:~$ ssh -p 8101 karaf@localhost
>> Password authentication
>> Password:
>>         __ __                  ____
>>        / //_/____ __________ _/ __/
>>       / ,<  / __ `/ ___/ __ `/ /_
>>      / /| |/ /_/ / /  / /_/ / __/
>>     /_/ |_|\__,_/_/   \__,_/_/
>>
>>   Apache Karaf (4.0.4)
>>
>> Hit '<tab>' for a list of available commands
>> and '[cmd] --help' for help on a specific command.
>> Hit 'system:shutdown' to shutdown Karaf.
>> Hit '<ctrl-d>' or type 'logout' to disconnect shell from current session.
>>
>> karaf@root()>
>>
>>
>> Regards
>> JB
>>
>> On 03/04/2016 05:54 PM, Jason Reilly wrote:
>>> $ java -version
>>> java version "1.8.0_45"
>>> Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
>>> Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
>>>
>>>
>>> How do I check which JCE I am using?
>>>
>>>
>>> On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
>>>> Hi Jason,
>>>>
>>>> which JCE/JDK are you using (provider and version) ?
>>>>
>>>> Thanks,
>>>> Regards
>>>> JB
>>>>
>>>> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>>>>> Hi all,
>>>>>
>>>>> I am seeing an exception in the log when I try the following:
>>>>>
>>>>> $ ssh -p 8101 -l karaf localhost
>>>>>
>>>>> Connection reset by 127.0.0.1
>>>>>
>>>>>
>>>>>  From the karaf.log file:
>>>>>
>>>>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>>>>> ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 |
>>>>> Exception caught
>>>>>
>>>>> java.security.InvalidAlgorithmParameterException: parameter object
>>>>> not a
>>>>> ECParameterSpec
>>>>>
>>>>>      at
>>>>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown
>>>>>
>>>>> Source)
>>>>>
>>>>>      at
>>>>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>      at
>>>>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0]
>>>>>
>>>>>
>>>>>
>>>>> ....
>>>>>
>>>>>
>>>>> This is from a custom distribution of Karaf....when I try the same
>>>>> with
>>>>> a clean Karaf4 instance, I do not encounter this issue & am able to
>>>>> login successfully.  I figured it must be one of the etc/*.cfg files I
>>>>> messed up that's included in the custom distribution. However, when I
>>>>> remove all the custom distribution's etc files, I still encounter the
>>>>> login problem.  Is there something else I can try?
>>>>>
>>>>> Thanks
>>>>> Jason
>>>>
>>>
>>
>

-- 
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com

Re: ssh access to Karaf 4.0.4

Posted by Jason Reilly <jd...@renci.org>.
Yes, I started with bin/karaf.  I was able to do as you did....just not 
with my custom distribution.  Something must be different, but I don't 
know what.

On 03/04/2016 11:56 AM, Jean-Baptiste Onofré wrote:
> Do you start Karaf with bin/karaf ?
>
> I just tried with a fresh Karaf 4.0.4:
>
> bin/karaf
>
> and on another terminal:
>
> jbonofre@latitude:~$ ssh -p 8101 karaf@localhost
> Password authentication
> Password:
>         __ __                  ____
>        / //_/____ __________ _/ __/
>       / ,<  / __ `/ ___/ __ `/ /_
>      / /| |/ /_/ / /  / /_/ / __/
>     /_/ |_|\__,_/_/   \__,_/_/
>
>   Apache Karaf (4.0.4)
>
> Hit '<tab>' for a list of available commands
> and '[cmd] --help' for help on a specific command.
> Hit 'system:shutdown' to shutdown Karaf.
> Hit '<ctrl-d>' or type 'logout' to disconnect shell from current session.
>
> karaf@root()>
>
>
> Regards
> JB
>
> On 03/04/2016 05:54 PM, Jason Reilly wrote:
>> $ java -version
>> java version "1.8.0_45"
>> Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
>> Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
>>
>>
>> How do I check which JCE I am using?
>>
>>
>> On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
>>> Hi Jason,
>>>
>>> which JCE/JDK are you using (provider and version) ?
>>>
>>> Thanks,
>>> Regards
>>> JB
>>>
>>> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>>>> Hi all,
>>>>
>>>> I am seeing an exception in the log when I try the following:
>>>>
>>>> $ ssh -p 8101 -l karaf localhost
>>>>
>>>> Connection reset by 127.0.0.1
>>>>
>>>>
>>>>  From the karaf.log file:
>>>>
>>>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>>>> ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 |
>>>> Exception caught
>>>>
>>>> java.security.InvalidAlgorithmParameterException: parameter object 
>>>> not a
>>>> ECParameterSpec
>>>>
>>>>      at
>>>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown 
>>>>
>>>> Source)
>>>>
>>>>      at
>>>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>>
>>>>      at
>>>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0] 
>>>>
>>>>
>>>>
>>>> ....
>>>>
>>>>
>>>> This is from a custom distribution of Karaf....when I try the same 
>>>> with
>>>> a clean Karaf4 instance, I do not encounter this issue & am able to
>>>> login successfully.  I figured it must be one of the etc/*.cfg files I
>>>> messed up that's included in the custom distribution. However, when I
>>>> remove all the custom distribution's etc files, I still encounter the
>>>> login problem.  Is there something else I can try?
>>>>
>>>> Thanks
>>>> Jason
>>>
>>
>


Re: ssh access to Karaf 4.0.4

Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Do you start Karaf with bin/karaf ?

I just tried with a fresh Karaf 4.0.4:

bin/karaf

and on another terminal:

jbonofre@latitude:~$ ssh -p 8101 karaf@localhost
Password authentication
Password:
         __ __                  ____
        / //_/____ __________ _/ __/
       / ,<  / __ `/ ___/ __ `/ /_
      / /| |/ /_/ / /  / /_/ / __/
     /_/ |_|\__,_/_/   \__,_/_/

   Apache Karaf (4.0.4)

Hit '<tab>' for a list of available commands
and '[cmd] --help' for help on a specific command.
Hit 'system:shutdown' to shutdown Karaf.
Hit '<ctrl-d>' or type 'logout' to disconnect shell from current session.

karaf@root()>


Regards
JB

On 03/04/2016 05:54 PM, Jason Reilly wrote:
> $ java -version
> java version "1.8.0_45"
> Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
> Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
>
>
> How do I check which JCE I am using?
>
>
> On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
>> Hi Jason,
>>
>> which JCE/JDK are you using (provider and version) ?
>>
>> Thanks,
>> Regards
>> JB
>>
>> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>>> Hi all,
>>>
>>> I am seeing an exception in the log when I try the following:
>>>
>>> $ ssh -p 8101 -l karaf localhost
>>>
>>> Connection reset by 127.0.0.1
>>>
>>>
>>>  From the karaf.log file:
>>>
>>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>>> ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 |
>>> Exception caught
>>>
>>> java.security.InvalidAlgorithmParameterException: parameter object not a
>>> ECParameterSpec
>>>
>>>      at
>>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown
>>> Source)
>>>
>>>      at
>>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>>
>>>      at
>>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0]
>>>
>>>
>>> ....
>>>
>>>
>>> This is from a custom distribution of Karaf....when I try the same with
>>> a clean Karaf4 instance, I do not encounter this issue & am able to
>>> login successfully.  I figured it must be one of the etc/*.cfg files I
>>> messed up that's included in the custom distribution.  However, when I
>>> remove all the custom distribution's etc files, I still encounter the
>>> login problem.  Is there something else I can try?
>>>
>>> Thanks
>>> Jason
>>
>

-- 
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com

Re: ssh access to Karaf 4.0.4

Posted by Jason Reilly <jd...@renci.org>.
$ java -version
java version "1.8.0_45"
Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)


How do I check which JCE I am using?


On 03/04/2016 11:52 AM, Jean-Baptiste Onofré wrote:
> Hi Jason,
>
> which JCE/JDK are you using (provider and version) ?
>
> Thanks,
> Regards
> JB
>
> On 03/04/2016 05:48 PM, Jason Reilly wrote:
>> Hi all,
>>
>> I am seeing an exception in the log when I try the following:
>>
>> $ ssh -p 8101 -l karaf localhost
>>
>> Connection reset by 127.0.0.1
>>
>>
>>  From the karaf.log file:
>>
>> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
>> ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 |
>> Exception caught
>>
>> java.security.InvalidAlgorithmParameterException: parameter object not a
>> ECParameterSpec
>>
>>      at
>> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown
>> Source)
>>
>>      at
>> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45] 
>>
>>
>>
>>      at
>> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>>
>>      at
>> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>>
>>      at
>> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>>
>>      at
>> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>>
>>      at
>> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>>
>>      at
>> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0] 
>>
>>
>> ....
>>
>>
>> This is from a custom distribution of Karaf....when I try the same with
>> a clean Karaf4 instance, I do not encounter this issue & am able to
>> login successfully.  I figured it must be one of the etc/*.cfg files I
>> messed up that's included in the custom distribution.  However, when I
>> remove all the custom distribution's etc files, I still encounter the
>> login problem.  Is there something else I can try?
>>
>> Thanks
>> Jason
>


Re: ssh access to Karaf 4.0.4

Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Hi Jason,

which JCE/JDK are you using (provider and version) ?

Thanks,
Regards
JB

On 03/04/2016 05:48 PM, Jason Reilly wrote:
> Hi all,
>
> I am seeing an exception in the log when I try the following:
>
> $ ssh -p 8101 -l karaf localhost
>
> Connection reset by 127.0.0.1
>
>
>  From the karaf.log file:
>
> 2016-03-04 11:12:27,501 | WARN  | f]-nio2-thread-1 |
> ServerSession                    | 5 - org.apache.sshd.core - 0.14.0 |
> Exception caught
>
> java.security.InvalidAlgorithmParameterException: parameter object not a
> ECParameterSpec
>
>      at
> org.bouncycastle.jce.provider.JDKKeyPairGenerator$EC.initialize(Unknown
> Source)
>
>      at
> java.security.KeyPairGenerator.initialize(KeyPairGenerator.java:411)[:1.8.0_45]
>
>
>      at
> org.apache.sshd.common.kex.ECDH.getE(ECDH.java:58)[5:org.apache.sshd.core:0.14.0]
>
>
>      at
> org.apache.sshd.server.kex.AbstractDHGServer.init(AbstractDHGServer.java:71)[5:org.apache.sshd.core:0.14.0]
>
>
>      at
> org.apache.sshd.common.session.AbstractSession.doHandleMessage(AbstractSession.java:390)[5:org.apache.sshd.core:0.14.0]
>
>
>      at
> org.apache.sshd.common.session.AbstractSession.handleMessage(AbstractSession.java:326)[5:org.apache.sshd.core:0.14.0]
>
>
>      at
> org.apache.sshd.common.session.AbstractSession.decode(AbstractSession.java:780)[5:org.apache.sshd.core:0.14.0]
>
>
>      at
> org.apache.sshd.common.session.AbstractSession.messageReceived(AbstractSession.java:308)[5:org.apache.sshd.core:0.14.0]
>
> ....
>
>
> This is from a custom distribution of Karaf....when I try the same with
> a clean Karaf4 instance, I do not encounter this issue & am able to
> login successfully.  I figured it must be one of the etc/*.cfg files I
> messed up that's included in the custom distribution.  However, when I
> remove all the custom distribution's etc files, I still encounter the
> login problem.  Is there something else I can try?
>
> Thanks
> Jason

-- 
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com