motion-openssl 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (88) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +53 -0
  3. data/lib/OpenSSL/aes.h +149 -0
  4. data/lib/OpenSSL/asn1.h +1419 -0
  5. data/lib/OpenSSL/asn1_mac.h +579 -0
  6. data/lib/OpenSSL/asn1t.h +973 -0
  7. data/lib/OpenSSL/bio.h +879 -0
  8. data/lib/OpenSSL/blowfish.h +130 -0
  9. data/lib/OpenSSL/bn.h +939 -0
  10. data/lib/OpenSSL/buffer.h +125 -0
  11. data/lib/OpenSSL/camellia.h +132 -0
  12. data/lib/OpenSSL/cast.h +107 -0
  13. data/lib/OpenSSL/cmac.h +82 -0
  14. data/lib/OpenSSL/cms.h +555 -0
  15. data/lib/OpenSSL/comp.h +79 -0
  16. data/lib/OpenSSL/conf.h +267 -0
  17. data/lib/OpenSSL/conf_api.h +89 -0
  18. data/lib/OpenSSL/crypto.h +661 -0
  19. data/lib/OpenSSL/des.h +257 -0
  20. data/lib/OpenSSL/des_old.h +497 -0
  21. data/lib/OpenSSL/dh.h +392 -0
  22. data/lib/OpenSSL/dsa.h +332 -0
  23. data/lib/OpenSSL/dso.h +451 -0
  24. data/lib/OpenSSL/dtls1.h +272 -0
  25. data/lib/OpenSSL/e_os2.h +328 -0
  26. data/lib/OpenSSL/ebcdic.h +26 -0
  27. data/lib/OpenSSL/ec.h +1282 -0
  28. data/lib/OpenSSL/ecdh.h +134 -0
  29. data/lib/OpenSSL/ecdsa.h +335 -0
  30. data/lib/OpenSSL/engine.h +960 -0
  31. data/lib/OpenSSL/err.h +389 -0
  32. data/lib/OpenSSL/evp.h +1534 -0
  33. data/lib/OpenSSL/hmac.h +109 -0
  34. data/lib/OpenSSL/idea.h +105 -0
  35. data/lib/OpenSSL/krb5_asn.h +240 -0
  36. data/lib/OpenSSL/kssl.h +197 -0
  37. data/lib/OpenSSL/lhash.h +240 -0
  38. data/lib/OpenSSL/libcrypto-tvOS.a +0 -0
  39. data/lib/OpenSSL/libcrypto.a +0 -0
  40. data/lib/OpenSSL/libssl-tvOS.a +0 -0
  41. data/lib/OpenSSL/libssl.a +0 -0
  42. data/lib/OpenSSL/md4.h +119 -0
  43. data/lib/OpenSSL/md5.h +119 -0
  44. data/lib/OpenSSL/mdc2.h +94 -0
  45. data/lib/OpenSSL/modes.h +163 -0
  46. data/lib/OpenSSL/obj_mac.h +4194 -0
  47. data/lib/OpenSSL/objects.h +1143 -0
  48. data/lib/OpenSSL/ocsp.h +637 -0
  49. data/lib/OpenSSL/opensslconf.h +262 -0
  50. data/lib/OpenSSL/opensslv.h +97 -0
  51. data/lib/OpenSSL/ossl_typ.h +211 -0
  52. data/lib/OpenSSL/pem.h +615 -0
  53. data/lib/OpenSSL/pem2.h +70 -0
  54. data/lib/OpenSSL/pkcs12.h +342 -0
  55. data/lib/OpenSSL/pkcs7.h +481 -0
  56. data/lib/OpenSSL/pqueue.h +99 -0
  57. data/lib/OpenSSL/rand.h +150 -0
  58. data/lib/OpenSSL/rc2.h +103 -0
  59. data/lib/OpenSSL/rc4.h +88 -0
  60. data/lib/OpenSSL/ripemd.h +105 -0
  61. data/lib/OpenSSL/rsa.h +664 -0
  62. data/lib/OpenSSL/safestack.h +2672 -0
  63. data/lib/OpenSSL/seed.h +149 -0
  64. data/lib/OpenSSL/sha.h +214 -0
  65. data/lib/OpenSSL/srp.h +169 -0
  66. data/lib/OpenSSL/srtp.h +147 -0
  67. data/lib/OpenSSL/ssl.h +3168 -0
  68. data/lib/OpenSSL/ssl2.h +265 -0
  69. data/lib/OpenSSL/ssl23.h +84 -0
  70. data/lib/OpenSSL/ssl3.h +774 -0
  71. data/lib/OpenSSL/stack.h +107 -0
  72. data/lib/OpenSSL/symhacks.h +516 -0
  73. data/lib/OpenSSL/tls1.h +810 -0
  74. data/lib/OpenSSL/ts.h +862 -0
  75. data/lib/OpenSSL/txt_db.h +112 -0
  76. data/lib/OpenSSL/ui.h +415 -0
  77. data/lib/OpenSSL/ui_compat.h +88 -0
  78. data/lib/OpenSSL/whrlpool.h +41 -0
  79. data/lib/OpenSSL/x509.h +1327 -0
  80. data/lib/OpenSSL/x509_vfy.h +647 -0
  81. data/lib/OpenSSL/x509v3.h +1055 -0
  82. data/lib/motion-openssl.rb +8 -0
  83. data/lib/motion-openssl/hooks.rb +8 -0
  84. data/lib/motion-openssl/hooks/openssl.rb +20 -0
  85. data/lib/motion-openssl/version.rb +5 -0
  86. data/motion/openssl.rb +1 -0
  87. data/motion/openssl/random.rb +18 -0
  88. metadata +229 -0
@@ -0,0 +1,8 @@
1
+ require 'motion_blender'
2
+ MotionBlender.incept
3
+ MotionBlender.use_motion_dir
4
+
5
+ require 'motion-openssl/version'
6
+ require 'motion-openssl/hooks'
7
+
8
+ require 'openssl'
@@ -0,0 +1,8 @@
1
+ MotionBlender.except
2
+
3
+ Dir[File.expand_path('../hooks/**/*.rb', __FILE__)].each do |file|
4
+ name = File.basename file, '.*'
5
+ MotionBlender.on_require name do
6
+ require file
7
+ end
8
+ end
@@ -0,0 +1,20 @@
1
+ lib_dir = File.expand_path('../../..', __FILE__)
2
+
3
+ Motion::Project::App.setup do |app|
4
+ case app.template || :ios
5
+ when :ios
6
+ app.vendor_project(
7
+ File.join(lib_dir, "OpenSSL"),
8
+ :static,
9
+ products: %w(libssl.a libcrypto.a)
10
+ )
11
+ when :tvos
12
+ app.vendor_project(
13
+ File.join(lib_dir, "OpenSSL"),
14
+ :static,
15
+ products: %w(libssl-tvOS.a libcrypto-tvOS.a)
16
+ )
17
+ else
18
+ raise "Unknown platform"
19
+ end
20
+ end
@@ -0,0 +1,5 @@
1
+ module Motion
2
+ module OpenSSL
3
+ VERSION = "0.1.0"
4
+ end
5
+ end
@@ -0,0 +1 @@
1
+ require 'openssl/random'
@@ -0,0 +1,18 @@
1
+ module OpenSSL
2
+ module Random
3
+ def self.random_bytes length
4
+ fail ArgumentEror, 'negative string size (or size too big)' if length < 0
5
+ s = ' ' * length
6
+ ret = RAND_bytes(s, length)
7
+ unless ret == 1
8
+ fail 'RAND_bytes error'
9
+ end
10
+ s
11
+ end
12
+
13
+ def self.random_add str, entropy
14
+ RAND_add(str, str.length, entropy)
15
+ self
16
+ end
17
+ end
18
+ end
metadata ADDED
@@ -0,0 +1,229 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: motion-openssl
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - kayhide
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-01-04 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: motion_blender
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.10'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.10'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '10.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '10.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: pry
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: pry-doc
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: motion-redgreen
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: motion-stump
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ description: OpenSSL library for RubyMotion. Compatible to the mri version.
112
+ email:
113
+ - kayhide@gmail.com
114
+ executables: []
115
+ extensions: []
116
+ extra_rdoc_files: []
117
+ files:
118
+ - README.md
119
+ - lib/OpenSSL/aes.h
120
+ - lib/OpenSSL/asn1.h
121
+ - lib/OpenSSL/asn1_mac.h
122
+ - lib/OpenSSL/asn1t.h
123
+ - lib/OpenSSL/bio.h
124
+ - lib/OpenSSL/blowfish.h
125
+ - lib/OpenSSL/bn.h
126
+ - lib/OpenSSL/buffer.h
127
+ - lib/OpenSSL/camellia.h
128
+ - lib/OpenSSL/cast.h
129
+ - lib/OpenSSL/cmac.h
130
+ - lib/OpenSSL/cms.h
131
+ - lib/OpenSSL/comp.h
132
+ - lib/OpenSSL/conf.h
133
+ - lib/OpenSSL/conf_api.h
134
+ - lib/OpenSSL/crypto.h
135
+ - lib/OpenSSL/des.h
136
+ - lib/OpenSSL/des_old.h
137
+ - lib/OpenSSL/dh.h
138
+ - lib/OpenSSL/dsa.h
139
+ - lib/OpenSSL/dso.h
140
+ - lib/OpenSSL/dtls1.h
141
+ - lib/OpenSSL/e_os2.h
142
+ - lib/OpenSSL/ebcdic.h
143
+ - lib/OpenSSL/ec.h
144
+ - lib/OpenSSL/ecdh.h
145
+ - lib/OpenSSL/ecdsa.h
146
+ - lib/OpenSSL/engine.h
147
+ - lib/OpenSSL/err.h
148
+ - lib/OpenSSL/evp.h
149
+ - lib/OpenSSL/hmac.h
150
+ - lib/OpenSSL/idea.h
151
+ - lib/OpenSSL/krb5_asn.h
152
+ - lib/OpenSSL/kssl.h
153
+ - lib/OpenSSL/lhash.h
154
+ - lib/OpenSSL/libcrypto-tvOS.a
155
+ - lib/OpenSSL/libcrypto.a
156
+ - lib/OpenSSL/libssl-tvOS.a
157
+ - lib/OpenSSL/libssl.a
158
+ - lib/OpenSSL/md4.h
159
+ - lib/OpenSSL/md5.h
160
+ - lib/OpenSSL/mdc2.h
161
+ - lib/OpenSSL/modes.h
162
+ - lib/OpenSSL/obj_mac.h
163
+ - lib/OpenSSL/objects.h
164
+ - lib/OpenSSL/ocsp.h
165
+ - lib/OpenSSL/opensslconf.h
166
+ - lib/OpenSSL/opensslv.h
167
+ - lib/OpenSSL/ossl_typ.h
168
+ - lib/OpenSSL/pem.h
169
+ - lib/OpenSSL/pem2.h
170
+ - lib/OpenSSL/pkcs12.h
171
+ - lib/OpenSSL/pkcs7.h
172
+ - lib/OpenSSL/pqueue.h
173
+ - lib/OpenSSL/rand.h
174
+ - lib/OpenSSL/rc2.h
175
+ - lib/OpenSSL/rc4.h
176
+ - lib/OpenSSL/ripemd.h
177
+ - lib/OpenSSL/rsa.h
178
+ - lib/OpenSSL/safestack.h
179
+ - lib/OpenSSL/seed.h
180
+ - lib/OpenSSL/sha.h
181
+ - lib/OpenSSL/srp.h
182
+ - lib/OpenSSL/srtp.h
183
+ - lib/OpenSSL/ssl.h
184
+ - lib/OpenSSL/ssl2.h
185
+ - lib/OpenSSL/ssl23.h
186
+ - lib/OpenSSL/ssl3.h
187
+ - lib/OpenSSL/stack.h
188
+ - lib/OpenSSL/symhacks.h
189
+ - lib/OpenSSL/tls1.h
190
+ - lib/OpenSSL/ts.h
191
+ - lib/OpenSSL/txt_db.h
192
+ - lib/OpenSSL/ui.h
193
+ - lib/OpenSSL/ui_compat.h
194
+ - lib/OpenSSL/whrlpool.h
195
+ - lib/OpenSSL/x509.h
196
+ - lib/OpenSSL/x509_vfy.h
197
+ - lib/OpenSSL/x509v3.h
198
+ - lib/motion-openssl.rb
199
+ - lib/motion-openssl/hooks.rb
200
+ - lib/motion-openssl/hooks/openssl.rb
201
+ - lib/motion-openssl/version.rb
202
+ - motion/openssl.rb
203
+ - motion/openssl/random.rb
204
+ homepage: http://github.com/kayhide/motion-openssl
205
+ licenses:
206
+ - MIT
207
+ metadata: {}
208
+ post_install_message:
209
+ rdoc_options: []
210
+ require_paths:
211
+ - lib
212
+ required_ruby_version: !ruby/object:Gem::Requirement
213
+ requirements:
214
+ - - ">="
215
+ - !ruby/object:Gem::Version
216
+ version: '0'
217
+ required_rubygems_version: !ruby/object:Gem::Requirement
218
+ requirements:
219
+ - - ">="
220
+ - !ruby/object:Gem::Version
221
+ version: '0'
222
+ requirements: []
223
+ rubyforge_project:
224
+ rubygems_version: 2.4.5.1
225
+ signing_key:
226
+ specification_version: 4
227
+ summary: OpenSSL library for RubyMotion.
228
+ test_files: []
229
+ has_rdoc: