nomyo-js/native/index.js
alpha-nerd-nomyo c7601b2270 fix:
- AES GCM protocol mismatch
- better, granular error handling
- UUID now uses crypto.randomUUID()
- added native mlock addon to improve security
- ZeroBuffer uses explicit_bzero now
- fixed imports

feat:
-  added unit tests
2026-03-04 11:30:44 +01:00

13 lines
423 B
JavaScript

/**
* Native mlock addon entry point.
* Loaded via node-gyp-build which selects the correct pre-built binary for
* the current platform/Node.js version, or falls back to building from source.
*
* Returns null if the native addon is not available, allowing the JS layer
* to fall back to pure-JS zeroing.
*/
try {
module.exports = require('node-gyp-build')(__dirname);
} catch (_e) {
module.exports = null;
}