Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
fix: restrict web login to normal users only (#17015)
boojackf0036d563aa3
diff --git a/backend/api/v1/auth_service.go b/backend/api/v1/auth_service.goindex a22223cdf2..1a8b12f8a4 100644--- a/backend/api/v1/auth_service.go+++ b/backend/api/v1/auth_service.go@@ -171,6 +171,11 @@ func (s *AuthService) Login(ctx context.Context, req *connect.Request[v1pb.Login}if request.Web {+ // Only allow end users to use web login, not service accounts.+ if loginUser.Type != storepb.PrincipalType_END_USER {+ return nil, connect.NewError(connect.CodePermissionDenied, errors.Errorf("only users can use web login"))+ }+origin := req.Header().Get("Origin")if origin == "" {origin = req.Header().Get("grpcgateway-origin")