Sha256: 197019a1a0095b1097286b9e9ad349662cb99322c3e48f585439856e4269d126
Contents?: true
Size: 416 Bytes
Versions: 27
Compression:
Stored size: 416 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
27 entries across 27 versions & 1 rubygems