ruby/rubygems · error · Gem::Security::Exception

#{algorithm} algorithm not found. RSA, DSA, and EC algorithm

Error message

#{algorithm} algorithm not found. RSA, DSA, and EC algorithms are supported.

What it means

Error "#{algorithm} algorithm not found. RSA, DSA, and EC algorithms are supported." thrown in ruby/rubygems.

Source

Thrown at lib/rubygems/security.rb:480

  def self.create_digest(algorithm = DIGEST_NAME)
    OpenSSL::Digest.new(algorithm)
  end

  ##
  # Creates a new key pair of the specified +algorithm+. RSA, DSA, and EC
  # are supported.

  def self.create_key(algorithm)
    if defined?(OpenSSL::PKey)
      case algorithm.downcase
      when "dsa"
        OpenSSL::PKey::DSA.new(RSA_DSA_KEY_LENGTH)
      when "rsa"
        OpenSSL::PKey::RSA.new(RSA_DSA_KEY_LENGTH)
      when "ec"
        OpenSSL::PKey::EC.generate(EC_NAME)
      else
        raise Gem::Security::Exception,
        "#{algorithm} algorithm not found. RSA, DSA, and EC algorithms are supported."
      end
    end
  end

  ##
  # Turns +email_address+ into an OpenSSL::X509::Name

  def self.email_to_name(email_address)
    email_address = email_address.gsub(/[^\w@.-]+/i, "_")

    cn, dcs = email_address.split "@"

    dcs = dcs.split "."

    OpenSSL::X509::Name.new([
      ["CN", cn],
      *dcs.map {|dc| ["DC", dc] },

View on GitHub (pinned to 86cbb817a3)

Solutions

  1. Use an RSA, DSA, or EC key for signing; the reported algorithm is unsupported

When it happens

Trigger: Thrown at lib/rubygems/security.rb:480 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of ruby/rubygems@86cbb817a3 (2026-08-23). Data as JSON: /api/errors/a62aaf25b3ec8e65. Report an issue: GitHub.