-
Notifications
You must be signed in to change notification settings - Fork 0
/
ivro_check
executable file
·58 lines (38 loc) · 1.27 KB
/
ivro_check
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#!/usr/bin/env ruby
puts "Ivro_check - Checks urls form library \n"
puts "by IvRR!mUm. \n"
print 'Please enter link you want to check: '
Link = gets.chomp
@sublink = ["/inc", "/include", "/includes", "/sys", "/admin", "/admin_panel", "/acp", "/cp", "/inc/admin", "/inc/admicp", "/inc/acp", "/inc/cp",
"/include/admin", "/include/admincp", "/inc/admin_panel", "/include/admin_panel", "/includes/admin", "/includes/admincp", "/assets", "/css", "/img",
"/images", "/style", "/css", "/js", "/Javascript", "/Fpoll", "Fpoll/admincp", "/Fpoll/admincp/install.php", "administrator", "labot", "mainit", "administracija", "special"]
if File.file?(Link + ".log")
File.delete(Link + ".log")
end
@sublink.each do |s|
%x(wget --no-cache --spider --append-output="#{Link}.log" "#{Link + s }")
end
%x( chmod 777 "#{Link}.log" )
@alllines = []
@repo = []
@fort = []
@line = 0
File.open(Link + ".log").each_line do |line|
@line += 1
@alllines.push(line)
if line.include?("301")
@repo.push(@line)
end
if line.include?("403")
@fort.push(@line)
end
end
@repo.each do |ll|
num = ll # 13
puts "[ 301 - Link have been Found ] " + @alllines[num]
end
@fort.each do |ll|
num = ll - 5 # 13
puts "[ 403 - Link is found, but is forbidden ] " + @alllines[num]
end
File.delete(Link + ".log")