mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 09:57:23 +02:00
Story #107192666 - only show dsData if allowed, or keyData if allowed
This commit is contained in:
parent
0c21f9b304
commit
714b8364cb
1 changed files with 6 additions and 7 deletions
|
@ -81,18 +81,17 @@ xml.epp_head do
|
||||||
end
|
end
|
||||||
|
|
||||||
xml.tag!('secDNS:infData', 'xmlns:secDNS' => 'urn:ietf:params:xml:ns:secDNS-1.1') do
|
xml.tag!('secDNS:infData', 'xmlns:secDNS' => 'urn:ietf:params:xml:ns:secDNS-1.1') do
|
||||||
# might not have ds in first key? maybe check any? k.ds_digest if requirements change (DS not accepted by EIS)
|
if Setting.ds_data_allowed
|
||||||
if @domain.dnskeys[0].ds_digest.blank?
|
(@domain.dnskeys.find_all { |key| key.ds_digest.present? }).sort.each do |key|
|
||||||
@domain.dnskeys.sort.each do |key|
|
tag_ds_data(xml, key)
|
||||||
tag_key_data(xml, key)
|
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
@domain.dnskeys.sort.each do |key|
|
(@domain.dnskeys.find_all { |key| key.ds_digest.blank? }).sort.each do |key|
|
||||||
tag_ds_data(xml, key)
|
tag_key_data(xml, key)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end if @domain.dnskeys.any?
|
end if @domain.dnskeys.any? && (Setting.ds_data_allowed ? @domain.dnskeys.any? { |key| key.ds_digest.present? } : Setting.key_data_allowed)
|
||||||
|
|
||||||
render('epp/shared/trID', builder: xml)
|
render('epp/shared/trID', builder: xml)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue