lib/test_crack_sha256.rb
#-------------------------------------------------------------------------------------#
# expensive: run sha256 on 1 million possible combos
run sha256 on 1 million possible combos
run sha256 on 1 million possible combos
def brute_worker(options)
    options[:combo].each do |x| 
      return options.merge({ valid: x }) if Digest::SHA256.hexdigest(x.to_s) == @target
    end
    options
  end
def brute_worker ( options ) options [ :combo ] . each do | x | return options . merge ( { valid : x } ) if Digest :: SHA256 . hexdigest ( x . to_s ) == @target end options end
expensive: run sha256 on 1 million possible combos
expensive : run sha256 on 1 million possible combos
options