class Nexpose::WebCredentials::HTMLForms
When using HTML form, this represents the login form information.
Attributes
baseURL[R]
Base URL of the application for which the form authentication applies.
enabled[RW]
is this enable for the site configuration
form[R]
The forms to authenticate with
id[R]
id of the header
loginURL[R]
The URL of the login page containing the login form.
name[R]
name of the html header
service[R]
service type of header
soft403Pattern[R]
A regular expression used to match against the response to identify authentication failures.
Public Class Methods
new(name, baseURL, loginURL, soft403Pattern, id = -1, enabled = true)
click to toggle source
# File lib/nexpose/web_credentials.rb, line 202 def initialize(name, baseURL, loginURL, soft403Pattern, id = -1, enabled = true) @name = name @baseURL = baseURL @loginURL = loginURL @soft403Pattern = soft403Pattern @service = WebAppAuthType::HTML_FORM @enabled = enabled @id = id end
Public Instance Methods
==(other)
click to toggle source
# File lib/nexpose/web_credentials.rb, line 231 def ==(other) eql?(other) end
add_html_form(html_form)
click to toggle source
# File lib/nexpose/web_credentials.rb, line 212 def add_html_form(html_form) @form = html_form end
eql?(other)
click to toggle source
# File lib/nexpose/web_credentials.rb, line 235 def eql?(other) id.eql?(other.id) && service.eql?(other.service) && enabled.eql?(other.enabled) && name.eql?(other.name) && form.eql?(other.form) && baseURL.eql?(other.baseURL) && loginURL.eql?(other.loginURL) && soft403Pattern.eql?(other.soft403Pattern) end
to_h()
click to toggle source
# File lib/nexpose/web_credentials.rb, line 220 def to_h { id: id, service: service, enabled: enabled, name: name, form: form.to_h, baseURL: baseURL, loginURL: loginURL, soft403Pattern: soft403Pattern } end
to_json()
click to toggle source
# File lib/nexpose/web_credentials.rb, line 216 def to_json JSON.generate(to_h) end