MCPcopy Index your code
hub / github.com/codeyourweb/irma / YaraScan

Function YaraScan

yaraProcessing.go:127–132  ·  view source on GitHub ↗

YaraScan use libyara to scan the specified content with a compiled rule

(content []byte, rules *yara.Rules)

Source from the content-addressed store, hash-verified

125
126// YaraScan use libyara to scan the specified content with a compiled rule
127func YaraScan(content []byte, rules *yara.Rules) (match yara.MatchRules, err error) {
128 sc, _ := yara.NewScanner(rules)
129 var m yara.MatchRules
130 err = sc.SetCallback(&m).ScanMem(content)
131 return m, err
132}

Callers 2

PerformYaraScanFunction · 0.85
PerformArchiveYaraScanFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected