-
-
Notifications
You must be signed in to change notification settings - Fork 655
Closed
Description
When using gas to scan golang.org/x/crypto/acme/autocert/autocert.go, I get the following segmentation violation:
[gas] 2018/02/13 16:08:38 Checking package: autocert
[gas] 2018/02/13 16:08:38 Checking file: /Users/browne/workspace/go/src/golang.org/x/crypto/acme/autocert/autocert.go
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x126a7ec]
goroutine 1 [running]:
github.com/GoASTScanner/gas/rules.(*insecureConfigTLS).Match(0xc42007d920, 0x1474fc0, 0xc420239ec0, 0xc420054400, 0x1, 0xdc0000c420c2cb48, 0xc42017a928)
/Users/browne/go/src/github.com/GoASTScanner/gas/rules/tls.go:109 +0x7c
github.com/GoASTScanner/gas.(*Analyzer).Visit(0xc4200841e0, 0x1474fc0, 0xc420239ec0, 0x2, 0x14e2fe0)
/Users/browne/go/src/github.com/GoASTScanner/gas/analyzer.go:171 +0x1c5
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1474fc0, 0xc420239ec0)
/usr/local/go/src/go/ast/walk.go:52 +0x66
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1475940, 0xc420240e80)
/usr/local/go/src/go/ast/walk.go:143 +0x15df
go/ast.walkExprList(0x1473980, 0xc4200841e0, 0xc4205a7e70, 0x1, 0x1)
/usr/local/go/src/go/ast/walk.go:26 +0x81
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1474c40, 0xc420239f00)
/usr/local/go/src/go/ast/walk.go:207 +0x211f
go/ast.walkStmtList(0x1473980, 0xc4200841e0, 0xc420244000, 0x3, 0x4)
/usr/local/go/src/go/ast/walk.go:32 +0x81
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1474e80, 0xc420244040)
/usr/local/go/src/go/ast/walk.go:238 +0x1e95
go/ast.walkStmtList(0x1473980, 0xc4200841e0, 0xc420244100, 0x3, 0x4)
/usr/local/go/src/go/ast/walk.go:32 +0x81
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1474dc0, 0xc42023b350)
/usr/local/go/src/go/ast/walk.go:224 +0x1b71
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1475900, 0xc42023b380)
/usr/local/go/src/go/ast/walk.go:254 +0x1212
go/ast.walkStmtList(0x1473980, 0xc4200841e0, 0xc4205bc780, 0x5, 0x8)
/usr/local/go/src/go/ast/walk.go:32 +0x81
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1474dc0, 0xc42023b560)
/usr/local/go/src/go/ast/walk.go:224 +0x1b71
go/ast.Walk(0x1473980, 0xc4200841e0, 0x1475240, 0xc42023b590)
/usr/local/go/src/go/ast/walk.go:344 +0xd83
go/ast.walkDeclList(0x1473980, 0xc4200841e0, 0xc42046d400, 0x2b, 0x40)
/usr/local/go/src/go/ast/walk.go:38 +0x81
go/ast.Walk(0x1473980, 0xc4200841e0, 0x14751c0, 0xc4205bcf80)
/usr/local/go/src/go/ast/walk.go:353 +0x266f
github.com/GoASTScanner/gas.(*Analyzer).Process(0xc4200841e0, 0xc42004a8d0, 0x1, 0x1, 0x1, 0xc42004a8d0)
/Users/browne/go/src/github.com/GoASTScanner/gas/analyzer.go:141 +0x57d
main.main()
/Users/browne/go/src/github.com/GoASTScanner/gas/cmd/gas/main.go:224 +0x459
To reproduce:
go get golang.org/x/crypto/ssh
cd /Users/browne/workspace/go/src/golang.org
gas x/crypto/acme/autocert/
Metadata
Metadata
Assignees
Labels
No labels