Ensure EPP session id is passed

This commit is contained in:
Artur Beljajev 2018-02-14 02:13:55 +02:00
parent 66b03e6d11
commit 17fefcf592

View file

@ -4,6 +4,7 @@ class EppController < ApplicationController
protect_from_forgery with: :null_session
skip_before_action :verify_authenticity_token
before_action :ensure_session_id_passed
before_action :generate_svtrid
before_action :latin_only
before_action :validate_against_schema
@ -377,7 +378,11 @@ class EppController < ApplicationController
end
def epp_session_id
cookies[:session]
cookies[:session] # Passed by mod_epp https://github.com/mod-epp/mod-epp#requestscript-interface
end
def ensure_session_id_passed
raise 'EPP session id is empty' unless epp_session_id.present?
end
def update_epp_session