using IntegrationKSSS.WebService.Infrastructure.Cryptography;

namespace IntegrationKSSS.WebService.Infrastructure.Services;
public class AuthService : IAuthService
{
    #region Methods
    public async Task<bool> Auth(string login, string password)
    {
        string _login = "5WndfpUBeL21vPl1T52S2w==",
               _password = "wK/ZViL6VAYL1FNYO10vLg==";

        return await Task.Run(() =>
               (_login.DecryptString(AesConfiguration.Key, AesConfiguration.IV) == login &&
               _password.DecryptString(AesConfiguration.Key, AesConfiguration.IV) == password) ?
               true :
               false);
    } 
    #endregion
}