Repository navigation
Bouncy Castle cryptography: .NET 10, OAEP, 2048-bit DSA, derived Blowfish key - #2273
Merged
vladimir-pecanac-main merged 2 commits intoOct 9, 2026
Conversation
…fish key - Retarget both projects to net10.0; BouncyCastle.Cryptography 2.3.1 to 2.7.0; Microsoft.NET.Test.Sdk 18.10.1, coverlet.collector 10.1.0, MSTest 4.5.1. - RSA: Pkcs1Encoding to OaepEncoding over SHA-256. - DSA: 2048-bit parameters through DsaParameterGenerationParameters (the Init(size, certainty) overload stops at 1024 bits). - Blowfish: derive the key from the password with PBKDF2 (HMAC-SHA256, random salt) instead of using the password bytes as the key; static class, file-scoped namespace, redundant usings removed. - Program.cs: hash the article's input string and print the DSA signature instead of the Blowfish ciphertext. - Tests: fix the "pasword" typo, add MD5 and SHA-256 known-answer tests, discard unused out values.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updates the sample for the Code Maze article "Bouncy Castle Cryptography in C# and .NET" (https://code-maze.com/csharp-bouncy-castle-cryptography/). Only authorization-dotnet/BouncyCastleCryptography changes.
Packages (re-queried on NuGet 2026-10-09; the re-query wins over the batch block):
Code:
Local run (SDK 10.0.302, runtime 10.0.10): build 0 warnings 0 errors, 12 of 12 tests passed, dotnet list package --vulnerable --include-transitive clean on both projects.