components/checks/passive/grep/x_frame_options.rb in arachni-1.5.1 vs components/checks/passive/grep/x_frame_options.rb in arachni-1.6.0
- old
+ new
@@ -1,21 +1,21 @@
=begin
- Copyright 2010-2017 Sarosys LLC <http://www.sarosys.com>
+ Copyright 2010-2022 Ecsypno <http://www.ecsypno.com>
This file is part of the Arachni Framework project and is subject to
redistribution and commercial restrictions. Please see the Arachni Framework
web site for more information on licensing and terms of use.
=end
# @author Tasos Laskos <tasos.laskos@arachni-scanner.com>
-# @version 0.1.2
class Arachni::Checks::XFrameOptions < Arachni::Check::Base
def run
return if audited?( page.parsed_url.host ) ||
page.response.headers.empty? ||
- page.response.headers['X-Frame-Options']
+ !page.response.headers['X-Frame-Options'].to_s.empty? || page.code != 200
+
audited( page.parsed_url.host )
log(
vector: Element::Server.new( page.url ),
proof: page.response.status_line
@@ -25,10 +25,10 @@
def self.info
{
name: 'Missing X-Frame-Options header',
description: %q{Checks the host for a missing `X-Frame-Options` header.},
author: 'Tasos Laskos <tasos.laskos@arachni-scanner.com>',
- version: '0.1.2',
+ version: '0.1.3',
elements: [ Element::Server ],
issue: {
name: %q{Missing 'X-Frame-Options' header},
description: %q{