DNSSEC refactor

This commit is contained in:
Martin Lensment 2014-10-09 13:59:52 +03:00
parent 6f12af5e0b
commit 3453b7f4a1
14 changed files with 150 additions and 30 deletions

View file

@ -1,9 +1,9 @@
class AddDnskeySettings < ActiveRecord::Migration
def change
sg = SettingGroup.create(code: 'dnskeys')
sg.settings << Setting.create(code: 'ds_algorithm', value: 1)
sg.settings << Setting.create(code: 'allow_ds_data', value: 1)
sg.settings << Setting.create(code: 'allow_ds_data_with_keys', value: 1)
sg.settings << Setting.create(code: 'allow_key_data', value: 1)
sg.settings << Setting.create(code: Setting::DS_ALGORITHM, value: 1)
sg.settings << Setting.create(code: Setting::ALLOW_DS_DATA, value: 1)
sg.settings << Setting.create(code: Setting::ALLOW_DS_DATA_WITH_KEYS, value: 1)
sg.settings << Setting.create(code: Setting::ALLOW_KEY_DATA, value: 1)
end
end

View file

@ -0,0 +1,10 @@
class CreateDelegationSigner < ActiveRecord::Migration
def change
create_table :delegation_signers do |t|
t.integer :domain_id
t.string :key_tag
t.integer :digest_type
t.string :digest
end
end
end

View file

@ -0,0 +1,5 @@
class AddDelegationSignerToDnskey < ActiveRecord::Migration
def change
add_column :dnskeys, :delegation_signer_id, :integer
end
end