Sha256: 2048ff17c030457803a30e01faeb392023186cbadba81746a2524a3cccadc571

Contents?: true

Size: 464 Bytes

Versions: 48

Compression:

Stored size: 464 Bytes

Contents

#!/usr/bin/env ruby
# frozen_string_literal: true

require 'optparse'
require 'cgi'

opts = {}
OptionParser.new do |options|
  options.banner = "USAGE:
    #{File.basename($PROGRAM_NAME)} [opts]
  "

  options.on('-pSTRING', '--payload=STRING', '<Required - String to Encode>') do |p|
    opts[:payload] = p
  end
end.parse!

if opts.empty?
  puts `#{File.basename($PROGRAM_NAME)} --help`
  exit 1
end

payload = opts[:payload].to_s.scrub
puts CGI.escape(payload)

Version data entries

48 entries across 48 versions & 1 rubygems

Version Path
pwn-0.5.172 bin/pwn_char_url_encoding
pwn-0.5.171 bin/pwn_char_url_encoding
pwn-0.5.170 bin/pwn_char_url_encoding
pwn-0.5.169 bin/pwn_char_url_encoding
pwn-0.5.168 bin/pwn_char_url_encoding
pwn-0.5.167 bin/pwn_char_url_encoding
pwn-0.5.166 bin/pwn_char_url_encoding
pwn-0.5.165 bin/pwn_char_url_encoding