Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 39 of 39 for IsResourceRequest (0.34 sec)

  1. staging/src/k8s.io/apiserver/pkg/audit/request.go

    		for k, v := range user.GetExtra() {
    			ev.User.Extra[k] = authnv1.ExtraValue(v)
    		}
    		ev.User.Groups = user.GetGroups()
    		ev.User.UID = user.GetUID()
    	}
    
    	if attribs.IsResourceRequest() {
    		ev.ObjectRef = &auditinternal.ObjectReference{
    			Namespace:   attribs.GetNamespace(),
    			Name:        attribs.GetName(),
    			Resource:    attribs.GetResource(),
    			Subresource: attribs.GetSubresource(),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jul 03 16:16:51 UTC 2023
    - 9K bytes
    - Viewed (0)
  2. pkg/registry/core/serviceaccount/storage/token.go

    func newContext(ctx context.Context, resource, name, namespace string, gvk schema.GroupVersionKind) context.Context {
    	newInfo := genericapirequest.RequestInfo{
    		IsResourceRequest: true,
    		Verb:              "get",
    		Namespace:         namespace,
    		Resource:          resource,
    		Name:              name,
    		Parts:             []string{resource, name},
    		APIGroup:          gvk.Group,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Feb 05 10:24:31 UTC 2024
    - 10K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/util/peerproxy/peerproxy_handler.go

    		if !ok {
    			responsewriters.InternalError(w, r, errors.New("no RequestInfo found in the context"))
    			return
    		}
    
    		// Allow non-resource requests
    		if !requestInfo.IsResourceRequest {
    			klog.V(3).Infof("Not a resource request skipping proxying")
    			handler.ServeHTTP(w, r)
    			return
    		}
    
    		// Request has already been proxied once, it must be served locally
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jul 19 00:36:22 UTC 2023
    - 11.5K bytes
    - Viewed (0)
  4. plugin/pkg/auth/authorizer/node/node_authorizer.go

    		return authorizer.DecisionNoOpinion, fmt.Sprintf("unknown node for user %q", attrs.GetUser().GetName()), nil
    	}
    
    	// subdivide access to specific resources
    	if attrs.IsResourceRequest() {
    		requestResource := schema.GroupResource{Group: attrs.GetAPIGroup(), Resource: attrs.GetResource()}
    		switch requestResource {
    		case secretResource:
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 21:22:55 UTC 2024
    - 16K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiserver/plugin/pkg/authorizer/webhook/webhook.go

    		r.Spec = authorizationv1.SubjectAccessReviewSpec{
    			User:   user.GetName(),
    			UID:    user.GetUID(),
    			Groups: user.GetGroups(),
    			Extra:  convertToSARExtra(user.GetExtra()),
    		}
    	}
    
    	if attr.IsResourceRequest() {
    		r.Spec.ResourceAttributes = &authorizationv1.ResourceAttributes{
    			Namespace:   attr.GetNamespace(),
    			Verb:        attr.GetVerb(),
    			Group:       attr.GetAPIGroup(),
    			Version:     attr.GetAPIVersion(),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Mar 04 19:01:15 UTC 2024
    - 18.4K bytes
    - Viewed (0)
  6. plugin/pkg/auth/authorizer/rbac/rbac_test.go

    func (d *defaultAttributes) GetAPIGroup() string     { return d.apiGroup }
    func (d *defaultAttributes) GetAPIVersion() string   { return "" }
    func (d *defaultAttributes) IsResourceRequest() bool { return true }
    func (d *defaultAttributes) GetPath() string         { return "" }
    
    func TestAuthorizer(t *testing.T) {
    	tests := []struct {
    		roles               []*rbacv1.Role
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Sep 24 15:14:54 UTC 2019
    - 21.1K bytes
    - Viewed (0)
  7. pkg/auth/authorizer/abac/abac_test.go

    		{User: uNoResource, Verb: "get", Path: "/foo/bar/baz", Resource: "", NS: "", ExpectDecision: authorizer.DecisionAllow},
    		// but cannot get any request where IsResourceRequest() == true
    		{User: uNoResource, Verb: "get", Path: "/", Resource: "", NS: "bar", ExpectDecision: authorizer.DecisionNoOpinion},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Sep 24 15:14:54 UTC 2019
    - 40K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiextensions-apiserver/pkg/apiserver/customresource_handler.go

    	if !ok {
    		responsewriters.ErrorNegotiated(
    			apierrors.NewInternalError(fmt.Errorf("no RequestInfo found in the context")),
    			Codecs, schema.GroupVersion{}, w, req,
    		)
    		return
    	}
    	if !requestInfo.IsResourceRequest {
    		pathParts := splitPath(requestInfo.Path)
    		// only match /apis/<group>/<version>
    		// only registered under /apis
    		if len(pathParts) == 3 {
    			r.versionDiscoveryHandler.ServeHTTP(w, req)
    			return
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Feb 28 19:06:46 UTC 2024
    - 52.9K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store_test.go

    	}
    }
    
    func fakeRequestInfo(resource, apiGroup string) *genericapirequest.RequestInfo {
    	return &genericapirequest.RequestInfo{
    		IsResourceRequest: true,
    		Path:              "/api/v1/test",
    		Verb:              "test",
    		APIPrefix:         "api",
    		APIGroup:          apiGroup,
    		APIVersion:        "v1",
    		Namespace:         "",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 12 10:12:02 UTC 2024
    - 101.8K bytes
    - Viewed (0)
Back to top