mirror of
https://github.com/internetee/registry.git
synced 2025-08-12 12:39:34 +02:00
Plug in shunter gem
This commit is contained in:
parent
ded19f8083
commit
4db0ab558f
2 changed files with 9 additions and 0 deletions
|
@ -6,6 +6,9 @@ module Epp
|
||||||
before_action :set_paper_trail_whodunnit
|
before_action :set_paper_trail_whodunnit
|
||||||
before_action :parse_schemas_prefix_and_version
|
before_action :parse_schemas_prefix_and_version
|
||||||
|
|
||||||
|
THROTTLED_ACTIONS = %i[info renew update transfer delete].freeze
|
||||||
|
include Shunter::Integration::Throttle
|
||||||
|
|
||||||
def info
|
def info
|
||||||
authorize! :info, @domain
|
authorize! :info, @domain
|
||||||
|
|
||||||
|
@ -131,6 +134,11 @@ module Epp
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
||||||
|
def throttled_user
|
||||||
|
authorize!(:throttled_user, @domain) unless current_user
|
||||||
|
current_user
|
||||||
|
end
|
||||||
|
|
||||||
def validate_info
|
def validate_info
|
||||||
@prefix = 'info > info >'
|
@prefix = 'info > info >'
|
||||||
requires('name')
|
requires('name')
|
||||||
|
|
|
@ -197,6 +197,7 @@ test:
|
||||||
cdns_scanner_output_file: 'test/fixtures/files/cdns_output.txt'
|
cdns_scanner_output_file: 'test/fixtures/files/cdns_output.txt'
|
||||||
dnssec_resolver_ips: 8.8.8.8, 8.8.4.4
|
dnssec_resolver_ips: 8.8.8.8, 8.8.4.4
|
||||||
legal_documents_dir: 'test/fixtures/files'
|
legal_documents_dir: 'test/fixtures/files'
|
||||||
|
shunter_default_adapter: "Shunter::Adapters::Memory"
|
||||||
|
|
||||||
openssl_config_path: 'test/fixtures/files/test_ca/openssl.cnf'
|
openssl_config_path: 'test/fixtures/files/test_ca/openssl.cnf'
|
||||||
crl_dir: 'test/fixtures/files/test_ca/crl'
|
crl_dir: 'test/fixtures/files/test_ca/crl'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue