Sha256: 5327982a962dfc64ad9d0d5a16fa903fb6616fbef0f5a2253ba120d8b3caed23
Contents?: true
Size: 899 Bytes
Versions: 27
Compression:
Stored size: 899 Bytes
Contents
# frozen_string_literal: true require "mihari/feed/reader" require "mihari/feed/parser" module Mihari module Analyzers class Feed < Base param :query option :http_request_method, default: proc { "GET" } option :http_request_headers, default: proc { {} } option :http_request_payload, default: proc { {} } option :http_request_payload_type, default: proc {} option :selector, default: proc { "" } def artifacts Mihari::Feed::Parser.new(data).parse selector end private def data reader = Mihari::Feed::Reader.new( query, http_request_method: http_request_method, http_request_headers: http_request_headers, http_request_payload: http_request_payload, http_request_payload_type: http_request_payload_type ) reader.read end end end end
Version data entries
27 entries across 27 versions & 1 rubygems