ipa_reader 0.5.1 → 0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. data/lib/ipa_reader/ipa_file.rb +23 -2
  2. data/test/Payload/MultiG.app/AccountTableViewCell.nib +0 -0
  3. data/test/Payload/MultiG.app/AddAccountView.nib +0 -0
  4. data/test/Payload/MultiG.app/AddAccountView_Phone.nib +0 -0
  5. data/test/Payload/MultiG.app/CodeResources +136 -0
  6. data/test/Payload/MultiG.app/Default-Landscape.png +0 -0
  7. data/test/Payload/MultiG.app/Default-Portrait.png +0 -0
  8. data/test/Payload/MultiG.app/Default.png +0 -0
  9. data/test/Payload/MultiG.app/ExternalWebView.nib +0 -0
  10. data/test/Payload/MultiG.app/ExternalWebView_Phone.nib +0 -0
  11. data/test/Payload/MultiG.app/GmailWebView.nib +0 -0
  12. data/test/Payload/MultiG.app/GmailWebView_Phone.nib +0 -0
  13. data/test/Payload/MultiG.app/Info.plist +0 -0
  14. data/test/Payload/MultiG.app/MainWindow_Pad.nib +0 -0
  15. data/test/Payload/MultiG.app/MainWindow_Phone.nib +0 -0
  16. data/test/Payload/MultiG.app/MultiG +0 -0
  17. data/test/Payload/MultiG.app/MultiMail.momd/MultiMail 2.mom +0 -0
  18. data/test/Payload/MultiG.app/MultiMail.momd/MultiMail 3.mom +0 -0
  19. data/test/Payload/MultiG.app/MultiMail.momd/MultiMail.mom +0 -0
  20. data/test/Payload/MultiG.app/MultiMail.momd/VersionInfo.plist +44 -0
  21. data/test/Payload/MultiG.app/PkgInfo +1 -0
  22. data/test/Payload/MultiG.app/ResourceRules.plist +25 -0
  23. data/test/Payload/MultiG.app/RootView.nib +0 -0
  24. data/test/Payload/MultiG.app/RootView_Phone.nib +0 -0
  25. data/test/Payload/MultiG.app/Settings.nib +0 -0
  26. data/test/Payload/MultiG.app/TableViewCellOnOff.nib +0 -0
  27. data/test/Payload/MultiG.app/_CodeSignature/CodeResources +136 -0
  28. data/test/Payload/MultiG.app/back_small.png +0 -0
  29. data/test/Payload/MultiG.app/dist.plist +0 -0
  30. data/test/Payload/MultiG.app/embedded.mobileprovision +0 -0
  31. data/test/Payload/MultiG.app/forward_small.png +0 -0
  32. data/test/Payload/MultiG.app/icon-ipad.png +0 -0
  33. data/test/Payload/MultiG.app/icon-iphone.png +0 -0
  34. data/test/Payload/MultiG.app/settings_small.png +0 -0
  35. data/version.txt +1 -1
  36. metadata +37 -5
@@ -6,11 +6,12 @@ rescue LoadError
6
6
  end
7
7
  module IpaReader
8
8
  class IpaFile
9
- attr_accessor :plist
9
+ attr_accessor :plist, :file_path
10
10
  def initialize(file_path)
11
+ self.file_path = file_path
11
12
  info_plist_file = nil
12
13
  Zip::ZipFile.foreach(file_path) { |f| info_plist_file = f if f.name.match(/\/Info.plist/) }
13
- self.plist = Plist::Binary.decode_binary_plist(info_plist_file.get_input_stream.read)
14
+ self.plist = Plist::Binary.decode_binary_plist(self.read_file(/\/Info.plist/))
14
15
  end
15
16
 
16
17
  def version
@@ -37,6 +38,20 @@ module IpaReader
37
38
  end
38
39
  end
39
40
 
41
+ def icon_file
42
+ if plist["CFBundleIconFile"]
43
+ read_file(Regexp.new("#{plist["CFBundleIconFile"]}$"))
44
+ elsif plist["CFBundleIconFiles"]
45
+ read_file(Regexp.new("#{plist["CFBundleIconFiles"][0]}$"))
46
+ else
47
+ nil
48
+ end
49
+ end
50
+
51
+ def mobile_provision_file
52
+ read_file(/embedded\.mobileprovision$/)
53
+ end
54
+
40
55
  def bundle_identifier
41
56
  plist["CFBundleIdentifier"]
42
57
  end
@@ -44,5 +59,11 @@ module IpaReader
44
59
  def icon_prerendered
45
60
  plist["UIPrerenderedIcon"] == true
46
61
  end
62
+
63
+ def read_file(regex)
64
+ file = nil
65
+ Zip::ZipFile.foreach(self.file_path) { |f| file = f if f.name.match(regex) }
66
+ file.get_input_stream.read
67
+ end
47
68
  end
48
69
  end
@@ -0,0 +1,136 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>files</key>
6
+ <dict>
7
+ <key>AccountTableViewCell.nib</key>
8
+ <data>
9
+ AyjJwvw8bbERsI4rmj/I5YduQJ4=
10
+ </data>
11
+ <key>AddAccountView.nib</key>
12
+ <data>
13
+ lL4dW5BBRh/yBzE9x1mnpFzZjHM=
14
+ </data>
15
+ <key>AddAccountView_Phone.nib</key>
16
+ <data>
17
+ 8ylJH7N1wPHZKz28JrcFETZSzyo=
18
+ </data>
19
+ <key>Default-Landscape.png</key>
20
+ <data>
21
+ 9pgDW2LOQyRAPScwkyfDnZllNS0=
22
+ </data>
23
+ <key>Default-Portrait.png</key>
24
+ <data>
25
+ VWFZpYKaTfooVdHhD5pbbJVaiK8=
26
+ </data>
27
+ <key>Default.png</key>
28
+ <data>
29
+ n0O2VKrKGdgut2gRqfcIfi5ZWRE=
30
+ </data>
31
+ <key>ExternalWebView.nib</key>
32
+ <data>
33
+ q902wsmqdPnXgYXZkTyacTOQW98=
34
+ </data>
35
+ <key>ExternalWebView_Phone.nib</key>
36
+ <data>
37
+ Iv+UyuRtCTey8RLlmxxOLPv6qXU=
38
+ </data>
39
+ <key>GmailWebView.nib</key>
40
+ <data>
41
+ fD725MP8KEJyKfnUHnC1ap6rh84=
42
+ </data>
43
+ <key>GmailWebView_Phone.nib</key>
44
+ <data>
45
+ FC922vWks0NwN+B+8NnqLy6hQ10=
46
+ </data>
47
+ <key>MainWindow_Pad.nib</key>
48
+ <data>
49
+ +6WOkZsGMKWUOD3vVsL8U9Q0Wm8=
50
+ </data>
51
+ <key>MainWindow_Phone.nib</key>
52
+ <data>
53
+ ODbcV8Pc/oTiYbebSoXuc09Bpp0=
54
+ </data>
55
+ <key>MultiMail.momd/MultiMail 2.mom</key>
56
+ <data>
57
+ 3LdTFsmpRTddNJ/j4I1BjYmKstM=
58
+ </data>
59
+ <key>MultiMail.momd/MultiMail 3.mom</key>
60
+ <data>
61
+ qWHGBfl8YX0Vqns6lfl0pZoZzfw=
62
+ </data>
63
+ <key>MultiMail.momd/MultiMail.mom</key>
64
+ <data>
65
+ WK+mfYC00/2DYCr8+JB/b4PLTGs=
66
+ </data>
67
+ <key>PkgInfo</key>
68
+ <data>
69
+ n57qDP4tZfLD1rCS43W0B4LQjzE=
70
+ </data>
71
+ <key>RootView.nib</key>
72
+ <data>
73
+ Ps04oMGcavkHVN16E6x2qhhiUWg=
74
+ </data>
75
+ <key>RootView_Phone.nib</key>
76
+ <data>
77
+ g7HOemeyRsNKeR3J30RPpmJbDqg=
78
+ </data>
79
+ <key>Settings.nib</key>
80
+ <data>
81
+ eUqOCJ3o5dC6/G2jYjt0ryAlbmQ=
82
+ </data>
83
+ <key>TableViewCellOnOff.nib</key>
84
+ <data>
85
+ FVX2y9YpmV1easO7YO//Fu0mwDE=
86
+ </data>
87
+ <key>back_small.png</key>
88
+ <data>
89
+ qIfS3VYnf/vUVFluqgG8iktd814=
90
+ </data>
91
+ <key>dist.plist</key>
92
+ <data>
93
+ s45CsB1sm2EFR9Z1NilFQ5hxXrI=
94
+ </data>
95
+ <key>embedded.mobileprovision</key>
96
+ <data>
97
+ Y7rOykzYACchiX+HF8Hs7IFgffU=
98
+ </data>
99
+ <key>forward_small.png</key>
100
+ <data>
101
+ 50tWCzD+7+7VOfNxZAl3Utjo1xE=
102
+ </data>
103
+ <key>icon-ipad.png</key>
104
+ <data>
105
+ kyNNDzUZxPXRZm7Yz/dAwYOQ9TA=
106
+ </data>
107
+ <key>icon-iphone.png</key>
108
+ <data>
109
+ RqTBh/HFCJRMKOTX/+KdnCiSdJk=
110
+ </data>
111
+ <key>settings_small.png</key>
112
+ <data>
113
+ Xa0iKIHr0w/T/YzLWp1mAipy0Ug=
114
+ </data>
115
+ </dict>
116
+ <key>rules</key>
117
+ <dict>
118
+ <key>.*</key>
119
+ <true/>
120
+ <key>Info.plist</key>
121
+ <dict>
122
+ <key>omit</key>
123
+ <true/>
124
+ <key>weight</key>
125
+ <real>10</real>
126
+ </dict>
127
+ <key>ResourceRules.plist</key>
128
+ <dict>
129
+ <key>omit</key>
130
+ <true/>
131
+ <key>weight</key>
132
+ <real>100</real>
133
+ </dict>
134
+ </dict>
135
+ </dict>
136
+ </plist>
Binary file
Binary file
Binary file
@@ -0,0 +1,44 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>NSManagedObjectModel_CurrentVersionName</key>
6
+ <string>MultiMail 3</string>
7
+ <key>NSManagedObjectModel_VersionHashes</key>
8
+ <dict>
9
+ <key>MultiMail</key>
10
+ <dict>
11
+ <key>Account</key>
12
+ <data>
13
+ tmk9q8df4wRRXOWRdYgWfjMKf6i7MDCClb0UujAuJVE=
14
+ </data>
15
+ <key>State</key>
16
+ <data>
17
+ tWGVIBtkcvg4I5qx3jIWBJrs1hqpGXih01No+EOcavg=
18
+ </data>
19
+ </dict>
20
+ <key>MultiMail 2</key>
21
+ <dict>
22
+ <key>Account</key>
23
+ <data>
24
+ poR+EgneS4FDDKTLtdQ1EsSRyer0XBL13gfFVgwefSE=
25
+ </data>
26
+ <key>State</key>
27
+ <data>
28
+ tWGVIBtkcvg4I5qx3jIWBJrs1hqpGXih01No+EOcavg=
29
+ </data>
30
+ </dict>
31
+ <key>MultiMail 3</key>
32
+ <dict>
33
+ <key>Account</key>
34
+ <data>
35
+ 2r8uf0oPFCt6YTW4j3WChAzMqF91HIXmkUvU4sTBdtw=
36
+ </data>
37
+ <key>State</key>
38
+ <data>
39
+ tWGVIBtkcvg4I5qx3jIWBJrs1hqpGXih01No+EOcavg=
40
+ </data>
41
+ </dict>
42
+ </dict>
43
+ </dict>
44
+ </plist>
@@ -0,0 +1 @@
1
+ APPL????
@@ -0,0 +1,25 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>rules</key>
6
+ <dict>
7
+ <key>.*</key>
8
+ <true/>
9
+ <key>Info.plist</key>
10
+ <dict>
11
+ <key>omit</key>
12
+ <true/>
13
+ <key>weight</key>
14
+ <real>10</real>
15
+ </dict>
16
+ <key>ResourceRules.plist</key>
17
+ <dict>
18
+ <key>omit</key>
19
+ <true/>
20
+ <key>weight</key>
21
+ <real>100</real>
22
+ </dict>
23
+ </dict>
24
+ </dict>
25
+ </plist>
@@ -0,0 +1,136 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+ <plist version="1.0">
4
+ <dict>
5
+ <key>files</key>
6
+ <dict>
7
+ <key>AccountTableViewCell.nib</key>
8
+ <data>
9
+ AyjJwvw8bbERsI4rmj/I5YduQJ4=
10
+ </data>
11
+ <key>AddAccountView.nib</key>
12
+ <data>
13
+ lL4dW5BBRh/yBzE9x1mnpFzZjHM=
14
+ </data>
15
+ <key>AddAccountView_Phone.nib</key>
16
+ <data>
17
+ 8ylJH7N1wPHZKz28JrcFETZSzyo=
18
+ </data>
19
+ <key>Default-Landscape.png</key>
20
+ <data>
21
+ 9pgDW2LOQyRAPScwkyfDnZllNS0=
22
+ </data>
23
+ <key>Default-Portrait.png</key>
24
+ <data>
25
+ VWFZpYKaTfooVdHhD5pbbJVaiK8=
26
+ </data>
27
+ <key>Default.png</key>
28
+ <data>
29
+ n0O2VKrKGdgut2gRqfcIfi5ZWRE=
30
+ </data>
31
+ <key>ExternalWebView.nib</key>
32
+ <data>
33
+ q902wsmqdPnXgYXZkTyacTOQW98=
34
+ </data>
35
+ <key>ExternalWebView_Phone.nib</key>
36
+ <data>
37
+ Iv+UyuRtCTey8RLlmxxOLPv6qXU=
38
+ </data>
39
+ <key>GmailWebView.nib</key>
40
+ <data>
41
+ fD725MP8KEJyKfnUHnC1ap6rh84=
42
+ </data>
43
+ <key>GmailWebView_Phone.nib</key>
44
+ <data>
45
+ FC922vWks0NwN+B+8NnqLy6hQ10=
46
+ </data>
47
+ <key>MainWindow_Pad.nib</key>
48
+ <data>
49
+ +6WOkZsGMKWUOD3vVsL8U9Q0Wm8=
50
+ </data>
51
+ <key>MainWindow_Phone.nib</key>
52
+ <data>
53
+ ODbcV8Pc/oTiYbebSoXuc09Bpp0=
54
+ </data>
55
+ <key>MultiMail.momd/MultiMail 2.mom</key>
56
+ <data>
57
+ 3LdTFsmpRTddNJ/j4I1BjYmKstM=
58
+ </data>
59
+ <key>MultiMail.momd/MultiMail 3.mom</key>
60
+ <data>
61
+ qWHGBfl8YX0Vqns6lfl0pZoZzfw=
62
+ </data>
63
+ <key>MultiMail.momd/MultiMail.mom</key>
64
+ <data>
65
+ WK+mfYC00/2DYCr8+JB/b4PLTGs=
66
+ </data>
67
+ <key>PkgInfo</key>
68
+ <data>
69
+ n57qDP4tZfLD1rCS43W0B4LQjzE=
70
+ </data>
71
+ <key>RootView.nib</key>
72
+ <data>
73
+ Ps04oMGcavkHVN16E6x2qhhiUWg=
74
+ </data>
75
+ <key>RootView_Phone.nib</key>
76
+ <data>
77
+ g7HOemeyRsNKeR3J30RPpmJbDqg=
78
+ </data>
79
+ <key>Settings.nib</key>
80
+ <data>
81
+ eUqOCJ3o5dC6/G2jYjt0ryAlbmQ=
82
+ </data>
83
+ <key>TableViewCellOnOff.nib</key>
84
+ <data>
85
+ FVX2y9YpmV1easO7YO//Fu0mwDE=
86
+ </data>
87
+ <key>back_small.png</key>
88
+ <data>
89
+ qIfS3VYnf/vUVFluqgG8iktd814=
90
+ </data>
91
+ <key>dist.plist</key>
92
+ <data>
93
+ s45CsB1sm2EFR9Z1NilFQ5hxXrI=
94
+ </data>
95
+ <key>embedded.mobileprovision</key>
96
+ <data>
97
+ Y7rOykzYACchiX+HF8Hs7IFgffU=
98
+ </data>
99
+ <key>forward_small.png</key>
100
+ <data>
101
+ 50tWCzD+7+7VOfNxZAl3Utjo1xE=
102
+ </data>
103
+ <key>icon-ipad.png</key>
104
+ <data>
105
+ kyNNDzUZxPXRZm7Yz/dAwYOQ9TA=
106
+ </data>
107
+ <key>icon-iphone.png</key>
108
+ <data>
109
+ RqTBh/HFCJRMKOTX/+KdnCiSdJk=
110
+ </data>
111
+ <key>settings_small.png</key>
112
+ <data>
113
+ Xa0iKIHr0w/T/YzLWp1mAipy0Ug=
114
+ </data>
115
+ </dict>
116
+ <key>rules</key>
117
+ <dict>
118
+ <key>.*</key>
119
+ <true/>
120
+ <key>Info.plist</key>
121
+ <dict>
122
+ <key>omit</key>
123
+ <true/>
124
+ <key>weight</key>
125
+ <real>10</real>
126
+ </dict>
127
+ <key>ResourceRules.plist</key>
128
+ <dict>
129
+ <key>omit</key>
130
+ <true/>
131
+ <key>weight</key>
132
+ <real>100</real>
133
+ </dict>
134
+ </dict>
135
+ </dict>
136
+ </plist>
Binary file
data/version.txt CHANGED
@@ -1 +1 @@
1
- 0.5.1
1
+ 0.6
metadata CHANGED
@@ -1,13 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ipa_reader
3
3
  version: !ruby/object:Gem::Version
4
- hash: 9
4
+ hash: 7
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
- - 5
9
- - 1
10
- version: 0.5.1
8
+ - 6
9
+ version: "0.6"
11
10
  platform: ruby
12
11
  authors:
13
12
  - Nicholas Schlueter
@@ -15,7 +14,7 @@ autorequire:
15
14
  bindir: bin
16
15
  cert_chain: []
17
16
 
18
- date: 2010-09-30 00:00:00 -04:00
17
+ date: 2011-01-24 00:00:00 -05:00
19
18
  default_executable:
20
19
  dependencies:
21
20
  - !ruby/object:Gem::Dependency
@@ -73,6 +72,39 @@ files:
73
72
  - spec/ipa_reader_spec.rb
74
73
  - spec/spec_helper.rb
75
74
  - test/MultiG.ipa
75
+ - test/Payload/MultiG.app/AccountTableViewCell.nib
76
+ - test/Payload/MultiG.app/AddAccountView.nib
77
+ - test/Payload/MultiG.app/AddAccountView_Phone.nib
78
+ - test/Payload/MultiG.app/CodeResources
79
+ - test/Payload/MultiG.app/Default-Landscape.png
80
+ - test/Payload/MultiG.app/Default-Portrait.png
81
+ - test/Payload/MultiG.app/Default.png
82
+ - test/Payload/MultiG.app/ExternalWebView.nib
83
+ - test/Payload/MultiG.app/ExternalWebView_Phone.nib
84
+ - test/Payload/MultiG.app/GmailWebView.nib
85
+ - test/Payload/MultiG.app/GmailWebView_Phone.nib
86
+ - test/Payload/MultiG.app/Info.plist
87
+ - test/Payload/MultiG.app/MainWindow_Pad.nib
88
+ - test/Payload/MultiG.app/MainWindow_Phone.nib
89
+ - test/Payload/MultiG.app/MultiG
90
+ - test/Payload/MultiG.app/MultiMail.momd/MultiMail 2.mom
91
+ - test/Payload/MultiG.app/MultiMail.momd/MultiMail 3.mom
92
+ - test/Payload/MultiG.app/MultiMail.momd/MultiMail.mom
93
+ - test/Payload/MultiG.app/MultiMail.momd/VersionInfo.plist
94
+ - test/Payload/MultiG.app/PkgInfo
95
+ - test/Payload/MultiG.app/ResourceRules.plist
96
+ - test/Payload/MultiG.app/RootView.nib
97
+ - test/Payload/MultiG.app/RootView_Phone.nib
98
+ - test/Payload/MultiG.app/Settings.nib
99
+ - test/Payload/MultiG.app/TableViewCellOnOff.nib
100
+ - test/Payload/MultiG.app/_CodeSignature/CodeResources
101
+ - test/Payload/MultiG.app/back_small.png
102
+ - test/Payload/MultiG.app/dist.plist
103
+ - test/Payload/MultiG.app/embedded.mobileprovision
104
+ - test/Payload/MultiG.app/forward_small.png
105
+ - test/Payload/MultiG.app/icon-ipad.png
106
+ - test/Payload/MultiG.app/icon-iphone.png
107
+ - test/Payload/MultiG.app/settings_small.png
76
108
  - test/test_ipa_reader.rb
77
109
  - version.txt
78
110
  has_rdoc: true