cherrypicker 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +1 -1
- data/lib/cherrypicker/download.rb +1 -1
- data/lib/cherrypicker/plugins/megavideo.rb +42 -42
- data/lib/cherrypicker/version.rb +1 -1
- metadata +2 -2
data/README.md
CHANGED
@@ -2,7 +2,7 @@ Cherrypicker
|
|
2
2
|
=========
|
3
3
|
|
4
4
|
Cherrypicker was part of my final year project for university it
|
5
|
-
is a Ruby Gem that lets you download from; Rapidshare, Hotfile, Youtube
|
5
|
+
is a Ruby Gem that lets you download from; Rapidshare, Hotfile, Hotfile, Youtube, Vimeo & Megavideo
|
6
6
|
You can also utilise the LinkChecker to see if your files are
|
7
7
|
alive on Rapidshare and Hotfile
|
8
8
|
|
@@ -37,56 +37,56 @@ class Megavideo
|
|
37
37
|
|
38
38
|
def decrypt(un,k1,k2) #credit http://userscripts.org/scripts/review/42944
|
39
39
|
k1 = k1.to_i
|
40
|
-
|
40
|
+
k2 = k2.to_i
|
41
41
|
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
42
|
+
#convert the hex "un" to binary
|
43
|
+
location1 = Array.new
|
44
|
+
un.each_char do |char|
|
45
|
+
#puts "#{char} => #{char.to_i(16).to_s(2)}"
|
46
|
+
location1 << ("000" + char.to_i(16).to_s(2))[-4,4]
|
47
|
+
end
|
48
48
|
|
49
|
-
|
49
|
+
location1 = location1.join("").split("")
|
50
50
|
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
end
|
57
|
-
|
58
|
-
location3 = Array.new
|
59
|
-
location4 = Array.new
|
60
|
-
location5 = Array.new
|
61
|
-
location8 = Array.new
|
62
|
-
|
63
|
-
256.downto(0) do |n|
|
64
|
-
location5 = location6[n]
|
65
|
-
location4 = n % 128
|
66
|
-
location8 = location1[location5]
|
67
|
-
location1[location5] = location1[location4]
|
68
|
-
location1[location4] = location8
|
51
|
+
location6 = Array.new
|
52
|
+
0.upto(383) do |n|
|
53
|
+
k1 = (k1 * 11 + 77213) % 81371
|
54
|
+
k2 = (k2 * 17 + 92717) % 192811
|
55
|
+
location6[n] = (k1 + k2) % 128
|
69
56
|
end
|
70
57
|
|
71
|
-
|
72
|
-
|
73
|
-
|
58
|
+
location3 = Array.new
|
59
|
+
location4 = Array.new
|
60
|
+
location5 = Array.new
|
61
|
+
location8 = Array.new
|
62
|
+
|
63
|
+
256.downto(0) do |n|
|
64
|
+
location5 = location6[n]
|
65
|
+
location4 = n % 128
|
66
|
+
location8 = location1[location5]
|
67
|
+
location1[location5] = location1[location4]
|
68
|
+
location1[location4] = location8
|
69
|
+
end
|
74
70
|
|
75
|
-
|
76
|
-
|
71
|
+
0.upto(127) do |n|
|
72
|
+
location1[n] = location1[n].to_i ^ location6[n+256] & 1
|
73
|
+
end
|
77
74
|
|
78
|
-
|
79
|
-
|
80
|
-
location9 = location12[n,4]
|
81
|
-
location7 << location9
|
82
|
-
n+=4
|
83
|
-
end
|
75
|
+
location12 = location1.join("")
|
76
|
+
location7 = Array.new
|
84
77
|
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
78
|
+
n = 0
|
79
|
+
while (n < location12.length) do
|
80
|
+
location9 = location12[n,4]
|
81
|
+
location7 << location9
|
82
|
+
n+=4
|
83
|
+
end
|
84
|
+
|
85
|
+
result = ""
|
86
|
+
location7.each do |bin|
|
87
|
+
result = result + bin.to_i(2).to_s(16)
|
88
|
+
end
|
89
|
+
result
|
90
90
|
end
|
91
91
|
|
92
92
|
def download
|
data/lib/cherrypicker/version.rb
CHANGED
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: cherrypicker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.3.
|
5
|
+
version: 0.3.2
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Karl Entwistle
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-04-
|
13
|
+
date: 2011-04-22 00:00:00 +01:00
|
14
14
|
default_executable:
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|