Skip to content

Commit dbc5a3d

Browse files
szhGitHub Enterprise
authored andcommitted
Merge pull request #31 from Conjur-Enterprise/fix-gosec
CNJR-5372: Fix 'nosec' comments
2 parents 510f413 + 1bb865c commit dbc5a3d

File tree

3 files changed

+13
-3
lines changed

3 files changed

+13
-3
lines changed

CONTRIBUTING.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,17 @@ To run linting checks via the Code Climate golint engine, simply run:
209209
./bin/check_style
210210
```
211211

212+
### gosec
213+
214+
We use [gosec](https://github.com/securego/gosec) to perform static analysis of
215+
our codebase in our CI for all changed code. To run gosec locally for the entire
216+
repository, simply run:
217+
218+
```sh-session
219+
go install github.com/securego/gosec/v2/cmd/gosec@latest
220+
$(go env GOPATH)/bin/gosec ./...
221+
```
222+
212223
### Testing Individual Connectors
213224

214225
For instructions on how to test individual connectors, see the README.md file in

bin/juxtaposer/tester/db/db.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,13 +77,12 @@ func (manager *DriverManager) ensureWantedDbDataState() error {
7777
insertItemStatement := QueryTypes["insertItem"] +
7878
fmt.Sprintf("(%s)", manager.Tester.GetQueryMarkers(5))
7979

80-
/* #nosec */
8180
err = manager.Tester.Query(insertItemStatement,
8281
fmt.Sprintf("%s%d", NameFieldPrefix, itemIndex),
8382
itemIndex,
8483
time.Now().AddDate(0, 0, itemIndex),
8584
float32(itemIndex)*10,
86-
rand.Int31()&0x1,
85+
rand.Int31()&0x1, // #nosec
8786
)
8887

8988
if err != nil {

third_party/go-mssqldb

0 commit comments

Comments
 (0)