Skip to content
Snippets Groups Projects
Commit 54c9a118 authored by Janis Daniel Dähne's avatar Janis Daniel Dähne
Browse files

- removed commented old UP auth code

parent b7390d25
No related branches found
No related tags found
No related merge requests found
......@@ -542,13 +542,9 @@ namespace ClientServer.Controllers.Core.Login
cts.CancelAfter(TimeSpan.FromMilliseconds(Constants.OstepuRequestTimeoutInMs));
HttpResponseMessage jsonResponse = null;
//HttpUtility.HtmlEncode(unencoded)
// var encodedTid = WebUtility.HtmlEncode(tuple.Tid); //removes all not ascii characters?
try
{
// jsonResponse = await client.GetAsync(AppConfiguration.ExternalLoginUrl + encodedTid, cts.Token);
HttpContent content = new StringContent("\"" + tuple.Tid + "\"", Encoding.UTF8, "application/json");
jsonResponse = await client.PostAsync(AppConfiguration.ExternalLoginUrl, content, cts.Token);
}
......@@ -665,13 +661,9 @@ namespace ClientServer.Controllers.Core.Login
cts.CancelAfter(TimeSpan.FromMilliseconds(Constants.OstepuRequestTimeoutInMs));
HttpResponseMessage jsonResponse = null;
//HttpUtility.HtmlEncode(unencoded)
// var encodedTid = WebUtility.HtmlEncode(tid); //removes all not ascii characters?
try
{
// jsonResponse = await client.GetAsync(AppConfiguration.ExternalLoginUrl + encodedTid, cts.Token);
HttpContent content = new StringContent("\"" + tid + "\"", Encoding.UTF8, "application/json");
jsonResponse = await client.PostAsync(AppConfiguration.ExternalLoginUrl, content, cts.Token);
......@@ -705,18 +697,6 @@ namespace ClientServer.Controllers.Core.Login
//user is logged in (or should be) now get data and verify user...
var contentResult = jsonResponse.Content.ReadAsStringAsync().Result;
// var transactionResult = Jc.Deserialize<OstepuTransactionData>(contentResult);
//
// if (transactionResult?.Content == null)
// {
// //http status was wrong or something other went wrong... the user is not longer available in ostepu...
// await
// Response.WriteAsync(
// Jc.Serialize(new BasicResponse(ResponseCode.InvalidRequest, "invalid data")));
// return;
// }
//we need to check if the external use already has a yapex account...
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment