-
Notifications
You must be signed in to change notification settings - Fork 143
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
Secure usage of Emscripten heap #495
Merged
Merged
Commits on Jul 9, 2019
-
Provide some wrapper functions to hide all the intricacies of dealing with Emscrpten heap. We should use these functions instead of calling C directly. Note that they ensure that allocated memory is zeroed out before use as well as after use. This makes it easier to debug initialization issues, and reduces the likelyhood of sensitive data leakage through Emscripten heap.
Configuration menu - View commit details
-
Copy full SHA for a550382 - Browse repository at this point
Copy the full SHA a550382View commit details -
Use heap securely in key generation
Instead of calling malloc() and free() directly, use our new helpers to deal with passing byte arrays between JavaScript and Emscripten.
Configuration menu - View commit details
-
Copy full SHA for 03caffa - Browse repository at this point
Copy the full SHA 03caffaView commit details -
Configuration menu - View commit details
-
Copy full SHA for 22a25ca - Browse repository at this point
Copy the full SHA 22a25caView commit details -
Use heap securely in Secure Cell
Instead of calling malloc() and free() directly, use our new helpers to deal with passing byte arrays between JavaScript and Emscripten.
Configuration menu - View commit details
-
Copy full SHA for b4719ef - Browse repository at this point
Copy the full SHA b4719efView commit details -
Use heap securely in Secure Message
Instead of calling malloc() and free() directly, use our new helpers to deal with passing byte arrays between JavaScript and Emscripten.
Configuration menu - View commit details
-
Copy full SHA for 5a16bce - Browse repository at this point
Copy the full SHA 5a16bceView commit details -
Use heap securely in Secure Comparator
Instead of calling malloc() and free() directly, use our new helpers to deal with passing byte arrays between JavaScript and Emscripten.
Configuration menu - View commit details
-
Copy full SHA for 927aca7 - Browse repository at this point
Copy the full SHA 927aca7View commit details -
Use heap securely in Secure Session
Instead of calling malloc() and free() directly, use our new helpers to deal with passing byte arrays between JavaScript and Emscripten.
Configuration menu - View commit details
-
Copy full SHA for 3fb6bd7 - Browse repository at this point
Copy the full SHA 3fb6bd7View commit details
Commits on Jul 10, 2019
-
heapAlloc: if malloc() fails then do not zero out the result heapFree: make this function a no-op to allow its usage in failure paths where the pointer is null (e.g., returned by failed heapAlloc) We use a weird check "!!buffer" because JavaScript has weird ideas about what is null and what is zero. malloc() results are generally checked with "!ptr" so we invert this check.
Configuration menu - View commit details
-
Copy full SHA for f8dd4e7 - Browse repository at this point
Copy the full SHA f8dd4e7View commit details
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.