|
@@ -105,7 +105,15 @@ jxrWXHbT1FB6DqkdOnBbQqS1Azqz5HxLlSyEK3F60e3SgB5iZsDZ
|
|
|
var request = Decrypt(dto.Signature);
|
|
|
if (request is null)
|
|
|
throw UserFriendlyException.SameMessage("用户名或密码错误!");
|
|
|
- var res = await _identityAppService.LoginWithSignatureAsync(request, HttpContext.RequestAborted);
|
|
|
+ string res;
|
|
|
+ if (_appOptions.Value.IsLuZhou)
|
|
|
+ {
|
|
|
+ res = await _identityAppService.LoginWithSignatureAsync(request, HttpContext.RequestAborted);
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ res = await _identityAppService.LoginAsync(request, HttpContext.RequestAborted);
|
|
|
+ }
|
|
|
request.Password = string.Empty;
|
|
|
await _iSystemLogApplication.AddLog("账号登录", res, request, HttpContext, request.Username);
|
|
|
return res;
|
|
@@ -215,7 +223,7 @@ jxrWXHbT1FB6DqkdOnBbQqS1Azqz5HxLlSyEK3F60e3SgB5iZsDZ
|
|
|
{
|
|
|
if (string.IsNullOrEmpty(signature)) return null;
|
|
|
var decrypted = EncryptProvider.AESDecrypt(signature, AesKey, AesIv);
|
|
|
- if(string.IsNullOrEmpty(decrypted)) return null;
|
|
|
+ if (string.IsNullOrEmpty(decrypted)) return null;
|
|
|
return System.Text.Json.JsonSerializer.Deserialize<LoginWithSignatureRequest>(decrypted,
|
|
|
JsonDefaults.DefaultJsonSerializerOptionsWithCamelCase);
|
|
|
}
|