insidersec/insider

Skip files based on pattern

DrakezulsMinimalism opened this issue · 2 comments

Is your feature request related to a problem? Please describe.
I scanned my whole repository and classes like "SomethingControllerTests" in C# were flagged with missing CSRF protection.

Describe the solution you'd like
Flag and/or configurable pattern to exclude files, for example by specifying a filename pattern *Tests.cs or similar.

Describe alternatives you've considered
In the specific case of tests, analyzers could skip files after looking for language/library specific terms such as annotations or fixtures.

Seems that I did not see the "exclude" setting.
Maybe tests could be excluded by default though, depending on the confidence that the file is actually a test?

I don't think that add tests to exclude in default should be good, because the organization of tests could be different in projects. What do you think guys @danilodeveloper @bieeldeveloper ?