Skip to content

Issue running stealth_extension #1081

@jackiecan

Description

@jackiecan

Hi,

I'm currently working on setting up the Stealth Extension by @bkrumnow on a freshly installed Ubuntu 18.04 system by running the stealth_extension branch. However, I'm encountering errors when npm ci is run in /scripts/build-extension.sh
The following error messages appearing regarding the instrument.ts and stealth.ts files during the execution of the > build:main command (see below)

Full console Log and Debug log of run of install.sh: console_log_install.txt, 2024-01-10T09_47_20_547Z-debug-0.log

Based on the information from Pull Request #1037, it appears that the extension might not be stable at the moment? I'm wondering if you have any insights into why these errors are occurring and if there are any steps I can take to successfully use the extension.

I appreciate your assistance in advance! Thanks for maintaining the tool!

Best Regards :)

ERROR:

src/stealth/instrument.ts:259:47 - error TS2339: Property 'logFunctionsAsStrings' does not exist on type '{ object: string; instrumentedName: string; depth: number; logSettings: { propertiesToInstrument: any[]; nonExistingPropertiesToInstrument: any[]; excludedProperties: string[]; overwrittenProperties: any[]; ... 5 more ...; depth: number; }; } | { ...; } | { ...; } | { ...; }'.
  Property 'logFunctionsAsStrings' does not exist on type '{ object: string; instrumentedName: string; depth: number; logSettings: { propertiesToInstrument: any[]; nonExistingPropertiesToInstrument: any[]; excludedProperties: string[]; overwrittenProperties: any[]; ... 5 more ...; depth: number; }; }'.

259     value: serializeObject(value, logSettings.logFunctionsAsStrings),
                                                  ~~~~~~~~~~~~~~~~~~~~~

#### some more errors

src/stealth/stealth.ts:86:24 - error TS2345: Argument of type '{ context: any; wrappedWindow: any; changeWindowProperty: (object: any, name: any, type: any, changed: any) => void; singleCallback: any; allCallback: any; }' is not assignable to parameter of type '{ context: any; wrappedWindow: any; changeWindowProperty: any; observe: any; allCallback: any; }'.
  Property 'observe' is missing in type '{ context: any; wrappedWindow: any; changeWindowProperty: (object: any, name: any, type: any, changed: any) => void; singleCallback: any; allCallback: any; }' but required in type '{ context: any; wrappedWindow: any; changeWindowProperty: any; observe: any; allCallback: any; }'.

86   protectDocumentWrite(api);
                          ~~~

#### some more errors

Errors  Files
    11  src/stealth/instrument.ts:259
     8  src/stealth/stealth.ts:56
npm verb exit 2
npm verb code 2
npm verb exit 2
npm verb code 2
npm verb stack Error: command failed
npm verb stack     at ChildProcess.<anonymous> (/home/vagrant/miniforge3/envs/openwpm/lib/node_modules/npm/node_modules/@npmcli/promise-spawn/lib/index.js:53:27)
npm verb stack     at ChildProcess.emit (node:events:514:28)
npm verb stack     at maybeClose (node:internal/child_process:1105:16)
npm verb stack     at ChildProcess._handle.onexit (node:internal/child_process:305:5)
npm verb cwd /home/vagrant/openwpm/OpenWPM/Extension
npm verb Linux 5.4.0-169-generic
npm verb node v20.6.1
npm verb npm  v9.8.1
npm ERR! code 2
npm ERR! path /home/vagrant/openwpm/OpenWPM/Extension
npm ERR! command failed
npm ERR! command sh -c npm run build && npm run test
npm verb exit 2
npm verb code 2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions