gflare 0.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +7 -0
  2. data/bin/gflare +4 -0
  3. data/lib/gflare.rb +80 -0
  4. metadata +46 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 4e60b31f4b46f8d5b7115c8f12ac51333aa68d01
4
+ data.tar.gz: 964a18cb7f2c334ce9bde8d17246195efa2c575b
5
+ SHA512:
6
+ metadata.gz: 208895feb4d4fb8fc9a190a29fbce14cee36bf1d4a1c7b454660a743529f117441297782c82d43abae400d99f48fa1384066a8796b9eeab2765046c172b6d730
7
+ data.tar.gz: 5c31e679dbdc186b038cc978e9ead67a96cd1a0d138e9c8bbd821cc5966d3870c4edc69b003240dc753d2a9857a8b428ed6a7ba5af558b27446a4ebed761f23c
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'gflare'
4
+ puts Gflare.bypass(ARGV[0])
@@ -0,0 +1,80 @@
1
+ require 'net/http'
2
+ require 'open-uri'
3
+ require 'json'
4
+ require 'socket'
5
+
6
+ class Gflare
7
+
8
+ def self.red()
9
+ red = "\033[01;31m"
10
+ end
11
+ def self.green()
12
+ green = "\033[01;32m"
13
+ end
14
+ def self.yellow()
15
+ yellow = "\033[01;33m"
16
+ end
17
+ def self.white()
18
+ white = "\033[01;37m"
19
+ end
20
+
21
+ def self.banner()
22
+ puts "\n"
23
+ puts " ▄████ █████▒██▓ ▄▄▄ ██▀███ ▓█████ "
24
+ puts " ██▒ ▀█▒▓██ ▒▓██▒ ▒████▄ ▓██ ▒ ██▒▓█ ▀ "
25
+ puts " ▒██░▄▄▄░▒████ ░▒██░ ▒██ ▀█▄ ▓██ ░▄█ ▒▒███ "
26
+ puts " ░▓█ ██▓░▓█▒ ░▒██░ ░██▄▄▄▄██ ▒██▀▀█▄ ▒▓█ ▄ "
27
+ puts " ░▒▓███▀▒░▒█░ ░██████▒▓█ ▓██▒░██▓ ▒██▒░▒████▒"
28
+ puts " ░▒ ▒ ▒░ ░ ▒░▓ ░▒▒ ▓▒█░░ ▒▓ ░▒▓░░░ ▒░ ░"
29
+ puts " ░ ░ ░ ░ ░ ▒ ░ ▒ ▒▒ ░ ░▒ ░ ▒░ ░ ░ ░"
30
+ puts " ░ ░ ░ ░ ░ ░ ░ ░ ▒ ░░ ░ ░ "
31
+ puts " ░ ░ ░ ░ ░ ░ ░ ░"
32
+ puts "#{yellow}\nTool for identifying real IP of CloudFlare protected websites."
33
+ puts "#{yellow}\n--------------------- chankruze ---------------------"
34
+ puts "\n"
35
+ end
36
+
37
+ def self.bypass(target_url)
38
+ @target_url = target_url
39
+ system "clear"
40
+ banner()
41
+ if target_url == nil
42
+ puts "\n#{green}Usage : gflare www.example.com"
43
+ else
44
+ puts "#{green}**CHECKING TARGET ADDRESS - STAND BY**"
45
+ option = target_url
46
+ payload = URI ("http://www.crimeflare.org:82/cgi-bin/cfsearch.cgi")
47
+ request = Net::HTTP.post_form(payload, 'cfS' => target_url)
48
+ response = request.body
49
+ nscheck = /No working nameservers are registered/.match(response)
50
+ if( !nscheck.nil? )
51
+ puts "[✘] No valid address - are you sure this is a CloudFlare protected domain?\n"
52
+ exit
53
+ end
54
+
55
+ red = "\033[01;31m"
56
+ regex = /(\d*\.\d*\.\d*\.\d*)/.match(response)
57
+ if( regex.nil? || regex == "" )
58
+ puts "#{red}[✘] No valid address - are you sure this is a CloudFlare protected domain?\n"
59
+ puts "[✘] Alternately,Try it by hand.\n"
60
+ exit
61
+ end
62
+
63
+ ip_real = IPSocket.getaddress (target_url)
64
+ puts "\n"
65
+ puts "#{yellow}[✔] Target : #{option}"
66
+ puts "[✔] CloudFlare IP : #{ip_real}"
67
+ puts "[✔] Real IP : #{regex}"
68
+ target = "http://ipinfo.io/#{regex}/json"
69
+ url = URI(target).read
70
+ json = JSON.parse(url)
71
+ puts "[✔] Hostname : " + json['hostname']
72
+ puts "[✔] City : " + json['city']
73
+ puts "[✔] Region : " + json['country']
74
+ puts "[✔] Location : " + json['loc']
75
+ puts "[✔] Organization : " + json['org']
76
+ puts "\n"
77
+ puts "#{red}\n----------- https://github.com/chankruze -----------"
78
+ end
79
+ end
80
+ end
metadata ADDED
@@ -0,0 +1,46 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: gflare
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.0
5
+ platform: ruby
6
+ authors:
7
+ - chankruze
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2018-11-28 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: A tool to bypass cloudflare proxy and reveal the real IP
14
+ email: chankruze@gmail.com
15
+ executables:
16
+ - gflare
17
+ extensions: []
18
+ extra_rdoc_files: []
19
+ files:
20
+ - bin/gflare
21
+ - lib/gflare.rb
22
+ homepage: http://rubygems.org/gems/gflare
23
+ licenses:
24
+ - MIT
25
+ metadata: {}
26
+ post_install_message:
27
+ rdoc_options: []
28
+ require_paths:
29
+ - lib
30
+ required_ruby_version: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: '0'
35
+ required_rubygems_version: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
40
+ requirements: []
41
+ rubyforge_project:
42
+ rubygems_version: 2.5.1
43
+ signing_key:
44
+ specification_version: 4
45
+ summary: Bypass cloudflare proxy
46
+ test_files: []