Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

winapi: Implement SecureZeroMemory() #690

Merged
merged 1 commit into from
Jan 9, 2025

Conversation

thrimbor
Copy link
Member

@thrimbor thrimbor commented Jan 9, 2025

The latest mbedtls release depends on this, and it was easy to implement.
It's basically just like a memset with zeroes or a call to ZeroMemory, but with volatile pointers to keep the compiler from optimizing it out, so it can be used for clearing memory that contained sensitive data.
On Windows this is implement in a header so the compiler can inline it, I did that as well.

@Ryzee119 Ryzee119 merged commit 92d68eb into XboxDev:master Jan 9, 2025
6 checks passed
@thrimbor thrimbor deleted the securezeromemory branch January 10, 2025 04:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants