rdap 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -0
- data/lib/rdap.rb +4 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a99673df539bd98e21a4e72d6016395e4d287242b7e4c32c51db227de855f25
|
4
|
+
data.tar.gz: 67d8b8e7bc6a7d6810aaef71405d9a52dad469e4d8472e596cf4833b3e5b9301
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 32a03c18914f4898eb292013cae6d424ac085c04c1fb944e2d91b07c1d25356382cee2bc736852c4dcdf824d74ff17a5ce7d6c94a16161bc13b65fdae5f6dd24
|
7
|
+
data.tar.gz: a50a93ccf5f86e3942189c9356d366a9030ee863ec5492d4886e3b302c6f467306e6d1b05805c2fcfa538a5f276799ee43c9aa2adf44ee08cd90ab8b461ef218
|
data/README.md
CHANGED
@@ -84,6 +84,7 @@ The gem make a query to one of the publicly available RDAP bootstrap server (the
|
|
84
84
|
|
85
85
|
## Changelog
|
86
86
|
|
87
|
+
- **0.1.3** (2022-01-10) - Wrap SSL errors as RDAP::SSLError < ServerError < Error
|
87
88
|
- **0.1.2** (2022-01-07) - Added HTTP headers customization
|
88
89
|
- **0.1.1** (2021-12-19) - Added TooManyRequests expection in case of 429
|
89
90
|
- **0.1.0** (2021-12-17) - Initial version
|
data/lib/rdap.rb
CHANGED
@@ -2,7 +2,7 @@ require 'json'
|
|
2
2
|
require 'net/http'
|
3
3
|
|
4
4
|
module RDAP
|
5
|
-
VERSION = "0.1.
|
5
|
+
VERSION = "0.1.3"
|
6
6
|
BOOTSTRAP = "https://rdap.org/"
|
7
7
|
TYPES = [:domain, :ip, :autnum].freeze
|
8
8
|
HEADERS = {
|
@@ -12,6 +12,7 @@ module RDAP
|
|
12
12
|
|
13
13
|
class Error < StandardError; end
|
14
14
|
class ServerError < Error; end
|
15
|
+
class SSLError < ServerError; end
|
15
16
|
class NotFound < Error; end
|
16
17
|
class TooManyRequests < Error; end
|
17
18
|
|
@@ -66,5 +67,7 @@ module RDAP
|
|
66
67
|
else
|
67
68
|
raise ServerError.new("[#{response.code}] #{response.message}")
|
68
69
|
end
|
70
|
+
rescue OpenSSL::SSL::SSLError => e
|
71
|
+
raise SSLError.new("#{e.message} (#{uri.host})")
|
69
72
|
end
|
70
73
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rdap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adrien Rey-Jarthon
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-01-
|
11
|
+
date: 2022-01-10 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|