Skip to content

Cryptographic method cleanup - #726

Merged
poppastring merged 2 commits into
mainfrom
fix/obsolete-cryptography-apis
Jul 29, 2025
Merged

poppastring merged 2 commits into
mainfrom
fix/obsolete-cryptography-apis

Conversation

@poppastring

Copy link
Copy Markdown
Owner

PR Classification

Code cleanup and modernization of cryptographic method usage.

PR Summary

This pull request updates cryptographic method instantiations to use modern factory methods and removes redundant code.

  • Utils.cs: Replaced MD5CryptoServiceProvider with MD5.Create() in GetGravatarHash.
  • SiteSecurityManager.cs: Removed duplicate using directive and replaced SHA512Managed.Create() with SHA512.Create() and MD5CryptoServiceProvider.Create() with MD5.Create() in relevant methods.

Closes #724 #723

Replaced `SHA512Managed.Create()` with `SHA512.Create()` and
`MD5CryptoServiceProvider.Create()` with `MD5.Create()` for
better flexibility and potential security improvements.
Replaced MD5CryptoServiceProvider with MD5.Create() in the
GetGravatarHash method in Utils.cs. This change improves
compatibility and follows best practices for creating MD5
hashes.
@poppastring
poppastring merged commit da5b62f into main Jul 29, 2025
@poppastring
poppastring deleted the fix/obsolete-cryptography-apis branch November 2, 2025 23:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

'SHA512Managed' is obsolete

1 participant