-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor Authorization and Project Configurations in Central Dogma #1048
Comments
System Admin? |
Overall, it seems like the proposal is to modify the current CD structure to follow Github more closely and I agree this is simpler for users to reason about. Having said this, some thoughts:
|
Thank you for your feedback. 👍
If this approach is acceptable, I’d be happy to provide a detailed migration plan.
That's a good question. 👍
Which APIs are you talking to?
This isn’t intended to address specific issues; rather, it’s part of a broader effort to enhance the authorization system in Central Dogma based on improvements identified during usage. Please consider it as a general refactoring of the authorization and configuration systems in Central Dogma. |
e.g. there may be more, but this comes to mind centraldogma/server/src/main/java/com/linecorp/centraldogma/server/internal/api/TokenService.java Line 108 in 755b3b4
I think as an overall direction the approach seems good. I guess my question was more about how much resources are we investing to this improvement. As an overall direction, the proposal seems good though. |
Oh, I forgot that API. Yeah, I need to fix that as well. 😉
Good point. I’m not entirely certain about the exact resources that I need to put. My goal is to complete it this quarter, though it may extend beyond that. However, I believe this improvement is essential to enhancing Central Dogma as a valuable product. 😉 |
Motivation: The anonymous role poses a security risk, as described in [issue line#1048](line#1048). Modifications: - Removed the anonymous role, effectively reversing changes introduced in [PR line#917](line#917). - Added `CentralDogmaExtension.accessToken()` for adding the access token to the testing Dogma client. - There was a bug after we introduced the anonymous role, which is an anonymous can create a project. - Becuase the anonymous role is now removed, the testing dogma client without an access token can't create a project if the auth provider is set to dogma extension. Result: - The anonymous role has been removed.
Motivation: The term "Admin" does not clearly convey its purpose as a system-wide administrator role, as discussed in [issue line#1048](line#1048). Renaming this role improves clarity for users and developers. Modifications: - Renamed all "Admin" to "SystemAdmin" across the codebase. - Updated `MetadataService.updateTokenLevel()` to avoid directly accessing the `admin` property. Result: - The role name "Admin" has been replaced with "SystemAdmin".
Motivation: The anonymous role poses a security risk, as described in [issue #1048](#1048). Modifications: - Removed the anonymous role, effectively reversing changes introduced in [PR #917](#917). - Added `CentralDogmaExtension.accessToken()` for adding the access token to the testing Dogma client. - There was a bug after we introduced the anonymous role, which is an anonymous can create a project. - Becuase the anonymous role is now removed, the testing dogma client without an access token can't create a project if the auth provider is set to dogma extension. Result: - The anonymous role has been removed.
Motivation: The term "Admin" does not clearly convey its purpose as a system-wide administrator role, as discussed in [issue #1048](#1048). Renaming this role improves clarity for users and developers. Modifications: - Renamed all "Admin" to "SystemAdmin" across the codebase. - Updated `MetadataService.updateTokenLevel()` to avoid directly accessing the `admin` property. Result: - The role name "Admin" has been replaced with "SystemAdmin". - (Breaking) - `authentication.administrators` in dogma.json is now `authentication.systemAdministrators`. - (Deprecation) - Use `systemAdmin` property instead of `admin` when creating a token via REST API: ```json {"appId": "foo", "isSystemAdmin": true, ...} ``` - Use `SYSTEMADMIN` instead of `admin` when changing the token level: ```json {"level":"SYSTEMADMIN"} ```
Summary
The current authorization system in Central Dogma has several limitations and issues regarding security, role permissions, and project management. This proposal addresses these issues by refining roles and permissions, adding visibility options, and improving configuration management.
Problems and Limitations
Insecure Anonymous Role
Anonymous
role that allows repository access without authentication.Anonymous
role entirely to restrict access to logged-in users only.Ineffective Guest Role and Repository Visibility
Guest
role can have read or write permissions, which is not ideal for permissions management. It can make sensitive information vulnerable.Guest
role with write permissions is unusual, and it limits options for repository visibility.Guest
role. Introduce a visibility option (public
orprivate
) at the repository level:Limited Project-Level Permissions
Lack of Team Structure
Terminology Alignment with Industry Standards
Admin
to describe the Central Dogma cluster owner, but GitHub and similar platforms useAdmin
for repository ownership, which may cause confusion.Admin
(the term used for cluster owners) to something clearer and more intuitive. Proposed name:ClusterAdmin
.Improvement of Configuration Storage for Projects and Repositories
meta
repository at the project level. Accessing this information requiresWRITE
permissions on themeta
repository, which will be hidden.meta
repository will be hidden to public users, which restricts management of configurations.Admin
s for accessing the information.Proposed Changes
Role and Permission Revisions
Enhanced Project and Repository Permissions
Team-Based Access Control
Terminology Update
Admin
designation for the cluster owner toClusterAdmin
(or other suggestions welcome) to align terminology more closely with industry standards.Configuration Management Improvements
Goals and Benefits
The text was updated successfully, but these errors were encountered: