class Ronin::CLI::Commands::Homoglyph

Generates homoglyph equivalent words.

## Usage

ronin homoglyph [options] [WORD ...]

## Options

-f, --file FILE                  Optional file to process
-C ascii|greek|cyrillic|punctuation|latin_numbers|full_width,
    --char-set                   Selects the homoglyph character set
-E, --enum                       Enumerates over every possible typo of a word
-h, --help                       Print help information

## Arguments

[WORD ...]                       Optional word(s) to homoglyph

Public Instance Methods

process_value(word) click to toggle source

Processes each word.

@param [String] word

A word argument to homoglyph.
# File lib/ronin/cli/commands/homoglyph.rb, line 85
def process_value(word)
  if options[:enum]
    @table.each_substitution(word) do |homoglyphed_word|
      puts homoglyphed_word
    end
  else
    puts @table.substitute(word)
  end
end
run(*words) click to toggle source

Runs the ‘ronin homoglyph` command.

@param [Array<String>] words

The words to homoglyph.
Calls superclass method
# File lib/ronin/cli/commands/homoglyph.rb, line 73
def run(*words)
  @table = Support::Text::Homoglyph.table(options[:char_set])

  super(*words)
end