@vita-mojo/aggregator 1.10.0 → 1.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/main.js.enc +0 -0
- package/main.js.map.enc +0 -0
- package/package.json +1 -1
- package/postinstall.js +2 -4
package/main.js.enc
CHANGED
|
Binary file
|
package/main.js.map.enc
CHANGED
|
Binary file
|
package/package.json
CHANGED
package/postinstall.js
CHANGED
|
@@ -9,9 +9,7 @@ const crypto = require('crypto');
|
|
|
9
9
|
* Load environment variables from .env file
|
|
10
10
|
*/
|
|
11
11
|
function loadEnvFile() {
|
|
12
|
-
|
|
13
|
-
const repoRoot = path.resolve(__dirname, '../../../..');
|
|
14
|
-
const envFilePath = path.join(repoRoot, '.env');
|
|
12
|
+
const envFilePath = path.resolve(process.env.INIT_CWD, '.env');
|
|
15
13
|
|
|
16
14
|
if (!fs.existsSync(envFilePath)) {
|
|
17
15
|
console.log('ℹ No .env file found in repo root');
|
|
@@ -79,7 +77,7 @@ function decryptFiles() {
|
|
|
79
77
|
}
|
|
80
78
|
|
|
81
79
|
// Shared secret must be 32 bytes (256 bits) for AES-256
|
|
82
|
-
const sharedSecret = Buffer.from(sharedSecretEnv, '
|
|
80
|
+
const sharedSecret = Buffer.from(sharedSecretEnv, 'utf8');
|
|
83
81
|
if (sharedSecret.length !== 32) {
|
|
84
82
|
throw new Error(`AGGREGATOR_ENCRYPTION_KEY must be 32 bytes (256 bits), got ${sharedSecret.length} bytes`);
|
|
85
83
|
}
|