Add post-quantum cryptography support with PqSoftCryptoProvider
Some checks failed
AOC Guard CI / aoc-guard (push) Has been cancelled
AOC Guard CI / aoc-verify (push) Has been cancelled
Concelier Attestation Tests / attestation-tests (push) Has been cancelled
Docs CI / lint-and-preview (push) Has been cancelled
Policy Lint & Smoke / policy-lint (push) Has been cancelled
Scanner Analyzers / Discover Analyzers (push) Has been cancelled
Scanner Analyzers / Build Analyzers (push) Has been cancelled
Scanner Analyzers / Test Language Analyzers (push) Has been cancelled
Scanner Analyzers / Validate Test Fixtures (push) Has been cancelled
Scanner Analyzers / Verify Deterministic Output (push) Has been cancelled
wine-csp-build / Build Wine CSP Image (push) Has been cancelled
Some checks failed
AOC Guard CI / aoc-guard (push) Has been cancelled
AOC Guard CI / aoc-verify (push) Has been cancelled
Concelier Attestation Tests / attestation-tests (push) Has been cancelled
Docs CI / lint-and-preview (push) Has been cancelled
Policy Lint & Smoke / policy-lint (push) Has been cancelled
Scanner Analyzers / Discover Analyzers (push) Has been cancelled
Scanner Analyzers / Build Analyzers (push) Has been cancelled
Scanner Analyzers / Test Language Analyzers (push) Has been cancelled
Scanner Analyzers / Validate Test Fixtures (push) Has been cancelled
Scanner Analyzers / Verify Deterministic Output (push) Has been cancelled
wine-csp-build / Build Wine CSP Image (push) Has been cancelled
- Implemented PqSoftCryptoProvider for software-only post-quantum algorithms (Dilithium3, Falcon512) using BouncyCastle. - Added PqSoftProviderOptions and PqSoftKeyOptions for configuration. - Created unit tests for Dilithium3 and Falcon512 signing and verification. - Introduced EcdsaPolicyCryptoProvider for compliance profiles (FIPS/eIDAS) with explicit allow-lists. - Added KcmvpHashOnlyProvider for KCMVP baseline compliance. - Updated project files and dependencies for new libraries and testing frameworks.
This commit is contained in:
@@ -147,7 +147,7 @@ internal static class PythonContainerAdapter
|
||||
|
||||
foreach (var sitePackages in DiscoverLayerSitePackages(rootPath))
|
||||
{
|
||||
foreach (var distInfo in EnumerateDistInfoDirectories(sitePackages))
|
||||
foreach (var distInfo in EnumerateMetadataDirectories(sitePackages))
|
||||
{
|
||||
discovered.Add(distInfo);
|
||||
}
|
||||
@@ -156,7 +156,7 @@ internal static class PythonContainerAdapter
|
||||
// Also check root-level site-packages
|
||||
foreach (var sitePackages in DiscoverSitePackagesInDirectory(rootPath))
|
||||
{
|
||||
foreach (var distInfo in EnumerateDistInfoDirectories(sitePackages))
|
||||
foreach (var distInfo in EnumerateMetadataDirectories(sitePackages))
|
||||
{
|
||||
discovered.Add(distInfo);
|
||||
}
|
||||
@@ -167,30 +167,33 @@ internal static class PythonContainerAdapter
|
||||
.ToArray();
|
||||
}
|
||||
|
||||
private static IEnumerable<string> EnumerateDistInfoDirectories(string sitePackages)
|
||||
private static IEnumerable<string> EnumerateMetadataDirectories(string sitePackages)
|
||||
{
|
||||
if (!Directory.Exists(sitePackages))
|
||||
{
|
||||
yield break;
|
||||
}
|
||||
|
||||
IEnumerable<string>? directories = null;
|
||||
try
|
||||
foreach (var pattern in new[] { "*.dist-info", "*.egg-info" })
|
||||
{
|
||||
directories = Directory.EnumerateDirectories(sitePackages, "*.dist-info");
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
yield break;
|
||||
}
|
||||
catch (UnauthorizedAccessException)
|
||||
{
|
||||
yield break;
|
||||
}
|
||||
IEnumerable<string>? directories = null;
|
||||
try
|
||||
{
|
||||
directories = Directory.EnumerateDirectories(sitePackages, pattern);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
catch (UnauthorizedAccessException)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
foreach (var directory in directories)
|
||||
{
|
||||
yield return directory;
|
||||
foreach (var directory in directories)
|
||||
{
|
||||
yield return directory;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -291,22 +291,8 @@ public sealed class PythonLanguageAnalyzer : ILanguageAnalyzer
|
||||
{
|
||||
var directories = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
// Collect from root path recursively
|
||||
try
|
||||
{
|
||||
foreach (var dir in Directory.EnumerateDirectories(rootPath, "*.dist-info", Enumeration))
|
||||
{
|
||||
directories.Add(dir);
|
||||
}
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Ignore enumeration errors
|
||||
}
|
||||
catch (UnauthorizedAccessException)
|
||||
{
|
||||
// Ignore access errors
|
||||
}
|
||||
AddMetadataDirectories(rootPath, "*.dist-info", directories);
|
||||
AddMetadataDirectories(rootPath, "*.egg-info", directories);
|
||||
|
||||
// Also collect from OCI container layers
|
||||
foreach (var dir in PythonContainerAdapter.DiscoverDistInfoDirectories(rootPath))
|
||||
@@ -317,5 +303,24 @@ public sealed class PythonLanguageAnalyzer : ILanguageAnalyzer
|
||||
return directories
|
||||
.OrderBy(static path => path, StringComparer.Ordinal)
|
||||
.ToArray();
|
||||
|
||||
static void AddMetadataDirectories(string basePath, string pattern, ISet<string> accumulator)
|
||||
{
|
||||
try
|
||||
{
|
||||
foreach (var dir in Directory.EnumerateDirectories(basePath, pattern, Enumeration))
|
||||
{
|
||||
accumulator.Add(dir);
|
||||
}
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Ignore enumeration errors
|
||||
}
|
||||
catch (UnauthorizedAccessException)
|
||||
{
|
||||
// Ignore access errors
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user