Exception: WPScan::Error::WpAuthEndpointUnavailable

Inherits:
Standard
  • Object
show all
Defined in:
lib/wpscan/errors/wp_auth.rb

Overview

Raised when the WP REST plugins/themes endpoint is unreachable for reasons other than authentication (404, 5xx, security plugins blocking /wp-json, …).

Instance Method Summary collapse

Constructor Details

#initialize(code, url) ⇒ WpAuthEndpointUnavailable

Returns a new instance of WpAuthEndpointUnavailable.



25
26
27
28
29
# File 'lib/wpscan/errors/wp_auth.rb', line 25

def initialize(code, url)
  super()
  @code = code
  @url  = url
end

Instance Method Details

#to_sObject



31
32
33
34
# File 'lib/wpscan/errors/wp_auth.rb', line 31

def to_s
  "Authenticated REST API endpoint #{@url} returned HTTP #{@code}. " \
    'The endpoint may be disabled, blocked, or require WordPress 5.5+.'
end