alexa_web_service 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c6a5420fbe930216340154847bf38452081bea63
4
- data.tar.gz: 72d381e9d150c925e8d6103faa24f3d352ddd9f5
3
+ metadata.gz: 1f13606e9587ceabbd5828d9fb36c1cca38db925
4
+ data.tar.gz: c0bfa0d3d93517fb0a2976a547acb87f6acb23cf
5
5
  SHA512:
6
- metadata.gz: d83e9ae0adc8294c081ef98553e121c68c88a8a054f8d195c7f98ca73790538f69c2ebea2cbf122c11ff60087a85c073ceece50df60250daa76f894240476822
7
- data.tar.gz: 12e02c87458a1810edd6dc7aea5e546ea00dfd7d98defd6bc7a100dec172759afd23fe72457f58436a4b963d074b6ff4a685a1394526d39a86e39757d902cf7b
6
+ metadata.gz: fbbfef34225182fa5831b331dd8f29aa65d226cd1a100b37f8fb1332bdd1a26e5e13e1ca90738e1c2f2d7ccfebd1dc56d100cde29e38bf828bd856fb7685233c
7
+ data.tar.gz: 7ca83a8b5b948a346e5c8f42bfd5e98933f352d7fd8d1985d42034e3a1677093b0c3928a5d219c9e9e280148cff062ab35c5c40af0c7bfcb1496649920361e2c
@@ -27,9 +27,9 @@ module AlexaWebService
27
27
  begin
28
28
  OpenSSL::X509::Certificate.new HTTParty.get(@url)
29
29
  rescue TypeError
30
- halt 400, "Bad Request"
30
+ "Bad Request"
31
31
  rescue OpenSSL::SSL::SSLError
32
- halt 400, "Bad Request"
32
+ "Bad Request"
33
33
  end
34
34
  end
35
35
 
@@ -42,19 +42,19 @@ module AlexaWebService
42
42
  if valid_address? && valid_timestamp?
43
43
  @certificate = get_certificate
44
44
  else
45
- halt 400, "Bad Request"
45
+ "Bad Request"
46
46
  end
47
47
 
48
48
  if valid_certificate?(@certificate)
49
49
  @verify = check_signature(@certificate)
50
50
  else
51
- halt 400, "Invalid Certificate"
51
+ "Invalid Certificate"
52
52
  end
53
53
 
54
54
  if @verify
55
- status 200
55
+ "OK"
56
56
  else
57
- halt 400, "Invalid Signature"
57
+ "Invalid Signature"
58
58
  end
59
59
  end
60
60
  end
@@ -1,3 +1,3 @@
1
1
  module AlexaWebService
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alexa_web_service
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - sarkonovich
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-04 00:00:00.000000000 Z
11
+ date: 2016-07-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler