Skip to content

Commit

Permalink
fix: mark gosec false positives
Browse files Browse the repository at this point in the history
  • Loading branch information
aeneasr committed Jul 19, 2022
1 parent b2b0eb0 commit 13eaddb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions internal/testhelpers/selfservice_settings.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,7 @@ func NewSettingsAPIServer(t *testing.T, reg *driver.RegistryDefault, ids map[str

reg.Config(context.Background()).MustSet(config.ViperKeyPublicBaseURL, tsp.URL)
reg.Config(context.Background()).MustSet(config.ViperKeyAdminBaseURL, tsa.URL)
// #nosec G112
return tsp, tsa, AddAndLoginIdentities(t, reg, &httptest.Server{Config: &http.Server{Handler: public}, URL: tsp.URL}, ids)
}

Expand Down
1 change: 1 addition & 0 deletions selfservice/strategy/oidc/strategy_helper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ func newHydraIntegration(t *testing.T, remote *string, subject *string, claims *
parsed, err := url.ParseRequestURI(addr)
require.NoError(t, err)

// #nosec G112
server := &http.Server{Addr: ":" + parsed.Port(), Handler: router}
go func(t *testing.T) {
if err := server.ListenAndServe(); err != http.ErrServerClosed {
Expand Down
1 change: 1 addition & 0 deletions test/e2e/hydra-login-consent/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ func main() {
})

addr := ":" + osx.GetenvDefault("PORT", "4446")
// #nosec G112
server := &http.Server{Addr: addr, Handler: router}
fmt.Printf("Starting web server at %s\n", addr)
check(server.ListenAndServe())
Expand Down

0 comments on commit 13eaddb

Please sign in to comment.