oidc auth provider does not support role mapping rules using custom keys

Đang mở
#6,641 2 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 1 ngày

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

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
25/100
Loại issue
Tính năng
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Đình trệ
Công nghệ
go
Lĩnh vực
authentication, security

Hướng nghiên cứu

Start with pkg/auth/authproviders/oidc/backend_impl.go to review the currently supported claim keys, then compare that behavior with the ACS authentication-provider documentation linked in the issue. The scope needs to be resolved between supporting arbitrary custom claims, restricting or validating allowed claims, and documenting the existing mappings; done means the chosen behavior is implemented or clearly documented.

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

Mô tả

Roles can be mapped to oidc users based on claims. While the rules allow setting arbitrary claims, the oidc implementation only allows a fixed set. I would have used the Groups claim but Auth0 restricts setting that claim. Digging into the code I found that backend_impl.go limits my choices to name, email, sub, groups, account_id and, as a boolean, is_org_admin. And, while the ACS documentation notes that sub is mapped to userid, it makes no mention that account_id is mapped to orgid. I was able to meet my need by creating an account_id claim and a rule matching value stored in orgid to a role, but that was not at all obvious.

The best case may be fully supporting custom claims within the oidc provider. If not, then restricting rules to allowed claims would be helpful, and if not that, then please document the limitations.

Ngôn ngữ chính
Go
Star
1.3k
Fork
194
Merge trung bình
2 ngày 20 giờ
Pull request đã merge (30 ngày)
392

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 stackrox/stackrox

Tất cả issue của stackrox/stackrox

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.