-
Notifications
You must be signed in to change notification settings - Fork 644
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
[OIDC 12] Add admin panel for federated credential policies #10290
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SQL: CREATE TABLE [dbo].[FederatedCredentialPolicies] ( [Key] [int] NOT NULL IDENTITY, [Created] [datetime2](7) NOT NULL, [LastMatched] [datetime2](7), [TypeKey] [int] NOT NULL, [Criteria] [nvarchar](max) NOT NULL, [CreatedByUserKey] [int] NOT NULL, [PackageOwnerUserKey] [int] NOT NULL, CONSTRAINT [PK_dbo.FederatedCredentialPolicies] PRIMARY KEY ([Key]) ) CREATE INDEX [IX_CreatedByUserKey] ON [dbo].[FederatedCredentialPolicies]([CreatedByUserKey]) CREATE INDEX [IX_PackageOwnerUserKey] ON [dbo].[FederatedCredentialPolicies]([PackageOwnerUserKey]) CREATE TABLE [dbo].[FederatedCredentials] ( [Key] [int] NOT NULL IDENTITY, [TypeKey] [int] NOT NULL, [FederatedCredentialPolicyKey] [int] NOT NULL, [Identity] [nvarchar](64), [Created] [datetime2](7) NOT NULL, [Expires] [datetime2](7), CONSTRAINT [PK_dbo.FederatedCredentials] PRIMARY KEY ([Key]) ) CREATE INDEX [IX_FederatedCredentialPolicyKey] ON [dbo].[FederatedCredentials]([FederatedCredentialPolicyKey]) CREATE UNIQUE INDEX [IX_Identity] ON [dbo].[FederatedCredentials]([Identity]) ALTER TABLE [dbo].[Credentials] ADD [FederatedCredentialPolicyKey] [int] CREATE INDEX [IX_FederatedCredentialPolicyKey] ON [dbo].[Credentials]([FederatedCredentialPolicyKey]) ALTER TABLE [dbo].[Credentials] ADD CONSTRAINT [FK_dbo.Credentials_dbo.FederatedCredentialPolicies_FederatedCredentialPolicyKey] FOREIGN KEY ([FederatedCredentialPolicyKey]) REFERENCES [dbo].[FederatedCredentialPolicies] ([Key]) ALTER TABLE [dbo].[FederatedCredentialPolicies] ADD CONSTRAINT [FK_dbo.FederatedCredentialPolicies_dbo.Users_CreatedByUserKey] FOREIGN KEY ([CreatedByUserKey]) REFERENCES [dbo].[Users] ([Key]) ALTER TABLE [dbo].[FederatedCredentialPolicies] ADD CONSTRAINT [FK_dbo.FederatedCredentialPolicies_dbo.Users_PackageOwnerUserKey] FOREIGN KEY ([PackageOwnerUserKey]) REFERENCES [dbo].[Users] ([Key])
joelverhagen
changed the title
Add admin panel for federated credential policies
[OIDC 12] Add admin panel for federated credential policies
Nov 27, 2024
agr
previously approved these changes
Dec 3, 2024
# Conflicts: # src/NuGetGallery.Services/Authentication/Federated/FederatedCredentialConfiguration.cs
drewgillies
previously approved these changes
Dec 5, 2024
# Conflicts: # src/NuGetGallery.Services/Authentication/Federated/FederatedCredentialService.cs # tests/NuGetGallery.Facts/Authentication/Federated/FederatedCredentialServiceFacts.cs
# Conflicts: # src/NuGetGallery.Services/Authentication/Federated/FederatedCredentialRepository.cs # tests/NuGetGallery.Facts/Authentication/Federated/FederatedCredentialRepositoryFacts.cs
joelverhagen
dismissed stale reviews from agr and drewgillies
December 9, 2024 20:08
The base branch was changed.
drewgillies
approved these changes
Dec 9, 2024
zhhyu
reviewed
Dec 10, 2024
src/NuGetGallery/Areas/Admin/Controllers/FederatedCredentialsController.cs
Show resolved
Hide resolved
zhhyu
reviewed
Dec 10, 2024
zhhyu
approved these changes
Dec 10, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Progress on #10212.
Depends on #10289.
This PR adds a new admin panel for our team to manage federated credential policies on behalf of other users. We will use this to manual onboard users to the OIDC feature.
The new option on the admin panel index looks like this:
The admin panel looks like this:
You can add a federated credential policy for a user here:
Search results look like this:
There is a "terminology" section at the bottom as a reference for the feature.