threefoldtecharchive / jumpscaleX_archived

Apache License 2.0
1 stars 6 forks source link

config manger loads id_rsa by default and doesn't accept any other key #469

Closed 0xIslamTaha closed 5 years ago

0xIslamTaha commented 5 years ago

I tried to use id_new in kosmos but it loads id_rsa and doesn't accept another key

3BOTDEVEL:6f00b189d165:/: ssh-add -l
2048 SHA256:ZX9GbnPhBdq/yyjx8FR1ztKLa/hxTJjZdlfE2Ka4WcE /root/.ssh/id_new (RSA)
3BOTDEVEL:6f00b189d165:/: kosmos 
do you want to use ssh-agent for secret key in jumpscale? [y/n]: y
Ok to generate private key (Y or 1 for yes, otherwise provide words)? [y/n]: y
We have generated a private key for you.
The private key:
## There is an issue in the Jumpscale encryption layer. ##
could not find secret key from sshagent, ssh-agent not active, if active need 1 ssh key loaded!
3BOTDEVEL:6f00b189d165:/: ssh-add -l
2048 SHA256:ZX9GbnPhBdq/yyjx8FR1ztKLa/hxTJjZdlfE2Ka4WcE /root/.ssh/id_new (RSA)
2048 SHA256:W4+wtxtKXrY1suQzGwNAOrxTbGs8H7Bhgpz24ypiQZU /root/.ssh/id_rsa (RSA)
3BOTDEVEL:6f00b189d165:/: 

branch development

AhmedHanafy725 commented 5 years ago

branch: development commit: b1b16a20bc7d16aef87c65f2f86f19c1b067ed2a

3BOTDEVEL:57e8e0ac844f:jumpscaleX: ssh-add -l 
2048 SHA256:exK6LTokBNAeRwj4AcUpJ/f/7C//DGUt5asV8atl908 /root/.ssh/id_new (RSA)
3BOTDEVEL:57e8e0ac844f:jumpscaleX: kosmos 
do you want to use ssh-agent for secret key in jumpscale? [y/n]: y
Ok to generate private key (Y or 1 for yes, otherwise provide words)? [y/n]: y
We have generated a private key for you.
The private key:

stem cool valley reduce round jacket slam estate dream tone essay lens clean news media give hello cook catalog bonus valley dream afraid regret
ITS IMPORTANT TO STORE THIS KEY IN A SAFE PLACE
Did you write the words down and store them in safe place? [y/n]: y

give the 3e word of the private key string: valley
Tue 28 06:50:46 BCDB.py          - 104 - bcdb:bcdb                          : BCDB INIT DONE:system
JSX>                                                                                                 
3BOTDEVEL:57e8e0ac844f:jumpscaleX: ssh-add -l
2048 SHA256:exK6LTokBNAeRwj4AcUpJ/f/7C//DGUt5asV8atl908 /root/.ssh/id_new (RSA)

It loads id_new as expected. Verified