Documentation ¶
Index ¶
- func InitSecurityAgent(app *newrelic.Application, opts ...ConfigOption) error
- type ConfigOption
- func ConfigSecurityDetectionDisableRxss(isDisable bool) ConfigOption
- func ConfigSecurityEnable(isEnabled bool) ConfigOption
- func ConfigSecurityFromEnvironment() ConfigOption
- func ConfigSecurityFromYaml() ConfigOption
- func ConfigSecurityMode(mode string) ConfigOption
- func ConfigSecurityRequestBodyLimit(bodyLimit int) ConfigOption
- func ConfigSecurityValidatorServiceEndPointUrl(url string) ConfigOption
- type SecurityConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitSecurityAgent ¶
func InitSecurityAgent(app *newrelic.Application, opts ...ConfigOption) error
InitSecurityAgent initializes the nrsecurityagent integration package from user-supplied configuration values.
Types ¶
type ConfigOption ¶
type ConfigOption func(*SecurityConfig)
ConfigOption functions are used to programmatically provide configuration values to the nrsecurityagent integration package.
func ConfigSecurityDetectionDisableRxss ¶
func ConfigSecurityDetectionDisableRxss(isDisable bool) ConfigOption
ConfigSecurityDetectionDisableRxss is used to enable or disable RXSS validation.
func ConfigSecurityEnable ¶
func ConfigSecurityEnable(isEnabled bool) ConfigOption
ConfigSecurityEnable enables or disables the security integration.
func ConfigSecurityFromEnvironment ¶
func ConfigSecurityFromEnvironment() ConfigOption
func ConfigSecurityFromYaml ¶
func ConfigSecurityFromYaml() ConfigOption
ConfigSecurityFromYaml directs the nrsecurityagent integration to read an external YAML-formatted file to obtain its configuration values.
The path to this file must be provided by setting the environment variable NEW_RELIC_SECURITY_CONFIG_PATH.
func ConfigSecurityMode ¶
func ConfigSecurityMode(mode string) ConfigOption
ConfigSecurityMode sets the security mode to use. By default, this is "IAST".
func ConfigSecurityRequestBodyLimit ¶ added in v1.1.3
func ConfigSecurityRequestBodyLimit(bodyLimit int) ConfigOption
ConfigSecurityRequestBodyLimit set limit on read request body in kb. By default, this is "300"
func ConfigSecurityValidatorServiceEndPointUrl ¶
func ConfigSecurityValidatorServiceEndPointUrl(url string) ConfigOption
ConfigSecurityValidatorServiceEndPointUrl sets the security validator service endpoint.
type SecurityConfig ¶
type SecurityConfig struct { securityAgent.SecurityAgentConfig Error error }