2017-09-27 17:27:39 +00:00
|
|
|
class GpgKeySubkey < ActiveRecord::Base
|
2017-09-28 00:45:19 +00:00
|
|
|
include ShaAttribute
|
|
|
|
|
|
|
|
sha_attribute :keyid
|
|
|
|
sha_attribute :fingerprint
|
|
|
|
|
2017-09-27 17:27:39 +00:00
|
|
|
belongs_to :gpg_key
|
2017-09-28 00:45:19 +00:00
|
|
|
|
|
|
|
def method_missing(m, *a, &b)
|
|
|
|
return super unless gpg_key.respond_to?(m)
|
|
|
|
|
|
|
|
gpg_key.public_send(m, *a, &b) # rubocop:disable GitlabSecurity/PublicSend
|
|
|
|
end
|
|
|
|
|
|
|
|
def respond_to_missing?(method, include_private = false)
|
|
|
|
gpg_key.respond_to?(method, include_private) || super
|
|
|
|
end
|
2017-09-27 17:27:39 +00:00
|
|
|
end
|