-
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed ISSOService interface to be clearer and to use correct user
- Loading branch information
1 parent
570b894
commit d4f6dfd
Showing
8 changed files
with
146 additions
and
77 deletions.
There are no files selected for viewing
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
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
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
21 changes: 10 additions & 11 deletions
21
src/IdentityApplication/ApplicationServices/ISSOProvidersService.cs
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,29 @@ | ||
using Application.Interfaces; | ||
using Application.Resources.Shared; | ||
using Common; | ||
using Domain.Common.ValueObjects; | ||
|
||
namespace IdentityApplication.ApplicationServices; | ||
|
||
/// <summary> | ||
/// Defines a service for accessing registered <see cref="ISSOAuthenticationProvider" />s | ||
/// Defines a service for accessing the registered <see cref="ISSOAuthenticationProvider" />s | ||
/// </summary> | ||
public interface ISSOProvidersService | ||
{ | ||
Task<Result<Optional<ISSOAuthenticationProvider>, Error>> FindByProviderNameAsync(string providerName, | ||
CancellationToken cancellationToken); | ||
|
||
Task<Result<Optional<ISSOAuthenticationProvider>, Error>> FindByUserIdAsync(ICallerContext caller, | ||
Identifier userId, string providerName, | ||
CancellationToken cancellationToken); | ||
string userId, string providerName, CancellationToken cancellationToken); | ||
|
||
Task<Result<IReadOnlyList<ProviderAuthenticationTokens>, Error>> GetTokensAsync(ICallerContext caller, | ||
Identifier userId, CancellationToken cancellationToken); | ||
|
||
Task<Result<Error>> SaveUserInfoAsync(ICallerContext caller, string providerName, Identifier userId, | ||
SSOUserInfo userInfo, | ||
CancellationToken cancellationToken); | ||
|
||
Task<Result<Error>> SaveUserTokensAsync(ICallerContext caller, string providerName, Identifier userId, | ||
ProviderAuthenticationTokens tokens, | ||
CancellationToken cancellationToken); | ||
Task<Result<IReadOnlyList<ProviderAuthenticationTokens>, Error>> GetTokensOnBehalfOfUserAsync(ICallerContext caller, | ||
string userId, CancellationToken cancellationToken); | ||
|
||
Task<Result<Error>> SaveUserInfoAsync(ICallerContext caller, string providerName, string userId, | ||
SSOUserInfo userInfo, CancellationToken cancellationToken); | ||
|
||
Task<Result<Error>> SaveUserTokensAsync(ICallerContext caller, string providerName, string userId, | ||
ProviderAuthenticationTokens tokens, CancellationToken cancellationToken); | ||
} |
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
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
Oops, something went wrong.