rule

package
v0.4.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 28, 2022 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package rule is to control the audit rule behaviors

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	InboundRule         *sync.Map // Key: Tag, Value: []api.DetectRule
	InboundDetectResult *sync.Map // key: Tag, Value: mapSet.NewSet []api.DetectResult
}

func New

func New() *Manager

func (*Manager) Detect

func (m *Manager) Detect(tag string, destination string, email string) (reject bool)

func (*Manager) GetDetectResult

func (m *Manager) GetDetectResult(tag string) (*[]api.DetectResult, error)

func (*Manager) UpdateRule

func (m *Manager) UpdateRule(tag string, newRuleList []api.DetectRule) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL