Skip to content

Commit 1c70528

Browse files
committed
cleanup
Signed-off-by: Yuval Kohavi <yuval.kohavi@gmail.com>
1 parent bf92f70 commit 1c70528

File tree

3 files changed

+2
-10
lines changed

3 files changed

+2
-10
lines changed

go/controller/cmd/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,8 +329,8 @@ func main() {
329329
cfg.DefaultModelConfig,
330330
)
331331

332-
authorizer := auth.DefaultAuthorizer()
333-
authenticator := auth.DefaultAuthn()
332+
authorizer := &auth.NothingAuthorizer{}
333+
authenticator := &auth.UnsecureAuthenticator{}
334334

335335
a2aHandler := a2a.NewA2AHttpMux(httpserver.APIPathA2A, authenticator)
336336

go/internal/httpserver/auth/authn.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,6 @@ const (
2525
VerbDelete Verb = "delete"
2626
)
2727

28-
func DefaultAuthn() AuthProvider {
29-
return &UnsecureAuthenticator{}
30-
}
31-
3228
func AuthSessionFrom(ctx context.Context) (*Session, bool) {
3329
v, ok := ctx.Value(sessionKey).(*Session)
3430
return v, ok && v != nil

go/internal/httpserver/auth/authz.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@ import (
44
"context"
55
)
66

7-
func DefaultAuthorizer() Authorizer {
8-
return &NothingAuthorizer{}
9-
}
10-
117
type Authorizer interface {
128
Check(ctx context.Context, principal Principal, verb Verb, resource Resource) error
139
}

0 commit comments

Comments
 (0)