class CoBreak::BruteChars

Public Class Methods

new(options) click to toggle source
# File lib/cobreak/force_chars.rb, line 6
def initialize(options)
  @options = options
  @hash = %w[MD4 MD5 SHA1 SHA224 SHA256 SHA384 SHA512 RIPEMD160]
end

Public Instance Methods

banner_chars() click to toggle source
chars() click to toggle source
# File lib/cobreak/force_chars.rb, line 36
    def chars()
#      if (@options.range.empty?) or (@options.chars.nil?) or (@param.algo.nil?)
#         abort "\n"
#      end
      if (@hash.include?(@options.bruteforce.upcase))
        if (File.exists?(@options.algo.to_s))
          IO.foreach(@options.algo){|line|
            line.chomp!
            ForzeBrute::chars(line, @options.range, @options.chars, @options.bruteforce, @options.out, @options.verbose)
          }
        else
          if (@hash.include?(@options.bruteforce.upcase))
            ForzeBrute::chars(@options.algo, @options.range, @options.chars, @options.bruteforce, @options.out, @options.verbose)
          end
        end
      end
    end