Documentation ¶
Overview ¶
Package wafrulegroupsapiv1 : Operations and models for the WafRuleGroupsApiV1 service
Index ¶
- Constants
- func UnmarshalWafGroupResponse(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalWafGroupResponseResultInfo(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalWafGroupsResponse(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalWafGroupsResponseResultInfo(m map[string]json.RawMessage, result interface{}) (err error)
- func UnmarshalWafRuleProperties(m map[string]json.RawMessage, result interface{}) (err error)
- type GetWafRuleGroupOptions
- type ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetDirection(direction string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetHeaders(param map[string]string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetMatch(match string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetMode(mode string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetName(name string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetOrder(order string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetPage(page int64) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetPerPage(perPage int64) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetPkgID(pkgID string) *ListWafRuleGroupsOptions
- func (options *ListWafRuleGroupsOptions) SetRulesCount(rulesCount string) *ListWafRuleGroupsOptions
- type UpdateWafRuleGroupOptions
- func (options *UpdateWafRuleGroupOptions) SetGroupID(groupID string) *UpdateWafRuleGroupOptions
- func (options *UpdateWafRuleGroupOptions) SetHeaders(param map[string]string) *UpdateWafRuleGroupOptions
- func (options *UpdateWafRuleGroupOptions) SetMode(mode string) *UpdateWafRuleGroupOptions
- func (options *UpdateWafRuleGroupOptions) SetPkgID(pkgID string) *UpdateWafRuleGroupOptions
- type WafGroupResponse
- type WafGroupResponseResultInfo
- type WafGroupsResponse
- type WafGroupsResponseResultInfo
- type WafRuleGroupsApiV1
- func (wafRuleGroupsApi *WafRuleGroupsApiV1) GetWafRuleGroup(getWafRuleGroupOptions *GetWafRuleGroupOptions) (result *WafGroupResponse, response *core.DetailedResponse, err error)
- func (wafRuleGroupsApi *WafRuleGroupsApiV1) ListWafRuleGroups(listWafRuleGroupsOptions *ListWafRuleGroupsOptions) (result *WafGroupsResponse, response *core.DetailedResponse, err error)
- func (*WafRuleGroupsApiV1) NewGetWafRuleGroupOptions(pkgID string, groupID string) *GetWafRuleGroupOptions
- func (*WafRuleGroupsApiV1) NewListWafRuleGroupsOptions(pkgID string) *ListWafRuleGroupsOptions
- func (*WafRuleGroupsApiV1) NewUpdateWafRuleGroupOptions(pkgID string, groupID string) *UpdateWafRuleGroupOptions
- func (wafRuleGroupsApi *WafRuleGroupsApiV1) SetServiceURL(url string) error
- func (wafRuleGroupsApi *WafRuleGroupsApiV1) UpdateWafRuleGroup(updateWafRuleGroupOptions *UpdateWafRuleGroupOptions) (result *WafGroupResponse, response *core.DetailedResponse, err error)
- type WafRuleGroupsApiV1Options
- type WafRuleProperties
Constants ¶
const ( ListWafRuleGroupsOptions_Mode_Off = "off" ListWafRuleGroupsOptions_Mode_On = "on" )
Constants associated with the ListWafRuleGroupsOptions.Mode property. Whether or not the rules contained within this group are configurable/usable.
const ( ListWafRuleGroupsOptions_Direction_Asc = "asc" ListWafRuleGroupsOptions_Direction_Desc = "desc" )
Constants associated with the ListWafRuleGroupsOptions.Direction property. Direction to order packages.
const ( ListWafRuleGroupsOptions_Match_All = "all" ListWafRuleGroupsOptions_Match_Any = "any" )
Constants associated with the ListWafRuleGroupsOptions.Match property. Whether to match all search requirements or at least one (any).
const ( UpdateWafRuleGroupOptions_Mode_Off = "off" UpdateWafRuleGroupOptions_Mode_On = "on" )
Constants associated with the UpdateWafRuleGroupOptions.Mode property. Whether or not the rules contained within this group are configurable/usable.
const DefaultServiceName = "waf_rule_groups_api"
DefaultServiceName is the default key used to find external configuration information.
const DefaultServiceURL = "https://api.cis.cloud.ibm.com"
DefaultServiceURL is the default URL to make service requests to.
Variables ¶
This section is empty.
Functions ¶
func UnmarshalWafGroupResponse ¶
func UnmarshalWafGroupResponse(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalWafGroupResponse unmarshals an instance of WafGroupResponse from the specified map of raw messages.
func UnmarshalWafGroupResponseResultInfo ¶
func UnmarshalWafGroupResponseResultInfo(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalWafGroupResponseResultInfo unmarshals an instance of WafGroupResponseResultInfo from the specified map of raw messages.
func UnmarshalWafGroupsResponse ¶
func UnmarshalWafGroupsResponse(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalWafGroupsResponse unmarshals an instance of WafGroupsResponse from the specified map of raw messages.
func UnmarshalWafGroupsResponseResultInfo ¶
func UnmarshalWafGroupsResponseResultInfo(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalWafGroupsResponseResultInfo unmarshals an instance of WafGroupsResponseResultInfo from the specified map of raw messages.
func UnmarshalWafRuleProperties ¶
func UnmarshalWafRuleProperties(m map[string]json.RawMessage, result interface{}) (err error)
UnmarshalWafRuleProperties unmarshals an instance of WafRuleProperties from the specified map of raw messages.
Types ¶
type GetWafRuleGroupOptions ¶
type GetWafRuleGroupOptions struct { // Package ID. PkgID *string `json:"pkg_id" validate:"required"` // Group ID. GroupID *string `json:"group_id" validate:"required"` // Allows users to set headers on API requests Headers map[string]string }
GetWafRuleGroupOptions : The GetWafRuleGroup options.
func (*GetWafRuleGroupOptions) SetGroupID ¶
func (options *GetWafRuleGroupOptions) SetGroupID(groupID string) *GetWafRuleGroupOptions
SetGroupID : Allow user to set GroupID
func (*GetWafRuleGroupOptions) SetHeaders ¶
func (options *GetWafRuleGroupOptions) SetHeaders(param map[string]string) *GetWafRuleGroupOptions
SetHeaders : Allow user to set Headers
func (*GetWafRuleGroupOptions) SetPkgID ¶
func (options *GetWafRuleGroupOptions) SetPkgID(pkgID string) *GetWafRuleGroupOptions
SetPkgID : Allow user to set PkgID
type ListWafRuleGroupsOptions ¶
type ListWafRuleGroupsOptions struct { // Package ID. PkgID *string `json:"pkg_id" validate:"required"` // Name of the firewall package. Name *string `json:"name,omitempty"` // Whether or not the rules contained within this group are configurable/usable. Mode *string `json:"mode,omitempty"` // How many rules are contained within this group. RulesCount *string `json:"rules_count,omitempty"` // Page number of paginated results. Page *int64 `json:"page,omitempty"` // Number of packages per page. PerPage *int64 `json:"per_page,omitempty"` // Field to order packages by. Order *string `json:"order,omitempty"` // Direction to order packages. Direction *string `json:"direction,omitempty"` // Whether to match all search requirements or at least one (any). Match *string `json:"match,omitempty"` // Allows users to set headers on API requests Headers map[string]string }
ListWafRuleGroupsOptions : The ListWafRuleGroups options.
func (*ListWafRuleGroupsOptions) SetDirection ¶
func (options *ListWafRuleGroupsOptions) SetDirection(direction string) *ListWafRuleGroupsOptions
SetDirection : Allow user to set Direction
func (*ListWafRuleGroupsOptions) SetHeaders ¶
func (options *ListWafRuleGroupsOptions) SetHeaders(param map[string]string) *ListWafRuleGroupsOptions
SetHeaders : Allow user to set Headers
func (*ListWafRuleGroupsOptions) SetMatch ¶
func (options *ListWafRuleGroupsOptions) SetMatch(match string) *ListWafRuleGroupsOptions
SetMatch : Allow user to set Match
func (*ListWafRuleGroupsOptions) SetMode ¶
func (options *ListWafRuleGroupsOptions) SetMode(mode string) *ListWafRuleGroupsOptions
SetMode : Allow user to set Mode
func (*ListWafRuleGroupsOptions) SetName ¶
func (options *ListWafRuleGroupsOptions) SetName(name string) *ListWafRuleGroupsOptions
SetName : Allow user to set Name
func (*ListWafRuleGroupsOptions) SetOrder ¶
func (options *ListWafRuleGroupsOptions) SetOrder(order string) *ListWafRuleGroupsOptions
SetOrder : Allow user to set Order
func (*ListWafRuleGroupsOptions) SetPage ¶
func (options *ListWafRuleGroupsOptions) SetPage(page int64) *ListWafRuleGroupsOptions
SetPage : Allow user to set Page
func (*ListWafRuleGroupsOptions) SetPerPage ¶
func (options *ListWafRuleGroupsOptions) SetPerPage(perPage int64) *ListWafRuleGroupsOptions
SetPerPage : Allow user to set PerPage
func (*ListWafRuleGroupsOptions) SetPkgID ¶
func (options *ListWafRuleGroupsOptions) SetPkgID(pkgID string) *ListWafRuleGroupsOptions
SetPkgID : Allow user to set PkgID
func (*ListWafRuleGroupsOptions) SetRulesCount ¶
func (options *ListWafRuleGroupsOptions) SetRulesCount(rulesCount string) *ListWafRuleGroupsOptions
SetRulesCount : Allow user to set RulesCount
type UpdateWafRuleGroupOptions ¶
type UpdateWafRuleGroupOptions struct { // Package ID. PkgID *string `json:"pkg_id" validate:"required"` // Group ID. GroupID *string `json:"group_id" validate:"required"` // Whether or not the rules contained within this group are configurable/usable. Mode *string `json:"mode,omitempty"` // Allows users to set headers on API requests Headers map[string]string }
UpdateWafRuleGroupOptions : The UpdateWafRuleGroup options.
func (*UpdateWafRuleGroupOptions) SetGroupID ¶
func (options *UpdateWafRuleGroupOptions) SetGroupID(groupID string) *UpdateWafRuleGroupOptions
SetGroupID : Allow user to set GroupID
func (*UpdateWafRuleGroupOptions) SetHeaders ¶
func (options *UpdateWafRuleGroupOptions) SetHeaders(param map[string]string) *UpdateWafRuleGroupOptions
SetHeaders : Allow user to set Headers
func (*UpdateWafRuleGroupOptions) SetMode ¶
func (options *UpdateWafRuleGroupOptions) SetMode(mode string) *UpdateWafRuleGroupOptions
SetMode : Allow user to set Mode
func (*UpdateWafRuleGroupOptions) SetPkgID ¶
func (options *UpdateWafRuleGroupOptions) SetPkgID(pkgID string) *UpdateWafRuleGroupOptions
SetPkgID : Allow user to set PkgID
type WafGroupResponse ¶
type WafGroupResponse struct { // Was operation successful. Success *bool `json:"success" validate:"required"` // Array of errors encountered. Errors [][]string `json:"errors" validate:"required"` // Array of messages returned. Messages [][]string `json:"messages" validate:"required"` // waf rule properties. Result *WafRuleProperties `json:"result" validate:"required"` // Statistics of results. ResultInfo *WafGroupResponseResultInfo `json:"result_info" validate:"required"` }
WafGroupResponse : waf group response.
type WafGroupResponseResultInfo ¶
type WafGroupResponseResultInfo struct { // Page number. Page *int64 `json:"page" validate:"required"` // Number of results per page. PerPage *int64 `json:"per_page" validate:"required"` // Number of results. Count *int64 `json:"count" validate:"required"` // Total number of results. TotalCount *int64 `json:"total_count" validate:"required"` }
WafGroupResponseResultInfo : Statistics of results.
type WafGroupsResponse ¶
type WafGroupsResponse struct { // Was operation successful. Success *bool `json:"success" validate:"required"` // Array of errors encountered. Errors [][]string `json:"errors" validate:"required"` // Array of messages returned. Messages [][]string `json:"messages" validate:"required"` // Container for response information. Result []WafRuleProperties `json:"result" validate:"required"` // Statistics of results. ResultInfo *WafGroupsResponseResultInfo `json:"result_info" validate:"required"` }
WafGroupsResponse : waf groups response.
type WafGroupsResponseResultInfo ¶
type WafGroupsResponseResultInfo struct { // Page number. Page *int64 `json:"page" validate:"required"` // Number of results per page. PerPage *int64 `json:"per_page" validate:"required"` // Number of results. Count *int64 `json:"count" validate:"required"` // Total number of results. TotalCount *int64 `json:"total_count" validate:"required"` }
WafGroupsResponseResultInfo : Statistics of results.
type WafRuleGroupsApiV1 ¶
type WafRuleGroupsApiV1 struct { Service *core.BaseService // cloud resource name. Crn *string // Zone ID. ZoneID *string }
WafRuleGroupsApiV1 : This document describes CIS WAF Rule Groups API.
Version: 1.0.0
func NewWafRuleGroupsApiV1 ¶
func NewWafRuleGroupsApiV1(options *WafRuleGroupsApiV1Options) (service *WafRuleGroupsApiV1, err error)
NewWafRuleGroupsApiV1 : constructs an instance of WafRuleGroupsApiV1 with passed in options.
func NewWafRuleGroupsApiV1UsingExternalConfig ¶
func NewWafRuleGroupsApiV1UsingExternalConfig(options *WafRuleGroupsApiV1Options) (wafRuleGroupsApi *WafRuleGroupsApiV1, err error)
NewWafRuleGroupsApiV1UsingExternalConfig : constructs an instance of WafRuleGroupsApiV1 with passed in options and external configuration.
func (*WafRuleGroupsApiV1) GetWafRuleGroup ¶
func (wafRuleGroupsApi *WafRuleGroupsApiV1) GetWafRuleGroup(getWafRuleGroupOptions *GetWafRuleGroupOptions) (result *WafGroupResponse, response *core.DetailedResponse, err error)
GetWafRuleGroup : Get a single WAF rule group Get a single WAF rule group.
func (*WafRuleGroupsApiV1) ListWafRuleGroups ¶
func (wafRuleGroupsApi *WafRuleGroupsApiV1) ListWafRuleGroups(listWafRuleGroupsOptions *ListWafRuleGroupsOptions) (result *WafGroupsResponse, response *core.DetailedResponse, err error)
ListWafRuleGroups : List all WAF rule groups contained within a package List all WAF rule groups contained within a package.
func (*WafRuleGroupsApiV1) NewGetWafRuleGroupOptions ¶
func (*WafRuleGroupsApiV1) NewGetWafRuleGroupOptions(pkgID string, groupID string) *GetWafRuleGroupOptions
NewGetWafRuleGroupOptions : Instantiate GetWafRuleGroupOptions
func (*WafRuleGroupsApiV1) NewListWafRuleGroupsOptions ¶
func (*WafRuleGroupsApiV1) NewListWafRuleGroupsOptions(pkgID string) *ListWafRuleGroupsOptions
NewListWafRuleGroupsOptions : Instantiate ListWafRuleGroupsOptions
func (*WafRuleGroupsApiV1) NewUpdateWafRuleGroupOptions ¶
func (*WafRuleGroupsApiV1) NewUpdateWafRuleGroupOptions(pkgID string, groupID string) *UpdateWafRuleGroupOptions
NewUpdateWafRuleGroupOptions : Instantiate UpdateWafRuleGroupOptions
func (*WafRuleGroupsApiV1) SetServiceURL ¶
func (wafRuleGroupsApi *WafRuleGroupsApiV1) SetServiceURL(url string) error
SetServiceURL sets the service URL
func (*WafRuleGroupsApiV1) UpdateWafRuleGroup ¶
func (wafRuleGroupsApi *WafRuleGroupsApiV1) UpdateWafRuleGroup(updateWafRuleGroupOptions *UpdateWafRuleGroupOptions) (result *WafGroupResponse, response *core.DetailedResponse, err error)
UpdateWafRuleGroup : Update the state of a WAF rule group Update the state of a WAF rule group.
type WafRuleGroupsApiV1Options ¶
type WafRuleGroupsApiV1Options struct { ServiceName string URL string Authenticator core.Authenticator // cloud resource name. Crn *string `validate:"required"` // Zone ID. ZoneID *string `validate:"required"` }
WafRuleGroupsApiV1Options : Service options
type WafRuleProperties ¶
type WafRuleProperties struct { // ID. ID *string `json:"id,omitempty"` // Name. Name *string `json:"name,omitempty"` // Description. Description *string `json:"description,omitempty"` // Number of rules. RulesCount *int64 `json:"rules_count,omitempty"` // Number of modified rules. ModifiedRulesCount *int64 `json:"modified_rules_count,omitempty"` // Package ID. PackageID *string `json:"package_id,omitempty"` // Mode. Mode *string `json:"mode,omitempty"` // Allowed Modes. AllowedModes []string `json:"allowed_modes,omitempty"` }
WafRuleProperties : waf rule properties.