diff --git a/build/dependencies.props b/build/dependencies.props
index 18af43d19a..d3527e5a2b 100644
--- a/build/dependencies.props
+++ b/build/dependencies.props
@@ -5,6 +5,7 @@
4.7.1
1.6.1
1.1.605
+ 2.0.0-*
15.0.0
2.2.0
7.2.1
diff --git a/samples/AzureBlob/AzureBlob.csproj b/samples/AzureBlob/AzureBlob.csproj
index b7314e9091..8ce0a3e6d9 100644
--- a/samples/AzureBlob/AzureBlob.csproj
+++ b/samples/AzureBlob/AzureBlob.csproj
@@ -3,7 +3,7 @@
- netcoreapp1.1
+ netcoreapp2.0
Exe
$(PackageTargetFallback);portable-net45+win8+wp8+wpa81
diff --git a/samples/CustomEncryptorSample/CustomEncryptorSample.csproj b/samples/CustomEncryptorSample/CustomEncryptorSample.csproj
index 60db203544..7422388415 100644
--- a/samples/CustomEncryptorSample/CustomEncryptorSample.csproj
+++ b/samples/CustomEncryptorSample/CustomEncryptorSample.csproj
@@ -3,7 +3,7 @@
- net451;netcoreapp1.1
+ net451;netcoreapp2.0
diff --git a/samples/KeyManagementSample/KeyManagementSample.csproj b/samples/KeyManagementSample/KeyManagementSample.csproj
index 355b4edab0..1b23de0ddf 100644
--- a/samples/KeyManagementSample/KeyManagementSample.csproj
+++ b/samples/KeyManagementSample/KeyManagementSample.csproj
@@ -1,7 +1,9 @@
+
+
- net451;netcoreapp1.1
+ net451;netcoreapp2.0
diff --git a/samples/NonDISample/NonDISample.csproj b/samples/NonDISample/NonDISample.csproj
index 355b4edab0..1b23de0ddf 100644
--- a/samples/NonDISample/NonDISample.csproj
+++ b/samples/NonDISample/NonDISample.csproj
@@ -1,7 +1,9 @@
+
+
- net451;netcoreapp1.1
+ net451;netcoreapp2.0
diff --git a/samples/Redis/Redis.csproj b/samples/Redis/Redis.csproj
index 21530ce9e2..73863155a2 100644
--- a/samples/Redis/Redis.csproj
+++ b/samples/Redis/Redis.csproj
@@ -3,7 +3,7 @@
- netcoreapp1.1;net451
+ netcoreapp2.0;net451
diff --git a/test/Microsoft.AspNetCore.Cryptography.Internal.Test/Microsoft.AspNetCore.Cryptography.Internal.Test.csproj b/test/Microsoft.AspNetCore.Cryptography.Internal.Test/Microsoft.AspNetCore.Cryptography.Internal.Test.csproj
index 129d71ce1f..71a60ea4d8 100644
--- a/test/Microsoft.AspNetCore.Cryptography.Internal.Test/Microsoft.AspNetCore.Cryptography.Internal.Test.csproj
+++ b/test/Microsoft.AspNetCore.Cryptography.Internal.Test/Microsoft.AspNetCore.Cryptography.Internal.Test.csproj
@@ -3,10 +3,10 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
true
- $(PackageTargetFallback);dnxcore50;portable-net451+win8
+ $(PackageTargetFallback);dnxcore50;portable-net451+win8
diff --git a/test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test.csproj b/test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test.csproj
index 42e4d7a6d8..56b23f29fd 100644
--- a/test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test.csproj
+++ b/test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test/Microsoft.AspNetCore.Cryptography.KeyDerivation.Test.csproj
@@ -3,8 +3,8 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
true
diff --git a/test/Microsoft.AspNetCore.DataProtection.Abstractions.Test/Microsoft.AspNetCore.DataProtection.Abstractions.Test.csproj b/test/Microsoft.AspNetCore.DataProtection.Abstractions.Test/Microsoft.AspNetCore.DataProtection.Abstractions.Test.csproj
index f8b5ce9a84..076480457b 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Abstractions.Test/Microsoft.AspNetCore.DataProtection.Abstractions.Test.csproj
+++ b/test/Microsoft.AspNetCore.DataProtection.Abstractions.Test/Microsoft.AspNetCore.DataProtection.Abstractions.Test.csproj
@@ -3,8 +3,8 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
diff --git a/test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test.csproj b/test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test.csproj
index 5620bd450e..fb2b75b60a 100644
--- a/test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test.csproj
+++ b/test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test/Microsoft.AspNetCore.DataProtection.AzureStorage.Test.csproj
@@ -3,10 +3,10 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
true
- $(PackageTargetFallback);dnxcore50;portable-net451+win8
+ $(PackageTargetFallback);dnxcore50;portable-net451+win8
diff --git a/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/DataProtectionProviderTests.cs b/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/DataProtectionProviderTests.cs
index c2e81fa7f2..694b612ce1 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/DataProtectionProviderTests.cs
+++ b/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/DataProtectionProviderTests.cs
@@ -106,7 +106,7 @@ namespace Microsoft.AspNetCore.DataProtection
});
}
-#if !NETCOREAPP1_1 // [[ISSUE60]] Remove this #ifdef when Core CLR gets support for EncryptedXml
+#if NET452 // [[ISSUE60]] Remove this #ifdef when Core CLR gets support for EncryptedXml
[ConditionalFact]
[ConditionalRunTestOnlyIfLocalAppDataAvailable]
[ConditionalRunTestOnlyOnWindows]
@@ -149,6 +149,9 @@ namespace Microsoft.AspNetCore.DataProtection
}
});
}
+#elif NETCOREAPP2_0
+#else
+#error Target framework needs to be updated
#endif
///
diff --git a/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/Microsoft.AspNetCore.DataProtection.Extensions.Test.csproj b/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/Microsoft.AspNetCore.DataProtection.Extensions.Test.csproj
index 59ed96d0de..4dc5e85324 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/Microsoft.AspNetCore.DataProtection.Extensions.Test.csproj
+++ b/test/Microsoft.AspNetCore.DataProtection.Extensions.Test/Microsoft.AspNetCore.DataProtection.Extensions.Test.csproj
@@ -3,8 +3,8 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
diff --git a/test/Microsoft.AspNetCore.DataProtection.Redis.Test/Microsoft.AspNetCore.DataProtection.Redis.Test.csproj b/test/Microsoft.AspNetCore.DataProtection.Redis.Test/Microsoft.AspNetCore.DataProtection.Redis.Test.csproj
index 8d0866a5e2..f873d70e1d 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Redis.Test/Microsoft.AspNetCore.DataProtection.Redis.Test.csproj
+++ b/test/Microsoft.AspNetCore.DataProtection.Redis.Test/Microsoft.AspNetCore.DataProtection.Redis.Test.csproj
@@ -3,8 +3,8 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
diff --git a/test/Microsoft.AspNetCore.DataProtection.Test/AnonymousImpersonation.cs b/test/Microsoft.AspNetCore.DataProtection.Test/AnonymousImpersonation.cs
index 8d1accf55b..89f115beba 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Test/AnonymousImpersonation.cs
+++ b/test/Microsoft.AspNetCore.DataProtection.Test/AnonymousImpersonation.cs
@@ -86,4 +86,7 @@ namespace Microsoft.AspNetCore.DataProtection
}
}
}
+#elif NETCOREAPP2_0
+#else
+#error Target framework needs to be updated
#endif
\ No newline at end of file
diff --git a/test/Microsoft.AspNetCore.DataProtection.Test/Microsoft.AspNetCore.DataProtection.Test.csproj b/test/Microsoft.AspNetCore.DataProtection.Test/Microsoft.AspNetCore.DataProtection.Test.csproj
index 0c070e19c2..e5f8052014 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Test/Microsoft.AspNetCore.DataProtection.Test.csproj
+++ b/test/Microsoft.AspNetCore.DataProtection.Test/Microsoft.AspNetCore.DataProtection.Test.csproj
@@ -3,8 +3,8 @@
- netcoreapp1.1;net452
- netcoreapp1.1
+ netcoreapp2.0;net452
+ netcoreapp2.0
true
diff --git a/test/Microsoft.AspNetCore.DataProtection.Test/Repositories/FileSystemXmlRepositoryTests.cs b/test/Microsoft.AspNetCore.DataProtection.Test/Repositories/FileSystemXmlRepositoryTests.cs
index 28cb78c8ba..bb371dd889 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Test/Repositories/FileSystemXmlRepositoryTests.cs
+++ b/test/Microsoft.AspNetCore.DataProtection.Test/Repositories/FileSystemXmlRepositoryTests.cs
@@ -159,10 +159,12 @@ namespace Microsoft.AspNetCore.DataProtection.Repositories
private static string GetLocalApplicationData()
{
-#if NETCOREAPP1_1
+#if NETCOREAPP2_0
return Environment.GetEnvironmentVariable("LOCALAPPDATA");
-#else
+#elif NET452
return Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData);
+#else
+#error Target framework needs to be updated
#endif
}
diff --git a/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/CertificateXmlEncryptionTests.cs b/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/CertificateXmlEncryptionTests.cs
index 23fd3bd06a..0dd9e072c2 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/CertificateXmlEncryptionTests.cs
+++ b/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/CertificateXmlEncryptionTests.cs
@@ -1,7 +1,7 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
-#if !NETCOREAPP1_1
+#if NET452
using System;
using System.Security.Cryptography;
using System.Security.Cryptography.Xml;
@@ -61,5 +61,8 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
}
}
}
+#elif NETCOREAPP2_0
+#else
+#error Target framework needs to be updated
#endif
diff --git a/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/DpapiXmlEncryptionTests.cs b/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/DpapiXmlEncryptionTests.cs
index a397337f8d..bcb41921d5 100644
--- a/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/DpapiXmlEncryptionTests.cs
+++ b/test/Microsoft.AspNetCore.DataProtection.Test/XmlEncryption/DpapiXmlEncryptionTests.cs
@@ -34,7 +34,7 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
XmlAssert.Equal(originalXml, roundTrippedElement);
}
-#if !NETCOREAPP1_1
+#if NET452
[ConditionalFact]
[ConditionalRunTestOnlyOnWindows]
public void Encrypt_CurrentUser_Decrypt_ImpersonatedAsAnonymous_Fails()
@@ -53,6 +53,9 @@ namespace Microsoft.AspNetCore.DataProtection.XmlEncryption
ExceptionAssert2.ThrowsCryptographicException(() =>
AnonymousImpersonation.Run(() => decryptor.Decrypt(encryptedXmlInfo.EncryptedElement)));
}
+#elif NETCOREAPP2_0
+#else
+#error Target framework needs to be updated
#endif
}
}