Skip to content

Commit

Permalink
Renamed AesManaged to Aes, removed obsolete test report config
Browse files Browse the repository at this point in the history
  • Loading branch information
oskardudycz committed Dec 8, 2021
1 parent e085e7f commit db901b6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
5 changes: 5 additions & 0 deletions Crypto_Shredding/.NET/CryptoShredding.sln
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CryptoShredding.IntegrationTests", "src\CryptoShredding.IntegrationTests\CryptoShredding.IntegrationTests.csproj", "{FA1C5197-1F19-4EB6-825C-08BB380283AB}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "CI", "CI", "{A6E8B7C5-D5F7-4F9E-8EDD-020FEF6D18CD}"
ProjectSection(SolutionItems) = preProject
..\..\.github\workflows\build.crypto_shredding.dotnet.yml = ..\..\.github\workflows\build.crypto_shredding.dotnet.yml
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<VSTestLogger>trx%3bLogFileName=$(MSBuildProjectName).trx</VSTestLogger>
<VSTestResultsDirectory>$(MSBuildThisFileDirectory)/bin/TestResults/$(TargetFramework)</VSTestResultsDirectory>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ public EncryptorDecryptor(CryptoRepository cryptoRepository)
public ICryptoTransform GetEncryptor(string dataSubjectId)
{
var encryptionKey = _cryptoRepository.GetExistingOrNew(dataSubjectId, CreateNewEncryptionKey);
var aesManaged = GetAesManaged(encryptionKey);
var encryptor = aesManaged.CreateEncryptor();
var aes = GetAes(encryptionKey);
var encryptor = aes.CreateEncryptor();
return encryptor;
}

Expand All @@ -29,8 +29,8 @@ public ICryptoTransform GetDecryptor(string dataSubjectId)
return default;
}

var aesManaged = GetAesManaged(encryptionKey);
var decryptor = aesManaged.CreateDecryptor();
var aes = GetAes(encryptionKey);
var decryptor = aes.CreateDecryptor();
return decryptor;
}

Expand All @@ -47,7 +47,7 @@ private EncryptionKey CreateNewEncryptionKey()
return encryptionKey;
}

private Aes GetAesManaged(EncryptionKey encryptionKey)
private Aes GetAes(EncryptionKey encryptionKey)
{
var aes = Aes.Create();

Expand Down

0 comments on commit db901b6

Please sign in to comment.