Sha256: 5a703e1d65e7a8d5b23f6220497b7fe2394342ff369220e69b1c15621fecba65
Contents?: true
Size: 451 Bytes
Versions: 8
Compression:
Stored size: 451 Bytes
Contents
# frozen_string_literal: true module Mihari class ReverseDnsName < ActiveRecord::Base belongs_to :artifact class << self # # Build reverse DNS names # # @param [String] ip # # @return [Array<Mihari::ReverseDnsName>] # def build_by_ip(ip) names = Resolv.getnames(ip) names.map { |name| new(name: name) } rescue Resolv::ResolvError [] end end end end
Version data entries
8 entries across 8 versions & 1 rubygems