Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for authorizeFunc (0.36 sec)

  1. pkg/kubelet/server/server_test.go

    	return nil, nil
    }
    
    type fakeAuth struct {
    	authenticateFunc func(*http.Request) (*authenticator.Response, bool, error)
    	attributesFunc   func(user.Info, *http.Request) authorizer.Attributes
    	authorizeFunc    func(authorizer.Attributes) (authorized authorizer.Decision, reason string, err error)
    }
    
    func (f *fakeAuth) AuthenticateRequest(req *http.Request) (*authenticator.Response, bool, error) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 51.5K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/authorization/authorizer/interfaces.go

    // authorized, otherwise it returns an error.
    type Authorizer interface {
    	Authorize(ctx context.Context, a Attributes) (authorized Decision, reason string, err error)
    }
    
    type AuthorizerFunc func(ctx context.Context, a Attributes) (Decision, string, error)
    
    func (f AuthorizerFunc) Authorize(ctx context.Context, a Attributes) (Decision, string, error) {
    	return f(ctx, a)
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 06 14:36:14 UTC 2023
    - 4.8K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/admission/plugin/policy/validating/caching_authorizer_test.go

    				},
    			},
    		},
    	} {
    		t.Run(tc.name, func(t *testing.T) {
    			var misses int
    			frontend := newCachingAuthorizer(func() authorizer.Authorizer {
    				return authorizer.AuthorizerFunc(func(_ context.Context, attributes authorizer.Attributes) (authorizer.Decision, string, error) {
    					if misses >= len(tc.backend) {
    						t.Fatalf("got more than expected %d backend invocations", len(tc.backend))
    					}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Feb 12 18:58:24 UTC 2024
    - 6.3K bytes
    - Viewed (0)
Back to top