Skip to content

gas produces legitimate warnings when run against itself #95

@endophage

Description

@endophage
Results:

[/Users/david/go/src/github.com/GoASTScanner/gas/rules/fileperms.go:39] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > mode, _ = strconv.ParseInt(value.(string), 0, 64)


[/Users/david/go/src/github.com/GoASTScanner/gas/rules/sql.go:45] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > str, _ := gas.GetString(start)


[/Users/david/go/src/github.com/GoASTScanner/gas/rules/sql.go:80] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > arg, _ := gas.GetString(node.Args[0])


[/Users/david/go/src/github.com/GoASTScanner/gas/rules/tempfiles.go:32] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > arg, _ := gas.GetString(node.Args[0])


[/Users/david/go/src/github.com/GoASTScanner/gas/tools.go:118] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > root, _ := parser.ParseFile(fileset, filename, nil, parser.ParseComments)


[/Users/david/go/src/github.com/GoASTScanner/gas/tools.go:129] - Errors unhandled. (Confidence: HIGH, Severity: LOW)
  > pkg, _ := config.Check("main.go", fileset, []*ast.File{root}, info)


Summary:
   Files: 26
   Lines: 48936
   Nosec: 2
  Issues: 6

These all seem like things that can legitimately error so checks should probably be added. Particularly strconv.ParseInt.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions