contrast-agent 6.6.3 → 6.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/contrast/agent/version.rb +1 -1
- data/lib/contrast/utils/net_http_base.rb +5 -6
- 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: 15953528d5e347bd018a0e448e2653107c782481cc3df1e6513fc52641d52900
|
4
|
+
data.tar.gz: c7bec86c862f372a1e2e3804a129cef4eb2d7ebc18115c7b829ba31080d4553f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b7de9ceb2ed80201d5c74aea212b652c86999b58c20693c5e2d1e233684c1ee54f1d2f56a3cdba20e374b22f35b89d231eec3a486325f7dde183a3ac0c9e114f
|
7
|
+
data.tar.gz: ce3fa2a7ae5021eb60978696254f7b0331f5d7c1d75bb697d423403e7fe2071aea5b66660875afe555a3ad101e8a121b546a3f9d5c7423833bc21a10c8cb4406
|
@@ -38,7 +38,7 @@ module Contrast
|
|
38
38
|
return unless net_http_client.started?
|
39
39
|
|
40
40
|
logger.debug("Starting #{ service_name } connection test")
|
41
|
-
return unless connection_verified?(net_http_client)
|
41
|
+
return unless connection_verified?(net_http_client, url)
|
42
42
|
|
43
43
|
logger.debug('Client verified', service: service_name, url: url)
|
44
44
|
net_http_client
|
@@ -49,18 +49,17 @@ module Contrast
|
|
49
49
|
|
50
50
|
# Validates connection with assigned domain.
|
51
51
|
# If connection is running, SSL certificate of the endpoint is valid, Ip address is resolvable
|
52
|
-
# and response is received without peer's reset or refuse of connection,
|
53
|
-
# then validation returns true. Error handling is in place so that the work of the agent will continue as
|
54
|
-
# normal without Telemetry.
|
52
|
+
# and response is received without peer's reset or refuse of connection, then validation returns true.
|
55
53
|
#
|
56
54
|
# @param client [Net::HTTP]
|
55
|
+
# @param url [String]
|
57
56
|
# @return [Boolean] true | false
|
58
|
-
def connection_verified? client
|
57
|
+
def connection_verified? client, url
|
59
58
|
return @_connection_verified unless @_connection_verified.nil?
|
60
59
|
return false if client.nil?
|
61
60
|
|
62
61
|
ipaddr = get_ipaddr(client)
|
63
|
-
response = client.request(Net::HTTP::Get.new(
|
62
|
+
response = client.request(Net::HTTP::Get.new(url))
|
64
63
|
verify_cert = client.address.to_s.include?('localhost') ||
|
65
64
|
OpenSSL::SSL.verify_certificate_identity(client.peer_cert, client.address)
|
66
65
|
resolved = resolved?(client.address, ipaddr)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: contrast-agent
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.6.
|
4
|
+
version: 6.6.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- galen.palmer@contrastsecurity.com
|
@@ -13,7 +13,7 @@ authors:
|
|
13
13
|
autorequire:
|
14
14
|
bindir: exe
|
15
15
|
cert_chain: []
|
16
|
-
date: 2022-07-
|
16
|
+
date: 2022-07-20 00:00:00.000000000 Z
|
17
17
|
dependencies:
|
18
18
|
- !ruby/object:Gem::Dependency
|
19
19
|
name: bundler
|