Class AccessRule.Builder
- java.lang.Object
- 
- com.oracle.bmc.waas.model.AccessRule.Builder
 
- 
- Enclosing class:
- AccessRule
 
 public static class AccessRule.Builder extends Object 
- 
- 
Constructor SummaryConstructors Constructor Description Builder()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description AccessRule.Builderaction(AccessRule.Action action)The action to take when the access criteria are met for a rule.AccessRule.BuilderblockAction(AccessRule.BlockAction blockAction)The method used to block requests if action is set to BLOCK and the access criteria are met.AccessRule.BuilderblockErrorPageCode(String blockErrorPageCode)The error code to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.AccessRule.BuilderblockErrorPageDescription(String blockErrorPageDescription)The description text to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.AccessRule.BuilderblockErrorPageMessage(String blockErrorPageMessage)The message to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.AccessRule.BuilderblockResponseCode(Integer blockResponseCode)The response status code to return when action is set to BLOCK, blockAction is set to SET_RESPONSE_CODE, and the access criteria are met.AccessRulebuild()AccessRule.BuilderbypassChallenges(List<AccessRule.BypassChallenges> bypassChallenges)The list of challenges to bypass when action is set to BYPASS.AccessRule.BuildercaptchaFooter(String captchaFooter)The text to show in the footer when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.AccessRule.BuildercaptchaHeader(String captchaHeader)The text to show in the header when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.AccessRule.BuildercaptchaSubmitLabel(String captchaSubmitLabel)The text to show on the label of the CAPTCHA challenge submit button when action is set to SHOW_CAPTCHA and the request is challenged.AccessRule.BuildercaptchaTitle(String captchaTitle)The title used when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.AccessRule.Buildercopy(AccessRule model)AccessRule.Buildercriteria(List<AccessRuleCriteria> criteria)The list of access rule criteria.AccessRule.Buildername(String name)The unique name of the access rule.AccessRule.BuilderredirectResponseCode(AccessRule.RedirectResponseCode redirectResponseCode)The response status code to return when action is set to REDIRECT.AccessRule.BuilderredirectUrl(String redirectUrl)The target to which the request should be redirected, represented as a URI reference.AccessRule.BuilderresponseHeaderManipulation(List<HeaderManipulationAction> responseHeaderManipulation)An object that represents an action to apply to an HTTP response headers if all rule criteria will be matched regardless of action value.
 
- 
- 
- 
Method Detail- 
namepublic AccessRule.Builder name(String name) The unique name of the access rule.- Parameters:
- name- the value to set
- Returns:
- this builder
 
 - 
criteriapublic AccessRule.Builder criteria(List<AccessRuleCriteria> criteria) The list of access rule criteria.The rule would be applied only for the requests that matched all the listed conditions. - Parameters:
- criteria- the value to set
- Returns:
- this builder
 
 - 
actionpublic AccessRule.Builder action(AccessRule.Action action) The action to take when the access criteria are met for a rule.If unspecified, defaults to ALLOW. - **ALLOW:** Takes no action, just logs the request. - **DETECT:** Takes no action, but creates an alert for the request. - **BLOCK:** Blocks the request by returning specified response code or showing error page. - **BYPASS:** Bypasses some or all challenges. - **REDIRECT:** Redirects the request to the specified URL. These fields are required when REDIRECT is selected: redirectUrl, redirectResponseCode. - **SHOW_CAPTCHA:** Show a CAPTCHA Challenge page instead of the requested page. Regardless of action, no further rules are processed once a rule is matched. - Parameters:
- action- the value to set
- Returns:
- this builder
 
 - 
blockActionpublic AccessRule.Builder blockAction(AccessRule.BlockAction blockAction) The method used to block requests if action is set to BLOCK and the access criteria are met.If unspecified, defaults to SET_RESPONSE_CODE. - Parameters:
- blockAction- the value to set
- Returns:
- this builder
 
 - 
blockResponseCodepublic AccessRule.Builder blockResponseCode(Integer blockResponseCode) The response status code to return when action is set to BLOCK, blockAction is set to SET_RESPONSE_CODE, and the access criteria are met.If unspecified, defaults to 403. The list of available response codes: 200, 201, 202, 204, 206, 300, 301, 302, 303, 304, 307, 400, 401, 403, 404, 405, 408, 409, 411, 412, 413, 414, 415, 416, 422, 444, 494, 495, 496, 497, 499, 500, 501, 502, 503, 504, 507. - Parameters:
- blockResponseCode- the value to set
- Returns:
- this builder
 
 - 
blockErrorPageMessagepublic AccessRule.Builder blockErrorPageMessage(String blockErrorPageMessage) The message to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.If unspecified, defaults to ‘Access to the website is blocked.’ - Parameters:
- blockErrorPageMessage- the value to set
- Returns:
- this builder
 
 - 
blockErrorPageCodepublic AccessRule.Builder blockErrorPageCode(String blockErrorPageCode) The error code to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.If unspecified, defaults to ‘Access rules’. - Parameters:
- blockErrorPageCode- the value to set
- Returns:
- this builder
 
 - 
blockErrorPageDescriptionpublic AccessRule.Builder blockErrorPageDescription(String blockErrorPageDescription) The description text to show on the error page when action is set to BLOCK, blockAction is set to SHOW_ERROR_PAGE, and the access criteria are met.If unspecified, defaults to ‘Access blocked by website owner. Please contact support.’ - Parameters:
- blockErrorPageDescription- the value to set
- Returns:
- this builder
 
 - 
bypassChallengespublic AccessRule.Builder bypassChallenges(List<AccessRule.BypassChallenges> bypassChallenges) The list of challenges to bypass when action is set to BYPASS.If unspecified or empty, all challenges are bypassed. - **JS_CHALLENGE:** Bypasses JavaScript Challenge. - **DEVICE_FINGERPRINT_CHALLENGE:** Bypasses Device Fingerprint Challenge. - **HUMAN_INTERACTION_CHALLENGE:** Bypasses Human Interaction Challenge. - **CAPTCHA:** Bypasses CAPTCHA Challenge. - Parameters:
- bypassChallenges- the value to set
- Returns:
- this builder
 
 - 
redirectUrlpublic AccessRule.Builder redirectUrl(String redirectUrl) The target to which the request should be redirected, represented as a URI reference.Required when action is REDIRECT. - Parameters:
- redirectUrl- the value to set
- Returns:
- this builder
 
 - 
redirectResponseCodepublic AccessRule.Builder redirectResponseCode(AccessRule.RedirectResponseCode redirectResponseCode) The response status code to return when action is set to REDIRECT.- **MOVED_PERMANENTLY:** Used for designating the permanent movement of a page (numerical code - 301). - **FOUND:** Used for designating the temporary movement of a page (numerical code - 302). - Parameters:
- redirectResponseCode- the value to set
- Returns:
- this builder
 
 - 
captchaTitlepublic AccessRule.Builder captchaTitle(String captchaTitle) The title used when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.- Parameters:
- captchaTitle- the value to set
- Returns:
- this builder
 
 - 
captchaHeaderpublic AccessRule.Builder captchaHeader(String captchaHeader) The text to show in the header when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.- Parameters:
- captchaHeader- the value to set
- Returns:
- this builder
 
 - 
captchaFooterpublic AccessRule.Builder captchaFooter(String captchaFooter) The text to show in the footer when showing a CAPTCHA challenge when action is set to SHOW_CAPTCHA and the request is challenged.- Parameters:
- captchaFooter- the value to set
- Returns:
- this builder
 
 - 
captchaSubmitLabelpublic AccessRule.Builder captchaSubmitLabel(String captchaSubmitLabel) The text to show on the label of the CAPTCHA challenge submit button when action is set to SHOW_CAPTCHA and the request is challenged.- Parameters:
- captchaSubmitLabel- the value to set
- Returns:
- this builder
 
 - 
responseHeaderManipulationpublic AccessRule.Builder responseHeaderManipulation(List<HeaderManipulationAction> responseHeaderManipulation) An object that represents an action to apply to an HTTP response headers if all rule criteria will be matched regardless of action value.- Parameters:
- responseHeaderManipulation- the value to set
- Returns:
- this builder
 
 - 
buildpublic AccessRule build() 
 - 
copypublic AccessRule.Builder copy(AccessRule model) 
 
- 
 
-