1
0
mirror of https://github.com/securego/gosec.git synced 2025-11-23 22:15:04 +02:00

Adding a config block to the analyzer, parsed from JSON

A CLI option can now be given to tell GAS it should parse data
from a JSON file. Fatal errors are given if the file is not
readable or is not valid JSON.
This commit is contained in:
Tim Kelsey
2016-07-29 11:19:50 +01:00
parent 8261ee58d6
commit d4367de2e2
17 changed files with 75 additions and 48 deletions

View File

@@ -15,12 +15,13 @@
package rules
import (
gas "github.com/HewlettPackard/gas/core"
"testing"
gas "github.com/HewlettPackard/gas/core"
)
func TestTempfiles(t *testing.T) {
analyzer := gas.NewAnalyzer(false, nil)
analyzer := gas.NewAnalyzer(false, nil, nil)
analyzer.AddRule(NewBadTempFile())
source := `