ory-oathkeeper-client 0.35.5.beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +103 -0
- data/Rakefile +10 -0
- data/docs/ApiApi.md +195 -0
- data/docs/CreateRuleCreated.md +17 -0
- data/docs/CreateRuleForbidden.md +17 -0
- data/docs/CreateRuleForbiddenBody.md +27 -0
- data/docs/CreateRuleInternalServerError.md +17 -0
- data/docs/CreateRuleInternalServerErrorBody.md +27 -0
- data/docs/CreateRuleUnauthorized.md +17 -0
- data/docs/CreateRuleUnauthorizedBody.md +27 -0
- data/docs/DecisionsForbidden.md +17 -0
- data/docs/DecisionsForbiddenBody.md +27 -0
- data/docs/DecisionsInternalServerError.md +17 -0
- data/docs/DecisionsInternalServerErrorBody.md +27 -0
- data/docs/DecisionsNotFound.md +17 -0
- data/docs/DecisionsNotFoundBody.md +27 -0
- data/docs/DecisionsUnauthorized.md +17 -0
- data/docs/DecisionsUnauthorizedBody.md +27 -0
- data/docs/DeleteRuleForbidden.md +17 -0
- data/docs/DeleteRuleForbiddenBody.md +27 -0
- data/docs/DeleteRuleInternalServerError.md +17 -0
- data/docs/DeleteRuleInternalServerErrorBody.md +27 -0
- data/docs/DeleteRuleNotFound.md +17 -0
- data/docs/DeleteRuleNotFoundBody.md +27 -0
- data/docs/DeleteRuleUnauthorized.md +17 -0
- data/docs/DeleteRuleUnauthorizedBody.md +27 -0
- data/docs/GetRuleForbidden.md +17 -0
- data/docs/GetRuleForbiddenBody.md +27 -0
- data/docs/GetRuleInternalServerError.md +17 -0
- data/docs/GetRuleInternalServerErrorBody.md +27 -0
- data/docs/GetRuleNotFound.md +17 -0
- data/docs/GetRuleNotFoundBody.md +27 -0
- data/docs/GetRuleOK.md +17 -0
- data/docs/GetRuleUnauthorized.md +17 -0
- data/docs/GetRuleUnauthorizedBody.md +27 -0
- data/docs/GetWellKnownForbidden.md +17 -0
- data/docs/GetWellKnownForbiddenBody.md +27 -0
- data/docs/GetWellKnownJSONWebKeysInternalServerError.md +17 -0
- data/docs/GetWellKnownJSONWebKeysInternalServerErrorBody.md +27 -0
- data/docs/GetWellKnownJSONWebKeysOK.md +17 -0
- data/docs/GetWellKnownOK.md +17 -0
- data/docs/GetWellKnownUnauthorized.md +17 -0
- data/docs/GetWellKnownUnauthorizedBody.md +27 -0
- data/docs/HealthApi.md +96 -0
- data/docs/HealthNotReadyStatus.md +17 -0
- data/docs/HealthStatus.md +17 -0
- data/docs/InlineResponse500.md +27 -0
- data/docs/IsInstanceAliveInternalServerError.md +17 -0
- data/docs/IsInstanceAliveInternalServerErrorBody.md +27 -0
- data/docs/IsInstanceAliveOK.md +17 -0
- data/docs/JsonWebKey.md +49 -0
- data/docs/JsonWebKeySet.md +17 -0
- data/docs/JudgeForbidden.md +17 -0
- data/docs/JudgeForbiddenBody.md +27 -0
- data/docs/JudgeInternalServerError.md +17 -0
- data/docs/JudgeInternalServerErrorBody.md +27 -0
- data/docs/JudgeNotFound.md +17 -0
- data/docs/JudgeNotFoundBody.md +27 -0
- data/docs/JudgeUnauthorized.md +17 -0
- data/docs/JudgeUnauthorizedBody.md +27 -0
- data/docs/ListRulesForbidden.md +17 -0
- data/docs/ListRulesForbiddenBody.md +27 -0
- data/docs/ListRulesInternalServerError.md +17 -0
- data/docs/ListRulesInternalServerErrorBody.md +27 -0
- data/docs/ListRulesOK.md +17 -0
- data/docs/ListRulesUnauthorized.md +17 -0
- data/docs/ListRulesUnauthorizedBody.md +27 -0
- data/docs/Rule.md +29 -0
- data/docs/RuleHandler.md +19 -0
- data/docs/RuleMatch.md +19 -0
- data/docs/SwaggerCreateRuleParameters.md +17 -0
- data/docs/SwaggerGetRuleParameters.md +17 -0
- data/docs/SwaggerHealthStatus.md +17 -0
- data/docs/SwaggerJSONWebKey.md +49 -0
- data/docs/SwaggerJSONWebKeySet.md +17 -0
- data/docs/SwaggerListRulesParameters.md +19 -0
- data/docs/SwaggerNotReadyStatus.md +17 -0
- data/docs/SwaggerRule.md +29 -0
- data/docs/SwaggerRuleHandler.md +19 -0
- data/docs/SwaggerRuleMatch.md +19 -0
- data/docs/SwaggerRuleResponse.md +17 -0
- data/docs/SwaggerRulesResponse.md +17 -0
- data/docs/SwaggerUpdateRuleParameters.md +19 -0
- data/docs/SwaggerVersion.md +17 -0
- data/docs/UpdateRuleForbidden.md +17 -0
- data/docs/UpdateRuleForbiddenBody.md +27 -0
- data/docs/UpdateRuleInternalServerError.md +17 -0
- data/docs/UpdateRuleInternalServerErrorBody.md +27 -0
- data/docs/UpdateRuleNotFound.md +17 -0
- data/docs/UpdateRuleNotFoundBody.md +27 -0
- data/docs/UpdateRuleOK.md +17 -0
- data/docs/UpdateRuleUnauthorized.md +17 -0
- data/docs/UpdateRuleUnauthorizedBody.md +27 -0
- data/docs/Upstream.md +21 -0
- data/docs/Version.md +17 -0
- data/docs/VersionApi.md +52 -0
- data/lib/ory-oathkeeper-client.rb +52 -0
- data/lib/ory-oathkeeper-client/api/api_api.rb +258 -0
- data/lib/ory-oathkeeper-client/api/health_api.rb +134 -0
- data/lib/ory-oathkeeper-client/api/version_api.rb +78 -0
- data/lib/ory-oathkeeper-client/api_client.rb +385 -0
- data/lib/ory-oathkeeper-client/api_error.rb +57 -0
- data/lib/ory-oathkeeper-client/configuration.rb +241 -0
- data/lib/ory-oathkeeper-client/models/create_rule_created.rb +207 -0
- data/lib/ory-oathkeeper-client/models/create_rule_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/create_rule_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/create_rule_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/create_rule_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/create_rule_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/create_rule_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/decisions_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/decisions_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/decisions_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/decisions_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/decisions_not_found.rb +207 -0
- data/lib/ory-oathkeeper-client/models/decisions_not_found_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/decisions_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/decisions_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_not_found.rb +207 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_not_found_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/delete_rule_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_rule_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_rule_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_rule_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_rule_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_rule_not_found.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_rule_not_found_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_rule_ok.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_rule_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_rule_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_json_web_keys_ok.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_ok.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/get_well_known_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/health_not_ready_status.rb +209 -0
- data/lib/ory-oathkeeper-client/models/health_status.rb +207 -0
- data/lib/ory-oathkeeper-client/models/inline_response500.rb +253 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/is_instance_alive_ok.rb +207 -0
- data/lib/ory-oathkeeper-client/models/json_web_key.rb +357 -0
- data/lib/ory-oathkeeper-client/models/json_web_key_set.rb +209 -0
- data/lib/ory-oathkeeper-client/models/judge_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/judge_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/judge_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/judge_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/judge_not_found.rb +207 -0
- data/lib/ory-oathkeeper-client/models/judge_not_found_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/judge_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/judge_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/list_rules_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/list_rules_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/list_rules_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/list_rules_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/list_rules_ok.rb +210 -0
- data/lib/ory-oathkeeper-client/models/list_rules_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/list_rules_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/rule.rb +268 -0
- data/lib/ory-oathkeeper-client/models/rule_handler.rb +217 -0
- data/lib/ory-oathkeeper-client/models/rule_match.rb +219 -0
- data/lib/ory-oathkeeper-client/models/swagger_create_rule_parameters.rb +207 -0
- data/lib/ory-oathkeeper-client/models/swagger_get_rule_parameters.rb +213 -0
- data/lib/ory-oathkeeper-client/models/swagger_health_status.rb +208 -0
- data/lib/ory-oathkeeper-client/models/swagger_json_web_key.rb +370 -0
- data/lib/ory-oathkeeper-client/models/swagger_json_web_key_set.rb +210 -0
- data/lib/ory-oathkeeper-client/models/swagger_list_rules_parameters.rb +218 -0
- data/lib/ory-oathkeeper-client/models/swagger_not_ready_status.rb +210 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule.rb +268 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_handler.rb +218 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_match.rb +220 -0
- data/lib/ory-oathkeeper-client/models/swagger_rule_response.rb +207 -0
- data/lib/ory-oathkeeper-client/models/swagger_rules_response.rb +210 -0
- data/lib/ory-oathkeeper-client/models/swagger_update_rule_parameters.rb +222 -0
- data/lib/ory-oathkeeper-client/models/swagger_version.rb +208 -0
- data/lib/ory-oathkeeper-client/models/update_rule_forbidden.rb +207 -0
- data/lib/ory-oathkeeper-client/models/update_rule_forbidden_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/update_rule_internal_server_error.rb +207 -0
- data/lib/ory-oathkeeper-client/models/update_rule_internal_server_error_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/update_rule_not_found.rb +207 -0
- data/lib/ory-oathkeeper-client/models/update_rule_not_found_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/update_rule_ok.rb +207 -0
- data/lib/ory-oathkeeper-client/models/update_rule_unauthorized.rb +207 -0
- data/lib/ory-oathkeeper-client/models/update_rule_unauthorized_body.rb +260 -0
- data/lib/ory-oathkeeper-client/models/upstream.rb +227 -0
- data/lib/ory-oathkeeper-client/models/version.rb +207 -0
- data/lib/ory-oathkeeper-client/version.rb +15 -0
- data/ory-oathkeeper-client.gemspec +39 -0
- data/spec/api/api_api_spec.rb +115 -0
- data/spec/api/health_api_spec.rb +57 -0
- data/spec/api/version_api_spec.rb +46 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/create_rule_created_spec.rb +41 -0
- data/spec/models/create_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/create_rule_forbidden_spec.rb +41 -0
- data/spec/models/create_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/create_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/create_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/create_rule_unauthorized_spec.rb +41 -0
- data/spec/models/decisions_forbidden_body_spec.rb +71 -0
- data/spec/models/decisions_forbidden_spec.rb +41 -0
- data/spec/models/decisions_internal_server_error_body_spec.rb +71 -0
- data/spec/models/decisions_internal_server_error_spec.rb +41 -0
- data/spec/models/decisions_not_found_body_spec.rb +71 -0
- data/spec/models/decisions_not_found_spec.rb +41 -0
- data/spec/models/decisions_unauthorized_body_spec.rb +71 -0
- data/spec/models/decisions_unauthorized_spec.rb +41 -0
- data/spec/models/delete_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/delete_rule_forbidden_spec.rb +41 -0
- data/spec/models/delete_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/delete_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/delete_rule_not_found_body_spec.rb +71 -0
- data/spec/models/delete_rule_not_found_spec.rb +41 -0
- data/spec/models/delete_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/delete_rule_unauthorized_spec.rb +41 -0
- data/spec/models/get_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/get_rule_forbidden_spec.rb +41 -0
- data/spec/models/get_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/get_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/get_rule_not_found_body_spec.rb +71 -0
- data/spec/models/get_rule_not_found_spec.rb +41 -0
- data/spec/models/get_rule_ok_spec.rb +41 -0
- data/spec/models/get_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/get_rule_unauthorized_spec.rb +41 -0
- data/spec/models/get_well_known_forbidden_body_spec.rb +71 -0
- data/spec/models/get_well_known_forbidden_spec.rb +41 -0
- data/spec/models/get_well_known_json_web_keys_internal_server_error_body_spec.rb +71 -0
- data/spec/models/get_well_known_json_web_keys_internal_server_error_spec.rb +41 -0
- data/spec/models/get_well_known_json_web_keys_ok_spec.rb +41 -0
- data/spec/models/get_well_known_ok_spec.rb +41 -0
- data/spec/models/get_well_known_unauthorized_body_spec.rb +71 -0
- data/spec/models/get_well_known_unauthorized_spec.rb +41 -0
- data/spec/models/health_not_ready_status_spec.rb +41 -0
- data/spec/models/health_status_spec.rb +41 -0
- data/spec/models/inline_response500_spec.rb +71 -0
- data/spec/models/is_instance_alive_internal_server_error_body_spec.rb +71 -0
- data/spec/models/is_instance_alive_internal_server_error_spec.rb +41 -0
- data/spec/models/is_instance_alive_ok_spec.rb +41 -0
- data/spec/models/json_web_key_set_spec.rb +41 -0
- data/spec/models/json_web_key_spec.rb +137 -0
- data/spec/models/judge_forbidden_body_spec.rb +71 -0
- data/spec/models/judge_forbidden_spec.rb +41 -0
- data/spec/models/judge_internal_server_error_body_spec.rb +71 -0
- data/spec/models/judge_internal_server_error_spec.rb +41 -0
- data/spec/models/judge_not_found_body_spec.rb +71 -0
- data/spec/models/judge_not_found_spec.rb +41 -0
- data/spec/models/judge_unauthorized_body_spec.rb +71 -0
- data/spec/models/judge_unauthorized_spec.rb +41 -0
- data/spec/models/list_rules_forbidden_body_spec.rb +71 -0
- data/spec/models/list_rules_forbidden_spec.rb +41 -0
- data/spec/models/list_rules_internal_server_error_body_spec.rb +71 -0
- data/spec/models/list_rules_internal_server_error_spec.rb +41 -0
- data/spec/models/list_rules_ok_spec.rb +41 -0
- data/spec/models/list_rules_unauthorized_body_spec.rb +71 -0
- data/spec/models/list_rules_unauthorized_spec.rb +41 -0
- data/spec/models/rule_handler_spec.rb +47 -0
- data/spec/models/rule_match_spec.rb +47 -0
- data/spec/models/rule_spec.rb +77 -0
- data/spec/models/swagger_create_rule_parameters_spec.rb +41 -0
- data/spec/models/swagger_get_rule_parameters_spec.rb +41 -0
- data/spec/models/swagger_health_status_spec.rb +41 -0
- data/spec/models/swagger_json_web_key_set_spec.rb +41 -0
- data/spec/models/swagger_json_web_key_spec.rb +137 -0
- data/spec/models/swagger_list_rules_parameters_spec.rb +47 -0
- data/spec/models/swagger_not_ready_status_spec.rb +41 -0
- data/spec/models/swagger_rule_handler_spec.rb +47 -0
- data/spec/models/swagger_rule_match_spec.rb +47 -0
- data/spec/models/swagger_rule_response_spec.rb +41 -0
- data/spec/models/swagger_rule_spec.rb +77 -0
- data/spec/models/swagger_rules_response_spec.rb +41 -0
- data/spec/models/swagger_update_rule_parameters_spec.rb +47 -0
- data/spec/models/swagger_version_spec.rb +41 -0
- data/spec/models/update_rule_forbidden_body_spec.rb +71 -0
- data/spec/models/update_rule_forbidden_spec.rb +41 -0
- data/spec/models/update_rule_internal_server_error_body_spec.rb +71 -0
- data/spec/models/update_rule_internal_server_error_spec.rb +41 -0
- data/spec/models/update_rule_not_found_body_spec.rb +71 -0
- data/spec/models/update_rule_not_found_spec.rb +41 -0
- data/spec/models/update_rule_ok_spec.rb +41 -0
- data/spec/models/update_rule_unauthorized_body_spec.rb +71 -0
- data/spec/models/update_rule_unauthorized_spec.rb +41 -0
- data/spec/models/upstream_spec.rb +53 -0
- data/spec/models/version_spec.rb +41 -0
- data/spec/spec_helper.rb +111 -0
- metadata +497 -0
@@ -0,0 +1,208 @@
|
|
1
|
+
=begin
|
2
|
+
#ORY Oathkeeper
|
3
|
+
|
4
|
+
#ORY Oathkeeper is a reverse proxy that checks the HTTP Authorization for validity against a set of rules. This service uses Hydra to validate access tokens and policies.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v0.0.0-alpha.37
|
7
|
+
Contact: hi@ory.am
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.2.2
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module OryHydraClient
|
16
|
+
# SwaggerHealthStatus swagger health status
|
17
|
+
class SwaggerHealthStatus
|
18
|
+
# Status always contains \"ok\".
|
19
|
+
attr_accessor :status
|
20
|
+
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
22
|
+
def self.attribute_map
|
23
|
+
{
|
24
|
+
:'status' => :'status'
|
25
|
+
}
|
26
|
+
end
|
27
|
+
|
28
|
+
# Attribute type mapping.
|
29
|
+
def self.openapi_types
|
30
|
+
{
|
31
|
+
:'status' => :'String'
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
# List of attributes with nullable: true
|
36
|
+
def self.openapi_nullable
|
37
|
+
Set.new([
|
38
|
+
])
|
39
|
+
end
|
40
|
+
|
41
|
+
# Initializes the object
|
42
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
43
|
+
def initialize(attributes = {})
|
44
|
+
if (!attributes.is_a?(Hash))
|
45
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `OryHydraClient::SwaggerHealthStatus` initialize method"
|
46
|
+
end
|
47
|
+
|
48
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
49
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
50
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
51
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `OryHydraClient::SwaggerHealthStatus`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
52
|
+
end
|
53
|
+
h[k.to_sym] = v
|
54
|
+
}
|
55
|
+
|
56
|
+
if attributes.key?(:'status')
|
57
|
+
self.status = attributes[:'status']
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
61
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
62
|
+
# @return Array for valid properties with the reasons
|
63
|
+
def list_invalid_properties
|
64
|
+
invalid_properties = Array.new
|
65
|
+
invalid_properties
|
66
|
+
end
|
67
|
+
|
68
|
+
# Check to see if the all the properties in the model are valid
|
69
|
+
# @return true if the model is valid
|
70
|
+
def valid?
|
71
|
+
true
|
72
|
+
end
|
73
|
+
|
74
|
+
# Checks equality by comparing each attribute.
|
75
|
+
# @param [Object] Object to be compared
|
76
|
+
def ==(o)
|
77
|
+
return true if self.equal?(o)
|
78
|
+
self.class == o.class &&
|
79
|
+
status == o.status
|
80
|
+
end
|
81
|
+
|
82
|
+
# @see the `==` method
|
83
|
+
# @param [Object] Object to be compared
|
84
|
+
def eql?(o)
|
85
|
+
self == o
|
86
|
+
end
|
87
|
+
|
88
|
+
# Calculates hash code according to all attributes.
|
89
|
+
# @return [Integer] Hash code
|
90
|
+
def hash
|
91
|
+
[status].hash
|
92
|
+
end
|
93
|
+
|
94
|
+
# Builds the object from hash
|
95
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
96
|
+
# @return [Object] Returns the model itself
|
97
|
+
def self.build_from_hash(attributes)
|
98
|
+
new.build_from_hash(attributes)
|
99
|
+
end
|
100
|
+
|
101
|
+
# Builds the object from hash
|
102
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
103
|
+
# @return [Object] Returns the model itself
|
104
|
+
def build_from_hash(attributes)
|
105
|
+
return nil unless attributes.is_a?(Hash)
|
106
|
+
self.class.openapi_types.each_pair do |key, type|
|
107
|
+
if type =~ /\AArray<(.*)>/i
|
108
|
+
# check to ensure the input is an array given that the attribute
|
109
|
+
# is documented as an array but the input is not
|
110
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
111
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
112
|
+
end
|
113
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
114
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
115
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
116
|
+
end
|
117
|
+
|
118
|
+
self
|
119
|
+
end
|
120
|
+
|
121
|
+
# Deserializes the data based on type
|
122
|
+
# @param string type Data type
|
123
|
+
# @param string value Value to be deserialized
|
124
|
+
# @return [Object] Deserialized data
|
125
|
+
def _deserialize(type, value)
|
126
|
+
case type.to_sym
|
127
|
+
when :DateTime
|
128
|
+
DateTime.parse(value)
|
129
|
+
when :Date
|
130
|
+
Date.parse(value)
|
131
|
+
when :String
|
132
|
+
value.to_s
|
133
|
+
when :Integer
|
134
|
+
value.to_i
|
135
|
+
when :Float
|
136
|
+
value.to_f
|
137
|
+
when :Boolean
|
138
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
139
|
+
true
|
140
|
+
else
|
141
|
+
false
|
142
|
+
end
|
143
|
+
when :Object
|
144
|
+
# generic object (usually a Hash), return directly
|
145
|
+
value
|
146
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
147
|
+
inner_type = Regexp.last_match[:inner_type]
|
148
|
+
value.map { |v| _deserialize(inner_type, v) }
|
149
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
150
|
+
k_type = Regexp.last_match[:k_type]
|
151
|
+
v_type = Regexp.last_match[:v_type]
|
152
|
+
{}.tap do |hash|
|
153
|
+
value.each do |k, v|
|
154
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
155
|
+
end
|
156
|
+
end
|
157
|
+
else # model
|
158
|
+
OryHydraClient.const_get(type).build_from_hash(value)
|
159
|
+
end
|
160
|
+
end
|
161
|
+
|
162
|
+
# Returns the string representation of the object
|
163
|
+
# @return [String] String presentation of the object
|
164
|
+
def to_s
|
165
|
+
to_hash.to_s
|
166
|
+
end
|
167
|
+
|
168
|
+
# to_body is an alias to to_hash (backward compatibility)
|
169
|
+
# @return [Hash] Returns the object in the form of hash
|
170
|
+
def to_body
|
171
|
+
to_hash
|
172
|
+
end
|
173
|
+
|
174
|
+
# Returns the object in the form of hash
|
175
|
+
# @return [Hash] Returns the object in the form of hash
|
176
|
+
def to_hash
|
177
|
+
hash = {}
|
178
|
+
self.class.attribute_map.each_pair do |attr, param|
|
179
|
+
value = self.send(attr)
|
180
|
+
if value.nil?
|
181
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
182
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
183
|
+
end
|
184
|
+
|
185
|
+
hash[param] = _to_hash(value)
|
186
|
+
end
|
187
|
+
hash
|
188
|
+
end
|
189
|
+
|
190
|
+
# Outputs non-array value in the form of hash
|
191
|
+
# For object, use to_hash. Otherwise, just return the value
|
192
|
+
# @param [Object] value Any valid value
|
193
|
+
# @return [Hash] Returns the value in the form of hash
|
194
|
+
def _to_hash(value)
|
195
|
+
if value.is_a?(Array)
|
196
|
+
value.compact.map { |v| _to_hash(v) }
|
197
|
+
elsif value.is_a?(Hash)
|
198
|
+
{}.tap do |hash|
|
199
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
200
|
+
end
|
201
|
+
elsif value.respond_to? :to_hash
|
202
|
+
value.to_hash
|
203
|
+
else
|
204
|
+
value
|
205
|
+
end
|
206
|
+
end
|
207
|
+
end
|
208
|
+
end
|
@@ -0,0 +1,370 @@
|
|
1
|
+
=begin
|
2
|
+
#ORY Oathkeeper
|
3
|
+
|
4
|
+
#ORY Oathkeeper is a reverse proxy that checks the HTTP Authorization for validity against a set of rules. This service uses Hydra to validate access tokens and policies.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v0.0.0-alpha.37
|
7
|
+
Contact: hi@ory.am
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.2.2
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module OryHydraClient
|
16
|
+
# SwaggerJSONWebKey swagger JSON web key
|
17
|
+
class SwaggerJSONWebKey
|
18
|
+
# The \"alg\" (algorithm) parameter identifies the algorithm intended for use with the key. The values used should either be registered in the IANA \"JSON Web Signature and Encryption Algorithms\" registry established by [JWA] or be a value that contains a Collision- Resistant Name.
|
19
|
+
attr_accessor :alg
|
20
|
+
|
21
|
+
# crv
|
22
|
+
attr_accessor :crv
|
23
|
+
|
24
|
+
# d
|
25
|
+
attr_accessor :d
|
26
|
+
|
27
|
+
# dp
|
28
|
+
attr_accessor :dp
|
29
|
+
|
30
|
+
# dq
|
31
|
+
attr_accessor :dq
|
32
|
+
|
33
|
+
# e
|
34
|
+
attr_accessor :e
|
35
|
+
|
36
|
+
# k
|
37
|
+
attr_accessor :k
|
38
|
+
|
39
|
+
# The \"kid\" (key ID) parameter is used to match a specific key. This is used, for instance, to choose among a set of keys within a JWK Set during key rollover. The structure of the \"kid\" value is unspecified. When \"kid\" values are used within a JWK Set, different keys within the JWK Set SHOULD use distinct \"kid\" values. (One example in which different keys might use the same \"kid\" value is if they have different \"kty\" (key type) values but are considered to be equivalent alternatives by the application using them.) The \"kid\" value is a case-sensitive string.
|
40
|
+
attr_accessor :kid
|
41
|
+
|
42
|
+
# The \"kty\" (key type) parameter identifies the cryptographic algorithm family used with the key, such as \"RSA\" or \"EC\". \"kty\" values should either be registered in the IANA \"JSON Web Key Types\" registry established by [JWA] or be a value that contains a Collision- Resistant Name. The \"kty\" value is a case-sensitive string.
|
43
|
+
attr_accessor :kty
|
44
|
+
|
45
|
+
# n
|
46
|
+
attr_accessor :n
|
47
|
+
|
48
|
+
# p
|
49
|
+
attr_accessor :p
|
50
|
+
|
51
|
+
# q
|
52
|
+
attr_accessor :q
|
53
|
+
|
54
|
+
# qi
|
55
|
+
attr_accessor :qi
|
56
|
+
|
57
|
+
# The \"use\" (public key use) parameter identifies the intended use of the public key. The \"use\" parameter is employed to indicate whether a public key is used for encrypting data or verifying the signature on data. Values are commonly \"sig\" (signature) or \"enc\" (encryption).
|
58
|
+
attr_accessor :use
|
59
|
+
|
60
|
+
# x
|
61
|
+
attr_accessor :x
|
62
|
+
|
63
|
+
# The \"x5c\" (X.509 certificate chain) parameter contains a chain of one or more PKIX certificates [RFC5280]. The certificate chain is represented as a JSON array of certificate value strings. Each string in the array is a base64-encoded (Section 4 of [RFC4648] -- not base64url-encoded) DER [ITU.X690.1994] PKIX certificate value. The PKIX certificate containing the key value MUST be the first certificate.
|
64
|
+
attr_accessor :x5c
|
65
|
+
|
66
|
+
# y
|
67
|
+
attr_accessor :y
|
68
|
+
|
69
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
70
|
+
def self.attribute_map
|
71
|
+
{
|
72
|
+
:'alg' => :'alg',
|
73
|
+
:'crv' => :'crv',
|
74
|
+
:'d' => :'d',
|
75
|
+
:'dp' => :'dp',
|
76
|
+
:'dq' => :'dq',
|
77
|
+
:'e' => :'e',
|
78
|
+
:'k' => :'k',
|
79
|
+
:'kid' => :'kid',
|
80
|
+
:'kty' => :'kty',
|
81
|
+
:'n' => :'n',
|
82
|
+
:'p' => :'p',
|
83
|
+
:'q' => :'q',
|
84
|
+
:'qi' => :'qi',
|
85
|
+
:'use' => :'use',
|
86
|
+
:'x' => :'x',
|
87
|
+
:'x5c' => :'x5c',
|
88
|
+
:'y' => :'y'
|
89
|
+
}
|
90
|
+
end
|
91
|
+
|
92
|
+
# Attribute type mapping.
|
93
|
+
def self.openapi_types
|
94
|
+
{
|
95
|
+
:'alg' => :'String',
|
96
|
+
:'crv' => :'String',
|
97
|
+
:'d' => :'String',
|
98
|
+
:'dp' => :'String',
|
99
|
+
:'dq' => :'String',
|
100
|
+
:'e' => :'String',
|
101
|
+
:'k' => :'String',
|
102
|
+
:'kid' => :'String',
|
103
|
+
:'kty' => :'String',
|
104
|
+
:'n' => :'String',
|
105
|
+
:'p' => :'String',
|
106
|
+
:'q' => :'String',
|
107
|
+
:'qi' => :'String',
|
108
|
+
:'use' => :'String',
|
109
|
+
:'x' => :'String',
|
110
|
+
:'x5c' => :'Array<String>',
|
111
|
+
:'y' => :'String'
|
112
|
+
}
|
113
|
+
end
|
114
|
+
|
115
|
+
# List of attributes with nullable: true
|
116
|
+
def self.openapi_nullable
|
117
|
+
Set.new([
|
118
|
+
])
|
119
|
+
end
|
120
|
+
|
121
|
+
# Initializes the object
|
122
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
123
|
+
def initialize(attributes = {})
|
124
|
+
if (!attributes.is_a?(Hash))
|
125
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `OryHydraClient::SwaggerJSONWebKey` initialize method"
|
126
|
+
end
|
127
|
+
|
128
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
129
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
130
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
131
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `OryHydraClient::SwaggerJSONWebKey`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
132
|
+
end
|
133
|
+
h[k.to_sym] = v
|
134
|
+
}
|
135
|
+
|
136
|
+
if attributes.key?(:'alg')
|
137
|
+
self.alg = attributes[:'alg']
|
138
|
+
end
|
139
|
+
|
140
|
+
if attributes.key?(:'crv')
|
141
|
+
self.crv = attributes[:'crv']
|
142
|
+
end
|
143
|
+
|
144
|
+
if attributes.key?(:'d')
|
145
|
+
self.d = attributes[:'d']
|
146
|
+
end
|
147
|
+
|
148
|
+
if attributes.key?(:'dp')
|
149
|
+
self.dp = attributes[:'dp']
|
150
|
+
end
|
151
|
+
|
152
|
+
if attributes.key?(:'dq')
|
153
|
+
self.dq = attributes[:'dq']
|
154
|
+
end
|
155
|
+
|
156
|
+
if attributes.key?(:'e')
|
157
|
+
self.e = attributes[:'e']
|
158
|
+
end
|
159
|
+
|
160
|
+
if attributes.key?(:'k')
|
161
|
+
self.k = attributes[:'k']
|
162
|
+
end
|
163
|
+
|
164
|
+
if attributes.key?(:'kid')
|
165
|
+
self.kid = attributes[:'kid']
|
166
|
+
end
|
167
|
+
|
168
|
+
if attributes.key?(:'kty')
|
169
|
+
self.kty = attributes[:'kty']
|
170
|
+
end
|
171
|
+
|
172
|
+
if attributes.key?(:'n')
|
173
|
+
self.n = attributes[:'n']
|
174
|
+
end
|
175
|
+
|
176
|
+
if attributes.key?(:'p')
|
177
|
+
self.p = attributes[:'p']
|
178
|
+
end
|
179
|
+
|
180
|
+
if attributes.key?(:'q')
|
181
|
+
self.q = attributes[:'q']
|
182
|
+
end
|
183
|
+
|
184
|
+
if attributes.key?(:'qi')
|
185
|
+
self.qi = attributes[:'qi']
|
186
|
+
end
|
187
|
+
|
188
|
+
if attributes.key?(:'use')
|
189
|
+
self.use = attributes[:'use']
|
190
|
+
end
|
191
|
+
|
192
|
+
if attributes.key?(:'x')
|
193
|
+
self.x = attributes[:'x']
|
194
|
+
end
|
195
|
+
|
196
|
+
if attributes.key?(:'x5c')
|
197
|
+
if (value = attributes[:'x5c']).is_a?(Array)
|
198
|
+
self.x5c = value
|
199
|
+
end
|
200
|
+
end
|
201
|
+
|
202
|
+
if attributes.key?(:'y')
|
203
|
+
self.y = attributes[:'y']
|
204
|
+
end
|
205
|
+
end
|
206
|
+
|
207
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
208
|
+
# @return Array for valid properties with the reasons
|
209
|
+
def list_invalid_properties
|
210
|
+
invalid_properties = Array.new
|
211
|
+
invalid_properties
|
212
|
+
end
|
213
|
+
|
214
|
+
# Check to see if the all the properties in the model are valid
|
215
|
+
# @return true if the model is valid
|
216
|
+
def valid?
|
217
|
+
true
|
218
|
+
end
|
219
|
+
|
220
|
+
# Checks equality by comparing each attribute.
|
221
|
+
# @param [Object] Object to be compared
|
222
|
+
def ==(o)
|
223
|
+
return true if self.equal?(o)
|
224
|
+
self.class == o.class &&
|
225
|
+
alg == o.alg &&
|
226
|
+
crv == o.crv &&
|
227
|
+
d == o.d &&
|
228
|
+
dp == o.dp &&
|
229
|
+
dq == o.dq &&
|
230
|
+
e == o.e &&
|
231
|
+
k == o.k &&
|
232
|
+
kid == o.kid &&
|
233
|
+
kty == o.kty &&
|
234
|
+
n == o.n &&
|
235
|
+
p == o.p &&
|
236
|
+
q == o.q &&
|
237
|
+
qi == o.qi &&
|
238
|
+
use == o.use &&
|
239
|
+
x == o.x &&
|
240
|
+
x5c == o.x5c &&
|
241
|
+
y == o.y
|
242
|
+
end
|
243
|
+
|
244
|
+
# @see the `==` method
|
245
|
+
# @param [Object] Object to be compared
|
246
|
+
def eql?(o)
|
247
|
+
self == o
|
248
|
+
end
|
249
|
+
|
250
|
+
# Calculates hash code according to all attributes.
|
251
|
+
# @return [Integer] Hash code
|
252
|
+
def hash
|
253
|
+
[alg, crv, d, dp, dq, e, k, kid, kty, n, p, q, qi, use, x, x5c, y].hash
|
254
|
+
end
|
255
|
+
|
256
|
+
# Builds the object from hash
|
257
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
258
|
+
# @return [Object] Returns the model itself
|
259
|
+
def self.build_from_hash(attributes)
|
260
|
+
new.build_from_hash(attributes)
|
261
|
+
end
|
262
|
+
|
263
|
+
# Builds the object from hash
|
264
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
265
|
+
# @return [Object] Returns the model itself
|
266
|
+
def build_from_hash(attributes)
|
267
|
+
return nil unless attributes.is_a?(Hash)
|
268
|
+
self.class.openapi_types.each_pair do |key, type|
|
269
|
+
if type =~ /\AArray<(.*)>/i
|
270
|
+
# check to ensure the input is an array given that the attribute
|
271
|
+
# is documented as an array but the input is not
|
272
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
273
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
274
|
+
end
|
275
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
276
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
277
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
278
|
+
end
|
279
|
+
|
280
|
+
self
|
281
|
+
end
|
282
|
+
|
283
|
+
# Deserializes the data based on type
|
284
|
+
# @param string type Data type
|
285
|
+
# @param string value Value to be deserialized
|
286
|
+
# @return [Object] Deserialized data
|
287
|
+
def _deserialize(type, value)
|
288
|
+
case type.to_sym
|
289
|
+
when :DateTime
|
290
|
+
DateTime.parse(value)
|
291
|
+
when :Date
|
292
|
+
Date.parse(value)
|
293
|
+
when :String
|
294
|
+
value.to_s
|
295
|
+
when :Integer
|
296
|
+
value.to_i
|
297
|
+
when :Float
|
298
|
+
value.to_f
|
299
|
+
when :Boolean
|
300
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
301
|
+
true
|
302
|
+
else
|
303
|
+
false
|
304
|
+
end
|
305
|
+
when :Object
|
306
|
+
# generic object (usually a Hash), return directly
|
307
|
+
value
|
308
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
309
|
+
inner_type = Regexp.last_match[:inner_type]
|
310
|
+
value.map { |v| _deserialize(inner_type, v) }
|
311
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
312
|
+
k_type = Regexp.last_match[:k_type]
|
313
|
+
v_type = Regexp.last_match[:v_type]
|
314
|
+
{}.tap do |hash|
|
315
|
+
value.each do |k, v|
|
316
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
317
|
+
end
|
318
|
+
end
|
319
|
+
else # model
|
320
|
+
OryHydraClient.const_get(type).build_from_hash(value)
|
321
|
+
end
|
322
|
+
end
|
323
|
+
|
324
|
+
# Returns the string representation of the object
|
325
|
+
# @return [String] String presentation of the object
|
326
|
+
def to_s
|
327
|
+
to_hash.to_s
|
328
|
+
end
|
329
|
+
|
330
|
+
# to_body is an alias to to_hash (backward compatibility)
|
331
|
+
# @return [Hash] Returns the object in the form of hash
|
332
|
+
def to_body
|
333
|
+
to_hash
|
334
|
+
end
|
335
|
+
|
336
|
+
# Returns the object in the form of hash
|
337
|
+
# @return [Hash] Returns the object in the form of hash
|
338
|
+
def to_hash
|
339
|
+
hash = {}
|
340
|
+
self.class.attribute_map.each_pair do |attr, param|
|
341
|
+
value = self.send(attr)
|
342
|
+
if value.nil?
|
343
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
344
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
345
|
+
end
|
346
|
+
|
347
|
+
hash[param] = _to_hash(value)
|
348
|
+
end
|
349
|
+
hash
|
350
|
+
end
|
351
|
+
|
352
|
+
# Outputs non-array value in the form of hash
|
353
|
+
# For object, use to_hash. Otherwise, just return the value
|
354
|
+
# @param [Object] value Any valid value
|
355
|
+
# @return [Hash] Returns the value in the form of hash
|
356
|
+
def _to_hash(value)
|
357
|
+
if value.is_a?(Array)
|
358
|
+
value.compact.map { |v| _to_hash(v) }
|
359
|
+
elsif value.is_a?(Hash)
|
360
|
+
{}.tap do |hash|
|
361
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
362
|
+
end
|
363
|
+
elsif value.respond_to? :to_hash
|
364
|
+
value.to_hash
|
365
|
+
else
|
366
|
+
value
|
367
|
+
end
|
368
|
+
end
|
369
|
+
end
|
370
|
+
end
|