Code Monkey home page Code Monkey logo

Comments (2)

kkaiser avatar kkaiser commented on June 13, 2024 1

Thanks for your reply and clarifying this is an AWS issue.

Also all you said is fair :) I thought it was worth asking also it might be useful to others as well to post this question here if they are looking for it. I can see that the key gets converted. Before it will start with:
-----BEGIN RSA PRIVATE KEY-----
and after with:
-----BEGIN OPENSSH PRIVATE KEY-----

I do use the private key to connect. Like it says in the blogposts I think the error message is just misleading. Also this is not an error but just a warning the connection is fine.

Just for completeness sake my ssh client runs on Windows with MinGW OpenSSH_8.3p1 and ssh server is OpenSSH_8.2p1 on Ubuntu 20.04.1 LTS.

Maybe I will ask the AWS support about this but here I will close the issue. Cheers!

from cdk-ec2-key-pair.

udondan avatar udondan commented on June 13, 2024

Hi @kkaiser,

the KeyPair is generated by AWS via API. So if there is anything wrong it probably cannot and should not be fixed in this package. When you manually generate a PEM key in the AWS EC2 console, you should see the same exact thing.

ssh-keygen -f root_key.pem -p -y

From my understanding, this command will convert the PEM/RSA key to an RFC 4716/SSH2 key. Don't know why this would make a difference. Both keys are valid. But the "error" message also said that it attempted to load the key as a public key. Of course, then this will fail since it's a private key.

ssh is a bit stupid at times. Maybe it just understands the OpenSSH format better in that case and does not attempt to load it as a pub key. I don't know. But I also cannot reproduce that message here. The original keys don't cause any such message.

Cheers,
Daniel

from cdk-ec2-key-pair.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.