Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: descriptions for v1.0.0 #4

Merged
merged 2 commits into from
Nov 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 12 additions & 11 deletions types/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,70 +177,71 @@ type Input struct {
DestAddr *string `yaml:"dest_addr,omitempty" koanf:"dest_addr,omitempty"`

// description: |
// Port allows you to declare which port on the destination host the tests should connect to.
// Port allows you to declare which port on the destination host the test should connect to.
// examples:
// - name: Port
// value: 80
Port *int `yaml:"port,omitempty" koanf:"port,omitempty"`

// description: |
// Protocol allows you to declare which port on the destination host the tests should connect to.
// Protocol allows you to declare which protocol the test should use when sending the request.
// examples:
// - name: Protocol
// value: "\"http\""
Protocol *string `yaml:"protocol,omitempty" koanf:"protocol,omitempty"`

// description: |
// URI allows you to declare which port on the destination host the tests should connect to.
// URI allows you to declare the URI the test should use as part of the request line.
// examples:
// - name: URI
// value: "\"/get?hello=world\""
URI *string `yaml:"uri,omitempty" koanf:"uri,omitempty"`

// description: |
// Version it the HTTP version used.
// Version allows you to declare the HTTP version the test should use as part of the request line.
// examples:
// - name: Version
// value: "\"1.1\""
Version *string `yaml:"version,omitempty" koanf:"version,omitempty"`

// description: |
// Method allows you to declare which port on the destination host the tests should connect to.
// Method allows you to declare the HTTP method the test should use as part of the request line.
// examples:
// - name: Method
// value: "\"GET\""
Method *string `yaml:"method,omitempty" koanf:"method,omitempty"`

// description: |
// Method allows you to declare which port on the destination host the tests should connect to.
// Method allows you to declare headers that the test should send.
// examples:
// - name: Headers
// value: exampleHeaders
Headers map[string]string `yaml:"headers,omitempty" koanf:"headers,omitempty"`

// description: |
// Data allows you to declare which port on the destination host the tests should connect to.
// Data allows you to declare the payload that the test should in the request body.
// examples:
// - name: Data
// value: "\"Bibitti bopi\""
Data *string `yaml:"data,omitempty" koanf:"data,omitempty"`

// description: |
// SaveCookie allows you to declare which port on the destination host the tests should connect to.
// SaveCookie allows you to automatically provide cookies if there are multiple stages and save cookie is set
// examples:
// - name: SaveCookie
// value: 80
SaveCookie bool `yaml:"save_cookie,omitempty" koanf:"save_cookie,omitempty"`

// description: |
// StopMagic allows you to declare which port on the destination host the tests should connect to.
// StopMagic blocks the test framework to automatically fill the request with Content-Type and Connection headers.
// examples:
// - name: StopMagic
// value: false
StopMagic bool `yaml:"stop_magic" koanf:"stop_magic,omitempty"`

// description: |
// EncodedRequest allows you to declare which port on the destination host the tests should connect to.
// EncodedRequest will take a base64 encoded string that will be decoded and sent through as the request.
// It will override all other settings
// examples:
// - name: EncodedRequest
// value: "\"a\""
Expand Down Expand Up @@ -278,7 +279,7 @@ type Output struct {
LogContains string `yaml:"log_contains,omitempty"`

// description: |
// NoLogContains describes the text that should be contained in the WAF logs.
// NoLogContains describes the text that should not be contained in the WAF logs.
// examples:
// - name: NoLogContains
// value: "\"id 920100\""
Expand Down