@gabrielmaialva33/discord-video-stream
Advanced tools
Comparing version 0.6.4 to 0.6.5
@@ -1,2 +0,2 @@ | ||
import { crypto_secretbox_easy } from 'libsodium-wrappers'; | ||
import * as libsodium from 'libsodium-wrappers'; | ||
export const MAX_INT16BIT = 2 ** 16; | ||
@@ -129,3 +129,3 @@ export const MAX_INT32BIT = 2 ** 32; | ||
packetHeader, | ||
crypto_secretbox_easy(senderReport, nonceBuffer, this._mediaUdp.mediaConnection.secretkey), | ||
libsodium.crypto_secretbox_easy(senderReport, nonceBuffer, this._mediaUdp.mediaConnection.secretkey), | ||
nonceBuffer.subarray(0, 4), | ||
@@ -181,4 +181,4 @@ ]); | ||
encryptData(message, nonceBuffer) { | ||
return crypto_secretbox_easy(message, nonceBuffer, this._mediaUdp.mediaConnection.secretkey); | ||
return libsodium.crypto_secretbox_easy(message, nonceBuffer, this._mediaUdp.mediaConnection.secretkey); | ||
} | ||
} |
{ | ||
"name": "@gabrielmaialva33/discord-video-stream", | ||
"version": "0.6.4", | ||
"version": "0.6.5", | ||
"description": "Experiment for making video streaming work for discord self bots", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -1,2 +0,2 @@ | ||
import { crypto_secretbox_easy } from 'libsodium-wrappers' | ||
import * as libsodium from 'libsodium-wrappers' | ||
@@ -166,3 +166,7 @@ import { MediaUdp } from '#src/client/voice/media_udp' | ||
packetHeader, | ||
crypto_secretbox_easy(senderReport, nonceBuffer, this._mediaUdp.mediaConnection.secretkey), | ||
libsodium.crypto_secretbox_easy( | ||
senderReport, | ||
nonceBuffer, | ||
this._mediaUdp.mediaConnection.secretkey | ||
), | ||
nonceBuffer.subarray(0, 4), | ||
@@ -226,4 +230,8 @@ ]) | ||
encryptData(message: string | Uint8Array, nonceBuffer: Buffer): Uint8Array { | ||
return crypto_secretbox_easy(message, nonceBuffer, this._mediaUdp.mediaConnection.secretkey) | ||
return libsodium.crypto_secretbox_easy( | ||
message, | ||
nonceBuffer, | ||
this._mediaUdp.mediaConnection.secretkey | ||
) | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
154686
4132