Uploaded image for project: 'MINA SSHD'
  1. MINA SSHD
  2. SSHD-763

Add support for reading ECDSA PUTTY key files

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.7.0
    • 1.7.0

    Description

      See if can use Ruby code example - specifically the openssl.rb part:

      when /\Aecdsa-sha2-(nistp(?:256|384|521))\z/
                  curve = OPENSSL_CURVES[$1]
      
                  # jruby-openssl doesn't include an EC class (version 0.9.16)
                  ec_class = (::OpenSSL::PKey::EC rescue raise ArgumentError, "Unsupported algorithm: #{ppk.algorithm}")
      
                  ec_class.new(curve).tap do |pkey|
                    _, _, point = Util.ssh_unpack(ppk.public_blob, :string, :string, :mpint)
                    pkey.public_key = ::OpenSSL::PKey::EC::Point.new(pkey.group, point)
                    pkey.private_key = Util.ssh_unpack(ppk.private_blob, :mpint).first
                  end
      

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            lgoldstein Lyor Goldstein
            lgoldstein Lyor Goldstein
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 4h
                4h
                Remaining:
                Remaining Estimate - 4h
                4h
                Logged:
                Time Spent - Not Specified
                Not Specified

                Slack

                  Issue deployment