Project

Profile

Help

Maintenance: Planio will be observing a scheduled maintenance window this Tuesday, November 5, 2024 from 03:00 UTC until 06:30 UTC to perform urgent network maintenance in our primary data center. Your Planio account will be unavailable during this maintenance window.

Story #7231

closed

As a user, I can Read Users, group membership, and their permissions via an API

Added by bmbouter over 4 years ago. Updated about 4 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
Groomed:
Yes
Sprint Candidate:
No
Tags:
Sprint:
Sprint 79
Quarter:

Description

Background

Users need to:

  • List all users
  • View a single user
  • View group membership for that user
  • View user and group permissions for that user

URL

  • GET /pulp/api/v3/users/ - the list view
  • GET /pulp/api/v3/users/:uuid/ - the detail view
  • GET /pulp/api/v3/users/:uuid/permissions/ - list all permissions view

The model

This is defined by Django: https://github.com/django/django/blob/7af8f4127397279d19ef7c7899e93018274e2f9b/django/contrib/auth/models.py#L321-L356

/pulp/api/v3/users/:uuid/ Serializer

A list of entries like:

{
    "group_name": "foo",
    "pulp_href": "/pulp/api/v3/groups/<UUID_HERE>/"
}

/pulp/api/v3/users/:uuid/permissions/ Serializer

Each permission entry for model-level permission should have:

{
    "name": "file.view_fileremote",
    "obj": None
}

Each permission entry for the object-level permission should have:

{
    "name": "file.view_fileremote",
    "obj": "/pulp/api/v3/remotes/file/file/<UUID_HERE/"
}
Actions #1

Updated by bmbouter over 4 years ago

  • Subject changed from As a user, I can list all Pulp users to As a user, I can CRUD Users via an API
Actions #2

Updated by bmbouter over 4 years ago

  • Description updated (diff)
Actions #3

Updated by bmbouter over 4 years ago

  • Description updated (diff)
Actions #4

Updated by dkliban@redhat.com over 4 years ago

  • Description updated (diff)
Actions #5

Updated by bmbouter over 4 years ago

  • Subject changed from As a user, I can CRUD Users via an API to As a user, I can Read Users, group membership, and their permissions via an API
  • Description updated (diff)
Actions #6

Updated by dkliban@redhat.com over 4 years ago

  • Groomed changed from No to Yes
  • Sprint set to Sprint 78
Actions #7

Updated by bmbouter over 4 years ago

  • Description updated (diff)
Actions #8

Updated by fao89 over 4 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to fao89
Actions #10

Updated by bmbouter over 4 years ago

fao89 wrote:

should I move it to pulpcore? https://github.com/ansible/galaxy_ng/blob/master/galaxy_ng/app/models/auth.py

I don't think so, I believe we want to continue using the vanilla user model provided by Django.

Actions #11

Updated by pulpbot over 4 years ago

  • Status changed from ASSIGNED to POST
Actions #12

Updated by rchan about 4 years ago

  • Sprint changed from Sprint 78 to Sprint 79

Added by Fabricio Aguiar about 4 years ago

Revision 6e6f599f | View on GitHub

Read API for Users, Group membership, and Permissions

https://pulp.plan.io/issues/7231 closes #7231

Actions #13

Updated by Anonymous about 4 years ago

  • Status changed from POST to MODIFIED
  • % Done changed from 0 to 100
Actions #14

Updated by dkliban@redhat.com about 4 years ago

  • Sprint/Milestone set to 3.6.0
Actions #15

Updated by pulpbot about 4 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF