pedump 0.5.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
metadata CHANGED
@@ -1,172 +1,65 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pedump
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
5
- prerelease:
4
+ version: 0.5.1
6
5
  platform: ruby
7
6
  authors:
8
7
  - Andrey "Zed" Zaikin
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-04-20 00:00:00.000000000 Z
11
+ date: 2016-09-09 00:00:00.000000000 Z
13
12
  dependencies:
14
- - !ruby/object:Gem::Dependency
15
- name: multipart-post
16
- requirement: !ruby/object:Gem::Requirement
17
- none: false
18
- requirements:
19
- - - ~>
20
- - !ruby/object:Gem::Version
21
- version: 1.1.4
22
- type: :runtime
23
- prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ~>
28
- - !ruby/object:Gem::Version
29
- version: 1.1.4
30
- - !ruby/object:Gem::Dependency
31
- name: progressbar
32
- requirement: !ruby/object:Gem::Requirement
33
- none: false
34
- requirements:
35
- - - ! '>='
36
- - !ruby/object:Gem::Version
37
- version: '0'
38
- type: :runtime
39
- prerelease: false
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ! '>='
44
- - !ruby/object:Gem::Version
45
- version: '0'
46
- - !ruby/object:Gem::Dependency
47
- name: awesome_print
48
- requirement: !ruby/object:Gem::Requirement
49
- none: false
50
- requirements:
51
- - - ! '>='
52
- - !ruby/object:Gem::Version
53
- version: '0'
54
- type: :runtime
55
- prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
- requirements:
59
- - - ! '>='
60
- - !ruby/object:Gem::Version
61
- version: '0'
62
- - !ruby/object:Gem::Dependency
63
- name: iostruct
64
- requirement: !ruby/object:Gem::Requirement
65
- none: false
66
- requirements:
67
- - - ! '>='
68
- - !ruby/object:Gem::Version
69
- version: 0.0.4
70
- type: :runtime
71
- prerelease: false
72
- version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
- requirements:
75
- - - ! '>='
76
- - !ruby/object:Gem::Version
77
- version: 0.0.4
78
- - !ruby/object:Gem::Dependency
79
- name: zhexdump
80
- requirement: !ruby/object:Gem::Requirement
81
- none: false
82
- requirements:
83
- - - ! '>='
84
- - !ruby/object:Gem::Version
85
- version: 0.0.2
86
- type: :runtime
87
- prerelease: false
88
- version_requirements: !ruby/object:Gem::Requirement
89
- none: false
90
- requirements:
91
- - - ! '>='
92
- - !ruby/object:Gem::Version
93
- version: 0.0.2
94
- - !ruby/object:Gem::Dependency
95
- name: rspec
96
- requirement: !ruby/object:Gem::Requirement
97
- none: false
98
- requirements:
99
- - - ! '>='
100
- - !ruby/object:Gem::Version
101
- version: '0'
102
- type: :development
103
- prerelease: false
104
- version_requirements: !ruby/object:Gem::Requirement
105
- none: false
106
- requirements:
107
- - - ! '>='
108
- - !ruby/object:Gem::Version
109
- version: '0'
110
13
  - !ruby/object:Gem::Dependency
111
14
  name: bundler
112
15
  requirement: !ruby/object:Gem::Requirement
113
- none: false
114
16
  requirements:
115
- - - ! '>='
17
+ - - "~>"
116
18
  - !ruby/object:Gem::Version
117
- version: '0'
19
+ version: '1.11'
118
20
  type: :development
119
21
  prerelease: false
120
22
  version_requirements: !ruby/object:Gem::Requirement
121
- none: false
122
23
  requirements:
123
- - - ! '>='
24
+ - - "~>"
124
25
  - !ruby/object:Gem::Version
125
- version: '0'
26
+ version: '1.11'
126
27
  - !ruby/object:Gem::Dependency
127
- name: jeweler
28
+ name: rake
128
29
  requirement: !ruby/object:Gem::Requirement
129
- none: false
130
30
  requirements:
131
- - - ! '>='
31
+ - - "~>"
132
32
  - !ruby/object:Gem::Version
133
- version: '0'
33
+ version: '10.0'
134
34
  type: :development
135
35
  prerelease: false
136
36
  version_requirements: !ruby/object:Gem::Requirement
137
- none: false
138
37
  requirements:
139
- - - ! '>='
38
+ - - "~>"
140
39
  - !ruby/object:Gem::Version
141
- version: '0'
40
+ version: '10.0'
142
41
  - !ruby/object:Gem::Dependency
143
- name: what_methods
42
+ name: rspec
144
43
  requirement: !ruby/object:Gem::Requirement
145
- none: false
146
44
  requirements:
147
- - - ! '>='
45
+ - - "~>"
148
46
  - !ruby/object:Gem::Version
149
- version: '0'
47
+ version: '3.0'
150
48
  type: :development
151
49
  prerelease: false
152
50
  version_requirements: !ruby/object:Gem::Requirement
153
- none: false
154
51
  requirements:
155
- - - ! '>='
52
+ - - "~>"
156
53
  - !ruby/object:Gem::Version
157
- version: '0'
54
+ version: '3.0'
158
55
  description: dump headers, sections, extract resources of win32 PE exe,dll,etc
159
- email: zed.0xff@gmail.com
56
+ email:
57
+ - zed.0xff@gmail.com
160
58
  executables:
161
59
  - pedump
162
60
  extensions: []
163
- extra_rdoc_files:
164
- - LICENSE.txt
165
- - README.md
61
+ extra_rdoc_files: []
166
62
  files:
167
- - .document
168
- - .rspec
169
- - .travis.yml
170
63
  - Gemfile
171
64
  - Gemfile.lock
172
65
  - LICENSE.txt
@@ -208,61 +101,28 @@ files:
208
101
  - misc/aspack/lzxdec.h
209
102
  - misc/nedump.c
210
103
  - pedump.gemspec
211
- - samples/bad/68.exe
212
- - samples/bad/data_dir_15_entries.exe
213
- - spec/65535sects_spec.rb
214
- - spec/bad_imports_spec.rb
215
- - spec/bad_samples_spec.rb
216
- - spec/composite_io_spec.rb
217
- - spec/data/calc.exe_sections.yml
218
- - spec/data/data_dir_15_entries.exe_sections.yml
219
- - spec/dllord_spec.rb
220
- - spec/foldedhdr_spec.rb
221
- - spec/imports_badterm_spec.rb
222
- - spec/imports_vterm_spec.rb
223
- - spec/loader/names_spec.rb
224
- - spec/loader/va_spec.rb
225
- - spec/manyimportsW7_spec.rb
226
- - spec/ne_spec.rb
227
- - spec/packer_spec.rb
228
- - spec/pe_spec.rb
229
- - spec/pedump_spec.rb
230
- - spec/resource_spec.rb
231
- - spec/sections_spec.rb
232
- - spec/sig_all_packers_spec.rb
233
- - spec/sig_spec.rb
234
- - spec/spec_helper.rb
235
- - spec/support/samples.rb
236
- - spec/unpackers/aspack_spec.rb
237
- - spec/unpackers/find_spec.rb
238
- - spec/virtsectblXP_spec.rb
239
- - tmp/.keep
240
104
  homepage: http://github.com/zed-0xff/pedump
241
105
  licenses:
242
106
  - MIT
107
+ metadata: {}
243
108
  post_install_message:
244
109
  rdoc_options: []
245
110
  require_paths:
246
111
  - lib
247
112
  required_ruby_version: !ruby/object:Gem::Requirement
248
- none: false
249
113
  requirements:
250
- - - ! '>='
114
+ - - ">="
251
115
  - !ruby/object:Gem::Version
252
116
  version: '0'
253
- segments:
254
- - 0
255
- hash: -1369606751108388991
256
117
  required_rubygems_version: !ruby/object:Gem::Requirement
257
- none: false
258
118
  requirements:
259
- - - ! '>='
119
+ - - ">="
260
120
  - !ruby/object:Gem::Version
261
121
  version: '0'
262
122
  requirements: []
263
123
  rubyforge_project:
264
- rubygems_version: 1.8.24
124
+ rubygems_version: 2.4.6
265
125
  signing_key:
266
- specification_version: 3
126
+ specification_version: 4
267
127
  summary: dump win32 PE executable files with a pure ruby
268
128
  test_files: []
data/.document DELETED
@@ -1,5 +0,0 @@
1
- lib/**/*.rb
2
- bin/*
3
- -
4
- features/**/*.feature
5
- LICENSE.txt
data/.rspec DELETED
@@ -1 +0,0 @@
1
- --color
@@ -1,4 +0,0 @@
1
- language: ruby
2
- before_install:
3
- - sudo apt-get update -qq
4
- - sudo apt-get install -qq upx-ucl p7zip
Binary file
@@ -1,8 +0,0 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
- require File.expand_path(File.dirname(__FILE__) + '/../lib/pedump')
3
-
4
- describe 'corkami/65535sects.exe' do
5
- it "should have 65535 sections" do
6
- sample.sections.size.should == 65535
7
- end
8
- end
@@ -1,20 +0,0 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
- require File.expand_path(File.dirname(__FILE__) + '/../lib/pedump')
3
-
4
- describe 'bad_imports.exe' do
5
- before :all do
6
- @imports = sample.imports
7
- end
8
-
9
- it "should have IMAGE_IMPORT_DESCRIPTOR" do
10
- @imports.size.should == 1
11
- end
12
-
13
- it "should have only IMAGE_IMPORT_DESCRIPTORs" do
14
- @imports.map(&:class).uniq.should == [PEdump::IMAGE_IMPORT_DESCRIPTOR]
15
- end
16
-
17
- it "should not detect packer" do
18
- sample.packer.should be_nil
19
- end
20
- end
@@ -1,13 +0,0 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
- require File.expand_path(File.dirname(__FILE__) + '/../lib/pedump')
3
-
4
- PEDUMP_BINARY = File.expand_path(File.dirname(__FILE__) + '/../bin/pedump')
5
-
6
- Dir[File.join(SAMPLES_DIR,"bad","*.exe")].each do |fname|
7
- describe fname do
8
- it "should not cause exception" do
9
- system "#{PEDUMP_BINARY} -qqq #{fname} > /dev/null"
10
- $?.should be_success
11
- end
12
- end
13
- end
@@ -1,122 +0,0 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
- require File.expand_path(File.dirname(__FILE__) + '/../lib/pedump/composite_io')
3
-
4
- describe PEdump::CompositeIO do
5
- it "concatenates" do
6
- io = PEdump::CompositeIO.new(
7
- StringIO.new('foo'),
8
- StringIO.new('bar'),
9
- StringIO.new('baz')
10
- )
11
- io.read.should == 'foobarbaz'
12
- end
13
-
14
- it "reads sequentally" do
15
- io = PEdump::CompositeIO.new(
16
- StringIO.new('foo1'),
17
- StringIO.new('bar2'),
18
- StringIO.new('baz')
19
- )
20
- io.read(3).should == 'foo'
21
- io.read(3).should == '1ba'
22
- io.read(3).should == 'r2b'
23
- io.read(3).should == 'az'
24
- end
25
-
26
- it "behaves like StringIO" do
27
- io1 = StringIO.new('foo')
28
- io2 = PEdump::CompositeIO.new(StringIO.new('foo'))
29
-
30
- io1.read.should == io2.read # 'foo'
31
- io1.read.should == io2.read # ''
32
- io1.read(3).should == io2.read(3) # nil
33
- end
34
-
35
- it "tracks number of bytes read" do
36
- io = PEdump::CompositeIO.new(
37
- StringIO.new('foo1'),
38
- StringIO.new('bar2'),
39
- StringIO.new('baz')
40
- )
41
- io.tell.should == 0
42
- io.read(3)
43
- io.tell.should == 3
44
- io.read(4)
45
- io.tell.should == 7
46
- io.read
47
- io.tell.should == 11
48
- io.read
49
- io.tell.should == 11
50
- io.read 10
51
- io.tell.should == 11
52
- end
53
-
54
- it "chains eof? call" do
55
- io = PEdump::CompositeIO.new(
56
- StringIO.new('foo1'),
57
- StringIO.new('bar2'),
58
- StringIO.new('baz')
59
- )
60
- io.eof?.should be_false
61
- io.read(3)
62
- io.eof?.should be_false
63
- io.read(4)
64
- io.eof?.should be_false
65
- io.read
66
- io.eof?.should be_true
67
- io.read
68
- io.eof?.should be_true
69
- io.read 10
70
- io.eof?.should be_true
71
- end
72
-
73
- it "seeks" do
74
- io = PEdump::CompositeIO.new(
75
- StringIO.new('foo1'),
76
- StringIO.new('bar2'),
77
- StringIO.new('baz')
78
- )
79
-
80
- io.seek(5)
81
- io.tell.should == 5
82
- io.read(4).should == "ar2b"
83
-
84
- io.seek(0)
85
- io.tell.should == 0
86
- io.read.should == "foo1bar2baz"
87
-
88
- io.seek(1)
89
- io.tell.should == 1
90
- io.read.should == "oo1bar2baz"
91
- end
92
-
93
- it "respects start positions" do
94
- ios = [
95
- StringIO.new('foo1'),
96
- StringIO.new('bar2'),
97
- StringIO.new('baz3')
98
- ]
99
- ios.each_with_index{ |io,idx| io.seek(idx+1) }
100
-
101
- s = "oo1r23"
102
-
103
- io = PEdump::CompositeIO.new(*ios)
104
- io.tell.should == 0
105
- io.read.should == s
106
-
107
- s.size.times do |pos|
108
- io.seek(pos)
109
- io.tell.should == pos
110
- io.read.should == s[pos..-1]
111
- end
112
- end
113
-
114
- it "summarizes size" do
115
- io = PEdump::CompositeIO.new(
116
- StringIO.new('foo1'),
117
- StringIO.new('bar2'),
118
- StringIO.new('baz')
119
- )
120
- io.size.should == 11
121
- end
122
- end
@@ -1,49 +0,0 @@
1
- ---
2
- - !ruby/struct:PEdump::IMAGE_SECTION_HEADER
3
- Name: !binary |-
4
- LnRleHQ=
5
- VirtualSize: 305562
6
- VirtualAddress: 4096
7
- SizeOfRawData: 305664
8
- PointerToRawData: 1024
9
- PointerToRelocations: 0
10
- PointerToLinenumbers: 0
11
- NumberOfRelocations: 0
12
- NumberOfLinenumbers: 0
13
- Characteristics: 1610612768
14
- - !ruby/struct:PEdump::IMAGE_SECTION_HEADER
15
- Name: !binary |-
16
- LmRhdGE=
17
- VirtualSize: 17180
18
- VirtualAddress: 311296
19
- SizeOfRawData: 12288
20
- PointerToRawData: 306688
21
- PointerToRelocations: 0
22
- PointerToLinenumbers: 0
23
- NumberOfRelocations: 0
24
- NumberOfLinenumbers: 0
25
- Characteristics: 3221225536
26
- - !ruby/struct:PEdump::IMAGE_SECTION_HEADER
27
- Name: !binary |-
28
- LnJzcmM=
29
- VirtualSize: 305927
30
- VirtualAddress: 331776
31
- SizeOfRawData: 306176
32
- PointerToRawData: 318976
33
- PointerToRelocations: 0
34
- PointerToLinenumbers: 0
35
- NumberOfRelocations: 0
36
- NumberOfLinenumbers: 0
37
- Characteristics: 1073741888
38
- - !ruby/struct:PEdump::IMAGE_SECTION_HEADER
39
- Name: !binary |-
40
- LnJlbG9j
41
- VirtualSize: 16886
42
- VirtualAddress: 638976
43
- SizeOfRawData: 16896
44
- PointerToRawData: 625152
45
- PointerToRelocations: 0
46
- PointerToLinenumbers: 0
47
- NumberOfRelocations: 0
48
- NumberOfLinenumbers: 0
49
- Characteristics: 1107296320