|
|
@@ -56,7 +56,7 @@ namespace Learun.Application.WebApi.Modules.Hetian |
|
|
|
{ |
|
|
|
var loginModel1 = this.GetReqData(); |
|
|
|
var loginModel = loginModel1.ToObject<LoginModel>(); |
|
|
|
LogHelper.WriteToLog($"loginModel :{loginModel.ToJson()}"); |
|
|
|
//LogHelper.WriteToLog($"loginModel :{loginModel.ToJson()}"); |
|
|
|
var ticket = loginModel.ticket; |
|
|
|
//var uid = "180018"; |
|
|
|
if (!string.IsNullOrEmpty(ticket)) |
|
|
@@ -66,17 +66,17 @@ namespace Learun.Application.WebApi.Modules.Hetian |
|
|
|
|
|
|
|
url.QueryItems.Add("service", HttpUtility.UrlEncode(CasAuthentication.ServerName)); |
|
|
|
url.QueryItems.Add("ticket", HttpUtility.UrlEncode(ticket)); |
|
|
|
LogHelper.WriteToLog($"validationUrl:{validationUrl}"); |
|
|
|
//LogHelper.WriteToLog($"validationUrl:{validationUrl}"); |
|
|
|
var a = PerformHttpGet(validationUrl, true); |
|
|
|
LogHelper.WriteToLog($"a :{a}"); |
|
|
|
//LogHelper.WriteToLog($"a :{a}"); |
|
|
|
if (a.Contains("PerformHttpGet")) |
|
|
|
{ |
|
|
|
return Fail("PerformHttpGet err"); |
|
|
|
} |
|
|
|
var serviceResponse = ServiceResponse.ParseResponse(a); |
|
|
|
LogHelper.WriteToLog($"serviceResponse:{serviceResponse.ToJson()}"); |
|
|
|
//LogHelper.WriteToLog($"serviceResponse:{serviceResponse.ToJson()}"); |
|
|
|
AuthenticationSuccess authSuccessResponse = (AuthenticationSuccess)serviceResponse.Item; |
|
|
|
LogHelper.WriteToLog($"authSuccessResponse:{authSuccessResponse.ToJson()}"); |
|
|
|
//LogHelper.WriteToLog($"authSuccessResponse:{authSuccessResponse.ToJson()}"); |
|
|
|
var uid = authSuccessResponse.User; |
|
|
|
if (!uid.IsNullOrWhiteSpace()) |
|
|
|
{ |
|
|
|