-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add inext_web_user_response, tests and CI improvements (#9)
* add inext_web_user_response, tests and CI improvements
- Loading branch information
1 parent
f959836
commit 1d2d852
Showing
78 changed files
with
925 additions
and
366 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "inext_web_user_response Resource - terraform-provider-infinity-next" | ||
subcategory: "" | ||
description: |- | ||
Determine the response returned to the client who initiated a blocked traffic.The response can be a simple HTTP error code, an HTTP redirect message, or a Block page that a user can view in their browser. | ||
--- | ||
|
||
# inext_web_user_response (Resource) | ||
|
||
Determine the response returned to the client who initiated a blocked traffic.The response can be a simple HTTP error code, an HTTP redirect message, or a Block page that a user can view in their browser. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
resource "inext_web_user_response" "web-user-response-blockpage" { | ||
name = "web-user-response" | ||
mode = "BlockPage" | ||
http_response_code = 403 | ||
message_title = "some message title" | ||
message_body = "some message body" | ||
} | ||
resource "inext_web_user_response" "web-user-response-redirect" { | ||
name = "web-user-response-redirect" | ||
mode = "Redirect" | ||
redirect_url = "http://localhost:1234/test" | ||
x_event_id = true | ||
} | ||
resource "inext_web_user_response" "web-user-response-responsecodeonly" { | ||
name = "web-user-response-responsecodeonly" | ||
mode = "ResponseCodeOnly" | ||
http_response_code = 403 | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `mode` (String) The type of the web user response object | ||
- `name` (String) The name of the resource, also acts as its unique ID | ||
|
||
### Optional | ||
|
||
- `http_response_code` (Number) It is recommended to use a 403 (Forbidden) as a response code | ||
- `message_body` (String) The body of the message to be shown to the user | ||
- `message_title` (String) The title of the web page to be shown to the user sending the malicious traffic | ||
- `redirect_url` (String) The client will be redirected to the provided URL where you can provide any customized web page | ||
- `x_event_id` (Boolean) When selected the redirect message will include this header with a value that provides an internal reference ID that will match a security log generated by the incident, if log triggers are configured | ||
|
||
### Read-Only | ||
|
||
- `id` (String) The ID of this resource. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
resource "inext_web_user_response" "web-user-response-blockpage" { | ||
name = "web-user-response" | ||
mode = "BlockPage" | ||
http_response_code = 403 | ||
message_title = "some message title" | ||
message_body = "some message body" | ||
} | ||
|
||
resource "inext_web_user_response" "web-user-response-redirect" { | ||
name = "web-user-response-redirect" | ||
mode = "Redirect" | ||
redirect_url = "http://localhost:1234/test" | ||
x_event_id = true | ||
} | ||
|
||
resource "inext_web_user_response" "web-user-response-responsecodeonly" { | ||
name = "web-user-response-responsecodeonly" | ||
mode = "ResponseCodeOnly" | ||
http_response_code = 403 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package models | ||
|
||
type WebUserResponseBehavior struct { | ||
ID string `json:"id"` | ||
Name string `json:"name"` | ||
Mode string `json:"mode"` | ||
MessageTitle string `json:"messageTitle"` | ||
MessageBody string `json:"messageBody"` | ||
HTTPResponseCode int `json:"httpResponseCode"` | ||
RedirectURL string `json:"redirectURL"` | ||
XEventID bool `json:"xEventId"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package models | ||
|
||
type CreateWebUserResponseBehaviorInput struct { | ||
Name string `json:"name"` | ||
Visibility string `json:"visibility"` | ||
Mode string `json:"mode"` | ||
MessageTitle string `json:"messageTitle"` | ||
MessageBody string `json:"messageBody"` | ||
HTTPResponseCode int `json:"httpResponseCode"` | ||
RedirectURL string `json:"redirectURL"` | ||
XEventID bool `json:"xEventId"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package models | ||
|
||
type UpdateWebUserResponseBehaviorInput struct { | ||
Name string `json:"name"` | ||
Mode string `json:"mode"` | ||
MessageTitle string `json:"messageTitle,omitempty"` | ||
MessageBody string `json:"messageBody,omitempty"` | ||
HTTPResponseCode int `json:"httpResponseCode,omitempty"` | ||
RedirectURL string `json:"redirectURL,omitempty"` | ||
XEventID bool `json:"xEventId"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.