-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
29 changed files
with
900 additions
and
305 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,6 +1,15 @@ | ||
<?xml version='1.0' encoding='utf-8'?> | ||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)"> | ||
<Profiles> | ||
<Profile Name="(Default)" /> | ||
</Profiles> | ||
</SettingsFile> | ||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="LauncherDM.Properties" GeneratedClassName="SettingsApp"> | ||
<Profiles /> | ||
<Settings> | ||
<Setting Name="Ip" Type="System.String" Scope="User"> | ||
<Value Profile="(Default)">127.0.0.1</Value> | ||
</Setting> | ||
<Setting Name="Port" Type="System.String" Scope="User"> | ||
<Value Profile="(Default)">25590</Value> | ||
</Setting> | ||
<Setting Name="Token" Type="System.String" Scope="User"> | ||
<Value Profile="(Default)" /> | ||
</Setting> | ||
</Settings> | ||
</SettingsFile> |
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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
using LauncherDM.Services.Interfaces; | ||
using ServerTCP; | ||
using ServerTCP.Сryptographies; | ||
|
||
namespace LauncherDM.Services | ||
{ | ||
internal class AuthorizationService : IAuthorizationService | ||
{ | ||
private IServerRequestService _serverRequest; | ||
public bool Authorization(string login, string password) | ||
{ | ||
//var requestPublicKey = _serverRequest.SendMessageRequest(MessageHeader.MessageType.PublicKey); | ||
//var publicKey = requestPublicKey.Message.ToString(); | ||
|
||
var data = string.Concat(login, ",", password); | ||
//var cryptMessage = CryptoRsa.Encrypt(publicKey, data); | ||
//var requestToken = _serverRequest.SendMessageRequest(cryptMessage, MessageHeader.MessageType.Login); | ||
|
||
var requestToken = _serverRequest.SendMessageRequest(data, MessageHeader.MessageType.Login); | ||
return false; | ||
} | ||
|
||
public AuthorizationService() | ||
{ | ||
_serverRequest = new ServerRequestService(); | ||
} | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace LauncherDM.Services.Interfaces | ||
{ | ||
internal interface IAuthorizationService | ||
{ | ||
bool Authorization(string login, string password); | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
namespace LauncherDM.Services.Interfaces | ||
{ | ||
interface IRegAndLogWindowService | ||
{ | ||
} | ||
} |
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,16 +1,12 @@ | ||
using ServerTCP; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using static ServerTCP.MessageLanguages; | ||
|
||
namespace LauncherDM.Services.Interfaces | ||
{ | ||
interface IServerRequestService | ||
{ | ||
public MessageHeader SendMessageRequest(string data, MessageHeader.MessageType messageType, int length); | ||
public MessageHeader SendMessageRequest(object data, MessageHeader.MessageType messageType, bool loadToken = false); | ||
|
||
public MessageHeader SendMessageRequest(MessageHeader.MessageType messageType); | ||
public MessageHeader SendMessageRequest(MessageHeader.MessageType messageType, bool loadToken = false); | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
LauncherDM/Services/Interfaces/IWindowAnimationsService.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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace LauncherDM.Services.Interfaces | ||
{ | ||
interface IWindowAnimationsService | ||
{ | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
using LauncherDM.Services.Interfaces; | ||
|
||
namespace LauncherDM.Services | ||
{ | ||
class RegAndLogWindowServiceService : IRegAndLogWindowService | ||
{ | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
using LauncherDM.Services.Interfaces; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace LauncherDM.Services | ||
{ | ||
class WindowAnimationsService : IWindowAnimationsService | ||
{ | ||
} | ||
} |
Oops, something went wrong.