mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 17:37:17 +02:00
parent
787cca8e4c
commit
35afbf1f8c
15 changed files with 304 additions and 54 deletions
|
@ -15,7 +15,7 @@ module Repp
|
|||
before do
|
||||
webclient_request = ENV['webclient_ips'].split(',').map(&:strip).include?(request.ip)
|
||||
unless webclient_request
|
||||
error! I18n.t('ip_is_not_whitelisted'), 401 unless @current_user.registrar.api_ip_white?(request.ip)
|
||||
error! I18n.t('api.authorization.ip_not_allowed', ip: request.ip), 401 unless @current_user.registrar.api_ip_white?(request.ip)
|
||||
end
|
||||
|
||||
if @current_user.cannot?(:view, :repp)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue