Documentation ¶
Index ¶
- func DecorateRules(concurrent int, proxy string)
- func DeleteSuricataRuleByID(db *gorm.DB, id int64) error
- func ExportRulesToFile(db *gorm.DB, fileName string) error
- func ImportRulesFromFile(db *gorm.DB, fileName string) error
- func SaveHTTPRequest(db *gorm.DB, name string, raw []byte) error
- func SaveICMPTraffic(db *gorm.DB, name string, raw []byte) error
- func SaveSuricata(db *gorm.DB, s *rule.Rule) error
- func SaveTCPTraffic(db *gorm.DB, name string, raw []byte) error
- func UpsertRule(db *gorm.DB, hash string, i interface{}) error
- func YieldRules(db *gorm.DB, ctx context.Context) chan *Storage
- type Storage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecorateRules ¶
Types ¶
type Storage ¶
type Storage struct { gorm.Model RawTrafficBeyondIPPacketBase64 string RawTrafficBeyondLinkLayerBase64 string RawTrafficBeyondHTTPBase64 string // suricata / http-request RuleType string SuricataRaw string `json:"raw"` Protocol string Action string Name string NameZh string ClassType string ClassTypeZh string Group string Hash string `json:"hash" gorm:"unique_index"` Keywords string KeywordsZh string Description string DescriptionZh string CVE string }
func NewHTTPRequestRule ¶
func NewRuleFromSuricata ¶
func (*Storage) BeforeSave ¶
func (*Storage) DecoratedByOpenAI ¶
func (c *Storage) DecoratedByOpenAI(db *gorm.DB, opts ...openai.ConfigOption)
func (*Storage) ToGPRCModel ¶
func (c *Storage) ToGPRCModel() *ypb.ChaosMakerRule
Click to show internal directories.
Click to hide internal directories.