Sha256: 57a31daaa4d7b60d34eef76d2655b7c8ce80890879fa50fdd527e11da0951b64
Contents?: true
Size: 413 Bytes
Versions: 8
Compression:
Stored size: 413 Bytes
Contents
# frozen_string_literal: true module Mihari class Port < ActiveRecord::Base belongs_to :artifact class << self # # Build ports # # @param [String] ip # # @return [Array<Mihari::Port>] # def build_by_ip(ip) res = Enrichers::Shodan.query(ip) return if res.nil? res.ports.map { |port| new(port: port) } end end end end
Version data entries
8 entries across 8 versions & 1 rubygems