Sha256: e1f25cfe0b278d437b1bbdcee7d6cec24125a38f36d7c06680a5327c448c35c7
Contents?: true
Size: 960 Bytes
Versions: 6
Compression:
Stored size: 960 Bytes
Contents
# frozen_string_literal: true ## # This file is part of WhatWeb and may be subject to # redistribution and commercial restrictions. Please see the WhatWeb # web site for more information on licensing and terms of use. # http://www.morningstarsecurity.com/research/whatweb ## WhatWeb::Plugin.define "Teapot" do @author = "Brendan Coles <bcoles@gmail.com>" # 2011-03-14 @version = "0.1" @description = "HTCPCP, a protocol for controlling, monitoring, and diagnosing coffee pots." @website = "http://www.apps.ietf.org/rfc/rfc2324.html" # ShodanHQ results as at 2011-03-14 # # 6 for 418 teapot # Passive # def passive(target) m = [] # HTCPCP 418 Status Code if @status == 418 m << if /<title>([^<]+)<\/title>/i.match?(target.body) { string: target.body.scan(/<title>([^<]+)<\/title>/i) } else { string: "I'm a teapot" } end end # Return passive matches m end end
Version data entries
6 entries across 6 versions & 1 rubygems