117 references to SHA256
Aspire.Dashboard (1)
DashboardWebApplication.cs (1)
663certThumbprint ??= context.ClientCertificate.GetCertHashString(HashAlgorithmName.SHA256);
dotnet-dev-certs (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
HttpStress (1)
Program.cs (1)
398var certReq = new CertificateRequest($"CN={LocalhostName}", rsa, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
IIS.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
IIS.LongTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
IIS.NewHandler.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
IIS.NewShim.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
IIS.ShadowCopy.Tests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
IISExpress.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\ClientCertificateFixture.cs (1)
31parentKey, HashAlgorithmName.SHA256,
InMemory.FunctionalTests (6)
src\Servers\Kestrel\shared\test\CertificateAuthority.cs (6)
210var req = new CertificateRequest(subjectName, _cert.PublicKey, HashAlgorithmName.SHA256); 262HashAlgorithmName.SHA256, 347HashAlgorithmName.SHA256, 481key.SignData(tbsCertList, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1); 634HashAlgorithmName.SHA256, 823HashAlgorithmName.SHA256,
Microsoft.AspNetCore.Authentication.Certificate (1)
CertificateValidationCache.cs (1)
66=> certificate.GetCertHashString(HashAlgorithmName.SHA256);
Microsoft.AspNetCore.Authentication.Test (1)
src\Shared\test\Certificates\Certificates.cs (1)
85HashAlgorithmName.SHA256,
Microsoft.AspNetCore.Components.Endpoints (1)
Builder\ResourceCollectionUrlEndpoint.cs (1)
113var incrementalHash = IncrementalHash.CreateHash(HashAlgorithmName.SHA256);
Microsoft.AspNetCore.Cryptography.KeyDerivation (1)
PBKDF2\NetCorePbkdf2Provider.cs (1)
31algorithmName = HashAlgorithmName.SHA256;
Microsoft.AspNetCore.DeveloperCertificates.XPlat (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Microsoft.AspNetCore.DeveloperCertificates.XPlat.Tests (1)
CertificateManagerTests.cs (1)
304var csr = new CertificateRequest(httpsCertificate.Subject + "Not", privateKey, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Microsoft.AspNetCore.HttpOverrides.Tests (1)
src\Shared\test\Certificates\Certificates.cs (1)
85HashAlgorithmName.SHA256,
Microsoft.AspNetCore.Server.Kestrel.Core (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (6)
src\Servers\Kestrel\shared\test\CertificateAuthority.cs (6)
210var req = new CertificateRequest(subjectName, _cert.PublicKey, HashAlgorithmName.SHA256); 262HashAlgorithmName.SHA256, 347HashAlgorithmName.SHA256, 481key.SignData(tbsCertList, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1); 634HashAlgorithmName.SHA256, 823HashAlgorithmName.SHA256,
Microsoft.AspNetCore.Testing (1)
FakeSslCertificateFactory.cs (1)
28HashAlgorithmName.SHA256,
Microsoft.CodeAnalysis (2)
CryptographicHashProvider.cs (1)
105return HashAlgorithmName.SHA256;
Emit\EmitOptions.cs (1)
246PdbChecksumAlgorithm = pdbChecksumAlgorithm ?? HashAlgorithmName.SHA256;
Microsoft.CodeAnalysis.CSharp (1)
CommandLine\CSharpCommandLineParser.cs (1)
1528pdbChecksumAlgorithm: HashAlgorithmName.SHA256,
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (3)
CommandLineTests.cs (3)
5823Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm); 5828Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm); 5834Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm);
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (1)
Emit\DeterministicTests.cs (1)
490.WithPdbChecksumAlgorithm(HashAlgorithmName.SHA256);
Microsoft.CodeAnalysis.Test.Utilities (1)
PDB\DeterministicBuildCompilationTestHelpers.cs (1)
38pdbChecksumAlgorithm: HashAlgorithmName.SHA256,
Microsoft.CodeAnalysis.UnitTests (1)
Emit\EmitOptionsTests.cs (1)
144Assert.Equal(options2, options3.WithPdbChecksumAlgorithm(HashAlgorithmName.SHA256));
Microsoft.CodeAnalysis.VisualBasic (1)
CommandLine\VisualBasicCommandLineParser.vb (1)
1463pdbChecksumAlgorithm:=HashAlgorithmName.SHA256) ' TODO: set from /checksumalgorithm (see https://github.com/dotnet/roslyn/issues/24735)
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (3)
CommandLineTests.vb (3)
1910Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm) 1915Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm) 1920Assert.Equal(HashAlgorithmName.SHA256, parsedArgs.EmitOptions.PdbChecksumAlgorithm)
Microsoft.DotNet.Build.Tasks.Workloads (2)
Msi\MsiBase.wix.cs (1)
96protected string OutputName => $"{Utils.GetTruncatedHash(BaseOutputName, HashAlgorithmName.SHA256)}-{Platform}.msi";
Swix\MsiSwixProject.wix.cs (1)
90ProjectFile = $"{Utils.GetTruncatedHash(hashInputs, HashAlgorithmName.SHA256)}.swixproj";
Microsoft.DotNet.SignCheckLibrary (3)
Verification\ArchiveVerifier.cs (3)
40string hashedPath = String.IsNullOrEmpty(directoryName) ? Utils.GetHash(@".\", HashAlgorithmName.SHA256.Name) : 41Utils.GetHash(directoryName, HashAlgorithmName.SHA256.Name); 46Utils.GetHash(archiveEntry.FullName, HashAlgorithmName.SHA256.Name) + Path.GetExtension(archiveEntry.FullName); // lgtm [cs/zipslip] Archive from trusted source
Microsoft.Extensions.FileProviders.Physical (1)
PollingWildCardChangeToken.cs (1)
118using (var sha256 = IncrementalHash.CreateHash(HashAlgorithmName.SHA256))
System.Net.Security (1)
src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSsl.cs (1)
166var key = new SslContextCacheKey(protocols, sslAuthenticationOptions.CertificateContext?.TargetCertificate.GetCertHash(HashAlgorithmName.SHA256));
System.Security.Cryptography (27)
src\libraries\Common\src\Internal\Cryptography\PkcsHelpers.cs (1)
210if (algName == HashAlgorithmName.SHA256)
src\libraries\Common\src\System\Security\Cryptography\Asn1\Pkcs12\PfxAsn.manual.cs (1)
38hashAlgorithm = HashAlgorithmName.SHA256;
src\libraries\Common\src\System\Security\Cryptography\ECDiffieHellmanOpenSsl.Derive.cs (1)
15DeriveKeyFromHash(otherPartyPublicKey, HashAlgorithmName.SHA256, null, null);
src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (2)
282if (prf == HashAlgorithmName.SHA256) 751Oids.HmacWithSha256 => HashAlgorithmName.SHA256,
src\libraries\Common\src\System\Security\Cryptography\Pkcs12Kdf.cs (1)
24(HashAlgorithmName.SHA256, 256, 512),
System\Security\Cryptography\CapiHelper.Unix.cs (3)
43SHA256 => HashAlgorithmName.SHA256, 57Oids.Sha256 => HashAlgorithmName.SHA256, 72return HashAlgorithmName.SHA256;
System\Security\Cryptography\HashAlgorithmName.cs (1)
152value = SHA256;
System\Security\Cryptography\Helpers.cs (1)
357else if (hashAlgorithmName == HashAlgorithmName.SHA256)
System\Security\Cryptography\Rfc2898DeriveBytes.cs (1)
256hashAlgorithm != HashAlgorithmName.SHA256 &&
System\Security\Cryptography\Rfc2898DeriveBytes.OneShot.cs (7)
37/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 72/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 109/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 148/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 191/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 236/// are <see cref="HashAlgorithmName.SHA1" />, <see cref="HashAlgorithmName.SHA256" />, 327hashAlgorithmName == HashAlgorithmName.SHA256.Name ||
System\Security\Cryptography\RSAEncryptionPadding.cs (1)
26public static RSAEncryptionPadding OaepSHA256 { get; } = CreateOaep(HashAlgorithmName.SHA256);
System\Security\Cryptography\SHA256CryptoServiceProvider.cs (1)
21_incrementalHash = IncrementalHash.CreateHash(HashAlgorithmName.SHA256);
System\Security\Cryptography\X509Certificates\CertificateRequest.Load.cs (1)
327hashAlg = HashAlgorithmName.SHA256;
System\Security\Cryptography\X509Certificates\ECDsaX509SignatureGenerator.cs (1)
25if (hashAlgorithm == HashAlgorithmName.SHA256)
System\Security\Cryptography\X509Certificates\RSAPkcs1X509SignatureGenerator.cs (1)
51if (hashAlgorithm == HashAlgorithmName.SHA256)
System\Security\Cryptography\X509Certificates\RSAPssX509SignatureGenerator.cs (1)
38if (hashAlgorithm == HashAlgorithmName.SHA256)
System\Security\Cryptography\X509Certificates\X509SubjectKeyIdentifierExtension.cs (2)
190return HashSubjectPublicKeyInfo(key, HashAlgorithmName.SHA256); 196return HashSubjectPublicKeyLeft160Bits(key, HashAlgorithmName.SHA256);
System.Security.Cryptography.Cose (5)
System\Security\Cryptography\Cose\CoseHelpers.cs (2)
266KnownCoseAlgorithms.ES256 => HashAlgorithmName.SHA256, 277KnownCoseAlgorithms.PS256 or KnownCoseAlgorithms.RS256 => HashAlgorithmName.SHA256,
System\Security\Cryptography\Cose\CoseSigner.cs (3)
182nameof(HashAlgorithmName.SHA256) => KnownCoseAlgorithms.ES256, 196nameof(HashAlgorithmName.SHA256) => KnownCoseAlgorithms.PS256, 207nameof(HashAlgorithmName.SHA256) => KnownCoseAlgorithms.RS256,
System.Security.Cryptography.Pkcs (12)
Internal\Cryptography\PkcsHelpers.cs (1)
48return HashAlgorithmName.SHA256;
src\libraries\Common\src\Internal\Cryptography\PkcsHelpers.cs (1)
210if (algName == HashAlgorithmName.SHA256)
src\libraries\Common\src\System\Security\Cryptography\Asn1\Pkcs12\PfxAsn.manual.cs (1)
38hashAlgorithm = HashAlgorithmName.SHA256;
src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (2)
282if (prf == HashAlgorithmName.SHA256) 751Oids.HmacWithSha256 => HashAlgorithmName.SHA256,
src\libraries\Common\src\System\Security\Cryptography\Pkcs12Kdf.cs (1)
24(HashAlgorithmName.SHA256, 256, 512),
System\Security\Cryptography\Pkcs\CmsSignature.DSA.cs (2)
20lookup.Add(Oids.DsaWithSha256, new DSACmsSignature(Oids.DsaWithSha256, HashAlgorithmName.SHA256)); 134hashAlgorithmName == HashAlgorithmName.SHA256 ? Oids.DsaWithSha256 :
System\Security\Cryptography\Pkcs\CmsSignature.ECDsa.cs (2)
17lookup.Add(Oids.ECDsaWithSha256, new ECDsaCmsSignature(Oids.ECDsaWithSha256, HashAlgorithmName.SHA256)); 136hashAlgorithmName == HashAlgorithmName.SHA256 ? Oids.ECDsaWithSha256 :
System\Security\Cryptography\Pkcs\CmsSignature.RSA.cs (2)
20lookup.Add(Oids.RsaPkcs1Sha256, new RSAPkcs1CmsSignature(Oids.RsaPkcs1Sha256, HashAlgorithmName.SHA256)); 350else if (hashAlgorithmName == HashAlgorithmName.SHA256)
Templates.Blazor.Tests (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Templates.Blazor.WebAssembly.Auth.Tests (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Templates.Blazor.WebAssembly.Tests (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Templates.Mvc.Tests (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
Templates.Tests (3)
src\Shared\CertificateGeneration\CertificateManager.cs (3)
541keyBytes = key.ExportEncryptedPkcs8PrivateKey(password, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 100000)); 550keyBytes = key.ExportEncryptedPkcs8PrivateKey(string.Empty, new PbeParameters(PbeEncryptionAlgorithm.Aes256Cbc, HashAlgorithmName.SHA256, 1)); 780var request = new CertificateRequest(subject, key, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
WebTransportInteractiveSampleApp (1)
Program.cs (1)
183CertificateRequest req = new("CN=localhost", ec, HashAlgorithmName.SHA256);
WebTransportSampleApp (1)
Program.cs (1)
69CertificateRequest req = new("CN=localhost", ec, HashAlgorithmName.SHA256);