Sha256: 57bdd5e46caf55f85d8b2f54070e2d6e8d1eb21633a59fc6bd0e69a85c96a4d2

Contents?: true

Size: 1.25 KB

Versions: 8

Compression:

Stored size: 1.25 KB

Contents

require 'metasploit/model/translation'

module Metasploit
  module Model
    # Code shared between `Mdm::Author` and `Metasploit::Framework::Author`.
    module Author
      extend ActiveModel::Naming
      extend ActiveSupport::Concern

      include Metasploit::Model::Translation

      included do
        include ActiveModel::MassAssignmentSecurity
        include ActiveModel::Validations
        include Metasploit::Model::Search

        #
        # Mass Assignment Security
        #

        attr_accessible :name

        #
        # Search Attributes
        #

        search_attribute :name, :type => :string

        #
        # Validations
        #

        validates :name, :presence => true
      end

      #
      # Associations
      #

      # @!attribute [r] email_addresses
      #   Email addresses used by this author across all {#module_instances}.
      #
      #   @return [Array<Metasploit::Model::EmailAddress>]

      # @!attribute [r] module_instances
      #   Modules written by this author.
      #
      #   @return [Array<Metasploit::Model::Module::Instance>]

      #
      # Attributes
      #

      # @!attribute [rw] name
      #   Full name (First + Last name) or handle of author.
      #
      #   @return [String]
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
metasploit-model-0.27.3 lib/metasploit/model/author.rb
metasploit-model-0.27.3-java lib/metasploit/model/author.rb
metasploit-model-0.27.2 lib/metasploit/model/author.rb
metasploit-model-0.27.2-java lib/metasploit/model/author.rb
metasploit-model-0.27.1 lib/metasploit/model/author.rb
metasploit-model-0.27.1-java lib/metasploit/model/author.rb
metasploit-model-0.27.0 lib/metasploit/model/author.rb
metasploit-model-0.27.0-java lib/metasploit/model/author.rb