Skip to content

Commit

Permalink
Now, I am corresponding to #77, #104, #111.
Browse files Browse the repository at this point in the history
  • Loading branch information
daisukenishino2 committed Jul 12, 2019
1 parent effe412 commit 18c4ac0
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ SELECT * FROM "RefreshTokenDictionary";
SELECT * FROM "CustomizedConfirmation";
SELECT * FROM "Saml2OAuth2Data";
SELECT * FROM "FIDO2Data";
SELECT * FROM "OAuth2Revocation";
SELECT * FROM "IssuedToken";
SELECT * FROM "RequestObject";
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ SELECT * FROM "refreshTokendictionary"
SELECT * FROM "customizedconfirmation"
SELECT * FROM "saml2oauth2data"
SELECT * FROM "fido2data"
SELECT * FROM "oauth2revocation"
SELECT * FROM "issuedtoken"
SELECT * FROM "requestobject"
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ SELECT * FROM [RefreshTokenDictionary]
SELECT * FROM [CustomizedConfirmation]
SELECT * FROM [Saml2OAuth2Data]
SELECT * FROM [FIDO2Data]
SELECT * FROM [OAuth2Revocation]
SELECT * FROM [IssuedToken]
SELECT * FROM [RequestObject]
12 changes: 0 additions & 12 deletions root/programs/CommonLibrary/Co/Const.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,17 +68,6 @@ public const string Role_SystemAdminOrAdmin
public const string Role_SystemAdminOrAdminOrUser
= Role_SystemAdmin + ", " + Role_Admin + ", " + Role_User;

#if NETCORE
// Normalizeのため
/// <summary>SystemAdministratorのrole</summary>
public const string Role_SystemAdmin = "SYSTEMADMIN";

/// <summary>Administratorのrole</summary>
public const string Role_Admin = "ADMIN";

/// <summary>Userのrole</summary>
public const string Role_User = "USER";
#else
/// <summary>SystemAdministratorのrole</summary>
public const string Role_SystemAdmin = "SystemAdmin";

Expand All @@ -87,7 +76,6 @@ public const string Role_SystemAdminOrAdminOrUser

/// <summary>Userのrole</summary>
public const string Role_User = "User";
#endif

#endregion

Expand Down
4 changes: 4 additions & 0 deletions root/programs/CommonLibrary/Data/CmnUserStore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1418,7 +1418,11 @@ public static void AddToRole(ApplicationUser user, string roleName)
case EnumUserStoreType.Memory:

// ロール情報を取得する
#if NETCORE
role = CmnStore._roles.FirstOrDefault(x => x.NormalizedName == roleName);
#else
role = CmnStore._roles.FirstOrDefault(x => x.Name == roleName);
#endif

if (role == null)
{
Expand Down
2 changes: 1 addition & 1 deletion root/programs/CommonLibrary/Data/RoleStoreCore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ public Task SetNormalizedRoleNameAsync(ApplicationRole role, string normalizedNa
cancellationToken.ThrowIfCancellationRequested();
this.ThrowIfDisposed();

role.Name = normalizedName;
role.NormalizedName = normalizedName;
return Task.FromResult(0);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1800,7 +1800,7 @@ public async Task<ActionResult> ExternalLoginCallback(string returnUrl, string r
// uid(e-mail or name情報)が一致している必要がある。
// Manage(サインイン済み)なので、
// RequireUniqueEmail == false時のname and e-mailまでの一致は不要。
if (user.NormalizedUserName == uid) // ★ これでイイのか?
if (user.NormalizedUserName == uid.ToUpper()) // ★ これでイイのか?
{
// uid(e-mail, name情報)が一致している。

Expand Down

0 comments on commit 18c4ac0

Please sign in to comment.