sodium-native
Advanced tools
+1
-1
@@ -13,3 +13,3 @@ cmake_minimum_required(VERSION 3.25) | ||
| fetch_package("github:jedisct1/libsodium#stable" SOURCE_DIR sodium) | ||
| fetch_package("github:holepunchto/libjstl#34a7894") | ||
| fetch_package("github:holepunchto/libjstl#098664c") | ||
@@ -16,0 +16,0 @@ bare_target(target) |
+4
-3
| { | ||
| "name": "sodium-native", | ||
| "version": "5.0.9", | ||
| "version": "5.0.10", | ||
| "description": "Low level bindings for libsodium", | ||
@@ -25,6 +25,7 @@ "main": "index.js", | ||
| "cmake-napi": "^1.2.1", | ||
| "standard": "^17.1.2" | ||
| "prettier": "^3.6.2", | ||
| "prettier-config-holepunch": "^1.0.0" | ||
| }, | ||
| "scripts": { | ||
| "test": "standard && npm run test:node && npm run test:bare", | ||
| "test": "prettier . --check && npm run test:node && npm run test:bare", | ||
| "test:node": "node test/all.js", | ||
@@ -31,0 +32,0 @@ "test:bare": "bare test/all.js" |
+5
-3
@@ -20,3 +20,3 @@ # sodium-native | ||
| ``` js | ||
| ```js | ||
| var sodium = require('sodium-native') | ||
@@ -30,3 +30,3 @@ | ||
| sodium.randombytes_buf(nonce) // insert random data into nonce | ||
| sodium.randombytes_buf(key) // insert random data into key | ||
| sodium.randombytes_buf(key) // insert random data into key | ||
@@ -38,3 +38,5 @@ // encrypted message is stored in ciphertext. | ||
| var plainText = Buffer.alloc(ciphertext.length - sodium.crypto_secretbox_MACBYTES) | ||
| var plainText = Buffer.alloc( | ||
| ciphertext.length - sodium.crypto_secretbox_MACBYTES | ||
| ) | ||
@@ -41,0 +43,0 @@ if (!sodium.crypto_secretbox_open_easy(plainText, ciphertext, nonce, key)) { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
17417255
0.15%1812
44.04%54
3.85%7
16.67%