Is it safe to use ssh keys generated inside of Docker as “fake” SSH keys?How do I remove the passphrase for the SSH key without having to create a new key?Best way to use multiple SSH private keys on one clientHow to specify the private SSH-key to use when executing shell command on Git?Using SSH keys inside docker containerFrom inside of a Docker container, how do I connect to the localhost of the machine?Trouble setting up SSH keysHow to ssh to a docker container on ec2 ubuntu host from outside machineHow to use ssh key inside docker containerssh-add in a docker containerPermission denied error after adding SSH Key to Digital Ocean

Am I legally required to provide a (GPL licensed) source code even after a project is abandoned?

What is that ceiling compartment of a Boeing 737?

How can I improve my violin intonation for enharmonic notes?

How can I take pictures like these examples with a yellowish tone and point & shoot film camera look?

One to Eleven Sum to Twenty Five

I found a password with hashcat but it doesn't work

In Street Fighter, what does the M stand for in M Bison?

Do details of my undergraduate title matter?

Why is Havana covered in 5-digit numbers in Our Man in Havana?

How much steel armor can you wear and still be able to swim?

How to write a nice frame challenge?

Counterfeit checks were created for my account. How does this type of fraud work?

Boundaries and Buddhism

Definition of 'vrit'

Why do you need to heat the pan before heating the olive oil?

Predict the product from the reaction

Math symbols in math operators

In the US, can a former president run again?

In a list with unique pairs A, B, how can I sort them so that the last B is the first A in the next pair?

What mathematical theory is required for high frequency trading?

Is Newton's third law really correct?

Got a new frameset, don't know why I need this split ring collar?

How would one carboxylate CBG into it's acid form, CBGA?

Kelvin type connection



Is it safe to use ssh keys generated inside of Docker as “fake” SSH keys?


How do I remove the passphrase for the SSH key without having to create a new key?Best way to use multiple SSH private keys on one clientHow to specify the private SSH-key to use when executing shell command on Git?Using SSH keys inside docker containerFrom inside of a Docker container, how do I connect to the localhost of the machine?Trouble setting up SSH keysHow to ssh to a docker container on ec2 ubuntu host from outside machineHow to use ssh key inside docker containerssh-add in a docker containerPermission denied error after adding SSH Key to Digital Ocean






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















I wanted simply to succeed a private key parser, and I just created ssh keys with ssh-keygen inside of a Docker container:



docker run -it --rm circleci/node:11
# Inside of docker
ssh-keygen
# Accepted default values
cat ~/.ssh/id_rsa
# And copied and used this value


Do these new keys contain any information about my machine (Outside of Docker)?



Is it dangerous if I share the content of that id_rsa?



I do not really need that the ssh key I use for my tests are functional, just that it complies with the private key parser.










share|improve this question




























    1















    I wanted simply to succeed a private key parser, and I just created ssh keys with ssh-keygen inside of a Docker container:



    docker run -it --rm circleci/node:11
    # Inside of docker
    ssh-keygen
    # Accepted default values
    cat ~/.ssh/id_rsa
    # And copied and used this value


    Do these new keys contain any information about my machine (Outside of Docker)?



    Is it dangerous if I share the content of that id_rsa?



    I do not really need that the ssh key I use for my tests are functional, just that it complies with the private key parser.










    share|improve this question
























      1












      1








      1


      0






      I wanted simply to succeed a private key parser, and I just created ssh keys with ssh-keygen inside of a Docker container:



      docker run -it --rm circleci/node:11
      # Inside of docker
      ssh-keygen
      # Accepted default values
      cat ~/.ssh/id_rsa
      # And copied and used this value


      Do these new keys contain any information about my machine (Outside of Docker)?



      Is it dangerous if I share the content of that id_rsa?



      I do not really need that the ssh key I use for my tests are functional, just that it complies with the private key parser.










      share|improve this question














      I wanted simply to succeed a private key parser, and I just created ssh keys with ssh-keygen inside of a Docker container:



      docker run -it --rm circleci/node:11
      # Inside of docker
      ssh-keygen
      # Accepted default values
      cat ~/.ssh/id_rsa
      # And copied and used this value


      Do these new keys contain any information about my machine (Outside of Docker)?



      Is it dangerous if I share the content of that id_rsa?



      I do not really need that the ssh key I use for my tests are functional, just that it complies with the private key parser.







      docker ssh






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 25 at 5:57









      Camilo SampedroCamilo Sampedro

      375619




      375619






















          1 Answer
          1






          active

          oldest

          votes


















          1














          I would argue that it's a dangerous practice in general, but as you've described the problem, the specific instance won't cause security issues.



          An ssh RSA key is "just" a couple of numbers plus a comment string. (In much the same way that a physical house key is "just" a chunk of metal with some grooves and notches cut in it.) If you generated an RSA key pair, discarded the public key, and published the private key, it wouldn't be intrinsically dangerous, since that private key doesn't technically authenticate you to anything.



          Still, if you're in the habit of publishing ssh private keys, it opens the possibility that at some point you'll publish a "real" key in your "normal" process, and that would be bad. I'd suggest that's not actually a best practice and you should treat every private key as though it had root permissions on your servers.



          (This has nothing at all to do with Docker, except that if you ssh-keygen inside a container, it will usually live in the container-private filesystem and it will be a little harder to leak.)






          share|improve this answer























            Your Answer






            StackExchange.ifUsing("editor", function ()
            StackExchange.using("externalEditor", function ()
            StackExchange.using("snippets", function ()
            StackExchange.snippets.init();
            );
            );
            , "code-snippets");

            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "1"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55331958%2fis-it-safe-to-use-ssh-keys-generated-inside-of-docker-as-fake-ssh-keys%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            1














            I would argue that it's a dangerous practice in general, but as you've described the problem, the specific instance won't cause security issues.



            An ssh RSA key is "just" a couple of numbers plus a comment string. (In much the same way that a physical house key is "just" a chunk of metal with some grooves and notches cut in it.) If you generated an RSA key pair, discarded the public key, and published the private key, it wouldn't be intrinsically dangerous, since that private key doesn't technically authenticate you to anything.



            Still, if you're in the habit of publishing ssh private keys, it opens the possibility that at some point you'll publish a "real" key in your "normal" process, and that would be bad. I'd suggest that's not actually a best practice and you should treat every private key as though it had root permissions on your servers.



            (This has nothing at all to do with Docker, except that if you ssh-keygen inside a container, it will usually live in the container-private filesystem and it will be a little harder to leak.)






            share|improve this answer



























              1














              I would argue that it's a dangerous practice in general, but as you've described the problem, the specific instance won't cause security issues.



              An ssh RSA key is "just" a couple of numbers plus a comment string. (In much the same way that a physical house key is "just" a chunk of metal with some grooves and notches cut in it.) If you generated an RSA key pair, discarded the public key, and published the private key, it wouldn't be intrinsically dangerous, since that private key doesn't technically authenticate you to anything.



              Still, if you're in the habit of publishing ssh private keys, it opens the possibility that at some point you'll publish a "real" key in your "normal" process, and that would be bad. I'd suggest that's not actually a best practice and you should treat every private key as though it had root permissions on your servers.



              (This has nothing at all to do with Docker, except that if you ssh-keygen inside a container, it will usually live in the container-private filesystem and it will be a little harder to leak.)






              share|improve this answer

























                1












                1








                1







                I would argue that it's a dangerous practice in general, but as you've described the problem, the specific instance won't cause security issues.



                An ssh RSA key is "just" a couple of numbers plus a comment string. (In much the same way that a physical house key is "just" a chunk of metal with some grooves and notches cut in it.) If you generated an RSA key pair, discarded the public key, and published the private key, it wouldn't be intrinsically dangerous, since that private key doesn't technically authenticate you to anything.



                Still, if you're in the habit of publishing ssh private keys, it opens the possibility that at some point you'll publish a "real" key in your "normal" process, and that would be bad. I'd suggest that's not actually a best practice and you should treat every private key as though it had root permissions on your servers.



                (This has nothing at all to do with Docker, except that if you ssh-keygen inside a container, it will usually live in the container-private filesystem and it will be a little harder to leak.)






                share|improve this answer













                I would argue that it's a dangerous practice in general, but as you've described the problem, the specific instance won't cause security issues.



                An ssh RSA key is "just" a couple of numbers plus a comment string. (In much the same way that a physical house key is "just" a chunk of metal with some grooves and notches cut in it.) If you generated an RSA key pair, discarded the public key, and published the private key, it wouldn't be intrinsically dangerous, since that private key doesn't technically authenticate you to anything.



                Still, if you're in the habit of publishing ssh private keys, it opens the possibility that at some point you'll publish a "real" key in your "normal" process, and that would be bad. I'd suggest that's not actually a best practice and you should treat every private key as though it had root permissions on your servers.



                (This has nothing at all to do with Docker, except that if you ssh-keygen inside a container, it will usually live in the container-private filesystem and it will be a little harder to leak.)







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Mar 25 at 11:09









                David MazeDavid Maze

                19.4k31733




                19.4k31733





























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55331958%2fis-it-safe-to-use-ssh-keys-generated-inside-of-docker-as-fake-ssh-keys%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

                    SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

                    은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현