scan

package
v0.0.0-...-a6020ae Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2024 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package scan contains scanner/parser code for rules and scanner code for the binary files

Index

Constants

View Source
const (
	EOF       = scanner.EOF
	Ident     = scanner.Ident
	Int       = scanner.Int
	Float     = scanner.Float
	Char      = scanner.Char
	String    = scanner.String
	RawString = scanner.RawString
	Comment   = scanner.Comment
)
View Source
const (
	Operator rune = -(iota + 10)
	None          // not scanned, only used by accept-any and similar
)

Variables

This section is empty.

Functions

func AnalyzeFile

func AnalyzeFile(rule *types.Rule, env *types.Env) (*types.Match, []error)

AnalyzeFile evaluates one rule against one file, if the rule has children they will also be evaluated

func ParseRuleFiles

func ParseRuleFiles(db *types.Molly, files ...string) error

ParseRuleFiles loads rules from a set of files

func ParseRuleStream

func ParseRuleStream(db *types.Molly, source string, r io.Reader) error

ParseRuleStream loads rules from a stream

Types

This section is empty.

Jump to

Keyboard shortcuts

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