google-cloud-recaptcha_enterprise 1.5.0 → 1.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +31 -26
- data/lib/google/cloud/recaptcha_enterprise/version.rb +1 -1
- data/lib/google/cloud/recaptcha_enterprise.rb +31 -0
- metadata +4 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4a0d40c57d5366089454b503dd0446d15ac7e4673ded45c062af04d936e9346d
|
4
|
+
data.tar.gz: 6483a431a559dbebd5659b784563c2c4986ee45c67d99cb17d89547e528debbe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2b1ae48f1bd15b1f871e9785cb979b8a84d27655bd40c4a4d3c949d8640ba0f134beaa9422390f861b1856a53bb20980ccef90000abe81d61f4ac5f7cf32655e
|
7
|
+
data.tar.gz: 7b22ba97fbd67a10a4e76839253848dcb560bc0a9e61bcdd58bd776f47a32beeb339458aa42c773f9af451c08554499da282c7ea16599ea7760033ebcbb5c440
|
data/README.md
CHANGED
@@ -43,35 +43,40 @@ and includes substantial interface changes. Existing code written for earlier
|
|
43
43
|
versions of this library will likely require updates to use this version.
|
44
44
|
See the {file:MIGRATING.md MIGRATING.md} document for more information.
|
45
45
|
|
46
|
-
##
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
46
|
+
## Debug Logging
|
47
|
+
|
48
|
+
This library comes with opt-in Debug Logging that can help you troubleshoot
|
49
|
+
your application's integration with the API. When logging is activated, key
|
50
|
+
events such as requests and responses, along with data payloads and metadata
|
51
|
+
such as headers and client configuration, are logged to the standard error
|
52
|
+
stream.
|
53
|
+
|
54
|
+
**WARNING:** Client Library Debug Logging includes your data payloads in
|
55
|
+
plaintext, which could include sensitive data such as PII for yourself or your
|
56
|
+
customers, private keys, or other security data that could be compromising if
|
57
|
+
leaked. Always practice good data hygiene with your application logs, and follow
|
58
|
+
the principle of least access. Google also recommends that Client Library Debug
|
59
|
+
Logging be enabled only temporarily during active debugging, and not used
|
60
|
+
permanently in production.
|
61
|
+
|
62
|
+
To enable logging, set the environment variable `GOOGLE_SDK_RUBY_LOGGING_GEMS`
|
63
|
+
to the value `all`. Alternatively, you can set the value to a comma-delimited
|
64
|
+
list of client library gem names. This will select the default logging behavior,
|
65
|
+
which writes logs to the standard error stream. On a local workstation, this may
|
66
|
+
result in logs appearing on the console. When running on a Google Cloud hosting
|
67
|
+
service such as [Google Cloud Run](https://cloud.google.com/run), this generally
|
68
|
+
results in logs appearing alongside your application logs in the
|
69
|
+
[Google Cloud Logging](https://cloud.google.com/logging/) service.
|
70
|
+
|
71
|
+
Debug logging also requires that the versioned clients for this service be
|
72
|
+
sufficiently recent, released after about Dec 10, 2024. If logging is not
|
73
|
+
working, try updating the versioned clients in your bundle or installed gems:
|
74
|
+
[google-cloud-recaptcha_enterprise-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-recaptcha_enterprise-v1/latest),
|
75
|
+
[google-cloud-recaptcha_enterprise-v1beta1](https://cloud.google.com/ruby/docs/reference/google-cloud-recaptcha_enterprise-v1beta1/latest).
|
71
76
|
|
72
77
|
## Supported Ruby Versions
|
73
78
|
|
74
|
-
This library is supported on Ruby
|
79
|
+
This library is supported on Ruby 3.0+.
|
75
80
|
|
76
81
|
Google provides official support for Ruby versions that are actively supported
|
77
82
|
by Ruby Core—that is, Ruby versions that are either in normal maintenance or
|
@@ -56,6 +56,11 @@ module Google
|
|
56
56
|
# supported by that API version, and the corresponding gem is available, the
|
57
57
|
# appropriate versioned client will be returned.
|
58
58
|
#
|
59
|
+
# Raises an exception if the currently installed versioned client gem for the
|
60
|
+
# given API version does not support the RecaptchaEnterpriseService service.
|
61
|
+
# You can determine whether the method will succeed by calling
|
62
|
+
# {Google::Cloud::RecaptchaEnterprise.recaptcha_enterprise_service_available?}.
|
63
|
+
#
|
59
64
|
# ## About RecaptchaEnterpriseService
|
60
65
|
#
|
61
66
|
# Service to determine the likelihood an event is legitimate.
|
@@ -75,6 +80,32 @@ module Google
|
|
75
80
|
service_module.const_get(:Client).new(&block)
|
76
81
|
end
|
77
82
|
|
83
|
+
##
|
84
|
+
# Determines whether the RecaptchaEnterpriseService service is supported by the current client.
|
85
|
+
# If true, you can retrieve a client object by calling {Google::Cloud::RecaptchaEnterprise.recaptcha_enterprise_service}.
|
86
|
+
# If false, that method will raise an exception. This could happen if the given
|
87
|
+
# API version does not exist or does not support the RecaptchaEnterpriseService service,
|
88
|
+
# or if the versioned client gem needs an update to support the RecaptchaEnterpriseService service.
|
89
|
+
#
|
90
|
+
# @param version [::String, ::Symbol] The API version to connect to. Optional.
|
91
|
+
# Defaults to `:v1`.
|
92
|
+
# @return [boolean] Whether the service is available.
|
93
|
+
#
|
94
|
+
def self.recaptcha_enterprise_service_available? version: :v1
|
95
|
+
require "google/cloud/recaptcha_enterprise/#{version.to_s.downcase}"
|
96
|
+
package_name = Google::Cloud::RecaptchaEnterprise
|
97
|
+
.constants
|
98
|
+
.select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
|
99
|
+
.first
|
100
|
+
return false unless package_name
|
101
|
+
service_module = Google::Cloud::RecaptchaEnterprise.const_get package_name
|
102
|
+
return false unless service_module.const_defined? :RecaptchaEnterpriseService
|
103
|
+
service_module = service_module.const_get :RecaptchaEnterpriseService
|
104
|
+
service_module.const_defined? :Client
|
105
|
+
rescue ::LoadError
|
106
|
+
false
|
107
|
+
end
|
108
|
+
|
78
109
|
##
|
79
110
|
# Configure the google-cloud-recaptcha_enterprise library.
|
80
111
|
#
|
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-recaptcha_enterprise
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
|
-
autorequire:
|
9
8
|
bindir: bin
|
10
9
|
cert_chain: []
|
11
|
-
date:
|
10
|
+
date: 2025-01-29 00:00:00.000000000 Z
|
12
11
|
dependencies:
|
13
12
|
- !ruby/object:Gem::Dependency
|
14
13
|
name: google-cloud-core
|
@@ -83,7 +82,6 @@ homepage: https://github.com/googleapis/google-cloud-ruby
|
|
83
82
|
licenses:
|
84
83
|
- Apache-2.0
|
85
84
|
metadata: {}
|
86
|
-
post_install_message:
|
87
85
|
rdoc_options: []
|
88
86
|
require_paths:
|
89
87
|
- lib
|
@@ -91,15 +89,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
91
89
|
requirements:
|
92
90
|
- - ">="
|
93
91
|
- !ruby/object:Gem::Version
|
94
|
-
version: '
|
92
|
+
version: '3.0'
|
95
93
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
96
94
|
requirements:
|
97
95
|
- - ">="
|
98
96
|
- !ruby/object:Gem::Version
|
99
97
|
version: '0'
|
100
98
|
requirements: []
|
101
|
-
rubygems_version: 3.
|
102
|
-
signing_key:
|
99
|
+
rubygems_version: 3.6.2
|
103
100
|
specification_version: 4
|
104
101
|
summary: API Client library for the reCAPTCHA Enterprise API
|
105
102
|
test_files: []
|