Reduced privileges for human users until elevation requested

Đang mở
#2,980 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 2 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
38/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
go, kubernetes, postgresql

Hướng nghiên cứu

Bắt đầu tại pkg/cluster/cluster.go, ở initPreparedDatabaseRoles, và theo dõi cách defaultRoles, defaultUsers, team_admin_role và enable_admin_role_for_users ảnh hưởng đến các vai trò cơ sở dữ liệu được chuẩn bị. So sánh việc triển khai với hành vi nâng quyền được ghi trong tài liệu và xác định xem vai trò quản trị viên được hardcode có phải là chủ ý hay không; được xem là hoàn tất khi hành vi dự kiến đọc trước và tự nâng quyền đã được làm rõ hoặc sửa chữa.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Please, answer some short questions which should help us to understand your problem / question better?

  • Which image of the operator are you using? ghcr.io/zalando/postgres-operator:v1.14.0
  • Where do you run it - cloud or metal? Kubernetes or OpenShift? GCP
  • Are you running Postgres Operator in production? On an experimental basis
  • Type of issue? Bug report / discussion

We are setting up access for human users to our databases, using the Teams API to create users.
We were looking for a way to make it so that human users have only read access when first connecting to the database, but can use GRANT ROLE or SET ROLE to give themselves more access if needed.

We use the defaultRoles/defaultUsers on preparedDatabases, so by default the human users are given admin, which has access to owner-roles, given them full access to everything.

Looking at the documentation, we thought maybe setting team_admin_role to the reader role would give us what we needed, but then they can't elevate themselves. Our understanding of the enable_admin_role_for_users was that this should be possible, but it doesn't seem to work that way.

Is what we want to do possible somehow?

Is our understanding of enable_admin_role_for_users wrong, or is there a bug when that option is used for the defaultRoles created for preparedDatabases?

We are wondering if the hardcoding of admin in initPreparedDatabaseRoles is a bug, or intentional?

Ngôn ngữ chính
Go
Star
5.3k
Fork
1.1k
Merge trung bình
3 ngày 17 giờ
Pull request đã merge (30 ngày)
11

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của zalando/postgres-operator

Tất cả issue của zalando/postgres-operator

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.