Skip to content

Commit 94e04fa

Browse files
jmukguptasu
authored andcommitted
suppress security lint warnings for a while. (istio#1830)
* suppress security lint warnings for a while. Those suppression should be removed once istio#1446 is fixed. * exclude mixer/adapter/svcctrl * a few more suppressions (and a run of fmt.sh) * fix on config * remove mixer/pkg/il suppression
1 parent c5a2b3b commit 94e04fa

File tree

5 files changed

+7
-4
lines changed

5 files changed

+7
-4
lines changed

bin/linters.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ docker run\
2424
-w /go/src/istio.io/istio\
2525
gcr.io/mukai-istio/linter:bbcfb47f85643d4f5a7b1c092280d33ffd214c10\
2626
--config=./lintconfig.json \
27-
./... || true
27+
./...
2828
echo 'linters OK'
2929

3030
echo 'Checking licences'

lintconfig.json

+2
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@
2424
"enableGC": true,
2525
"exclude": [
2626
"vendor",
27+
"mixer/adapter/svcctrl",
28+
"^security",
2729
".pb.go",
2830
"mixer/pkg/config/proto/combined.go",
2931
".*.gen.go",

lintconfig_base.json

+2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@
2727
],
2828
"exclude": [
2929
"vendor",
30+
"mixer/adapter/svcctrl",
31+
"^security",
3032
".pb.go",
3133
"mixer/pkg/config/proto/combined.go",
3234
".*.gen.go",

mixer/adapter/svcctrl/reportbuilder_test.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,12 @@
1515
package svcctrl
1616

1717
import (
18+
"reflect"
1819
"testing"
1920
"time"
2021

2122
sc "google.golang.org/api/servicecontrol/v1"
2223

23-
"reflect"
24-
2524
"istio.io/istio/mixer/adapter/svcctrl/template/svcctrlreport"
2625
)
2726

mixer/pkg/adapter/requestData_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ func TestNewContextWithRequestData(t *testing.T) {
5050
func TestRequestDataFromContextWithCollidingInt0Key(t *testing.T) {
5151
badKey := 0
5252
wantBadKeyData := "some data associated with bad key"
53-
ctx := context.WithValue(context.Background(), badKey, wantBadKeyData)
53+
ctx := context.WithValue(context.Background(), badKey, wantBadKeyData) // nolint: golint
5454

5555
wantGoodKeyData := &RequestData{DestinationService: Service{FullName: "foo.bar"}}
5656
ctx = context.WithValue(ctx, requestDataKey, wantGoodKeyData)

0 commit comments

Comments
 (0)