Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

puppeteer-extra-plugin-stealth

Package Overview
Dependencies
Maintainers
1
Versions
69
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

puppeteer-extra-plugin-stealth - npm Package Compare versions

Comparing version 2.0.1 to 2.0.2

index.test.js

2

evasions/_template/readme.md

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/_template/index.js#L10-L20)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/_template/index.js#L10-L20)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/chrome.runtime/index.js#L10-L22)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/chrome.runtime/index.js#L10-L22)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/console.debug/index.js#L8-L18)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/console.debug/index.js#L8-L18)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/iframe.contentWindow/index.js#L8-L23)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/iframe.contentWindow/index.js#L8-L23)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/navigator.languages/index.js#L8-L21)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/navigator.languages/index.js#L8-L21)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/navigator.permissions/index.js#L8-L46)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/navigator.permissions/index.js#L8-L46)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/navigator.plugins/index.js#L8-L23)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/navigator.plugins/index.js#L8-L23)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/navigator.webdriver/index.js#L8-L20)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/navigator.webdriver/index.js#L8-L20)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -9,3 +9,3 @@ ## API

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/evasions/user-agent/index.js#L13-L19)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/evasions/user-agent/index.js#L13-L19)

@@ -12,0 +12,0 @@ **Extends: PuppeteerExtraPlugin**

@@ -76,6 +76,8 @@ 'use strict'

class Plugin extends PuppeteerExtraPlugin {
constructor (opts = { }) {
super(opts)
constructor (opts = { }) { super(opts) }
this._availableEvasions = new Set([
get name () { return 'stealth' }
get defaults () {
const availableEvasions = new Set([
'chrome.runtime',

@@ -90,13 +92,9 @@ 'console.debug',

])
const defaults = {
return {
availableEvasions,
// Enable all available evasions by default
enabledEvasions: new Set(this._availableEvasions)
enabledEvasions: new Set([...availableEvasions])
}
this._opts = Object.assign(defaults, opts)
}
get name () { return 'stealth' }
/**

@@ -108,3 +106,3 @@ * Requires evasion techniques dynamically based on configuration.

get dependencies () {
return new Set([...this._opts.enabledEvasions]
return new Set([...this.opts.enabledEvasions]
.map(e => `${this.name}/evasions/${e}`)

@@ -126,3 +124,3 @@ )

*/
get availableEvasions () { return this._availableEvasions }
get availableEvasions () { return this.defaults.availableEvasions }

@@ -142,3 +140,3 @@ /**

*/
get enabledEvasions () { return this._opts.enabledEvasions }
get enabledEvasions () { return this.opts.enabledEvasions }

@@ -148,5 +146,5 @@ /**

*/
set enabledEvasions (evasions) { this._opts.enabledEvasions = evasions }
set enabledEvasions (evasions) { this.opts.enabledEvasions = evasions }
}
module.exports = function (pluginConfig) { return new Plugin(pluginConfig) }
{
"name": "puppeteer-extra-plugin-stealth",
"version": "2.0.1",
"version": "2.0.2",
"description": "Stealth mode: Applies various techniques to make detection of headless puppeteer harder.",

@@ -12,3 +12,3 @@ "main": "index.js",

"docs-for-evasions": "cd ./evasions && loop update-markdown-jsdoc",
"test": "standard"
"test": "ava -v && standard"
},

@@ -15,0 +15,0 @@ "engines": {

@@ -26,3 +26,3 @@ # puppeteer-extra-plugin-stealth

### [Plugin](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/index.js#L75-L144)
### [Plugin](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/index.js#L75-L142)

@@ -107,3 +107,3 @@ **Extends: PuppeteerExtraPlugin**

#### [availableEvasions](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/index.js#L123-L123)
#### [availableEvasions](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/index.js#L121-L121)

@@ -126,3 +126,3 @@ Get all available evasions.

#### [enabledEvasions](https://github.com/berstend/puppeteer-extra/blob/39bb3948016ab4afc7e6f31459828035c8e8c65c/packages/puppeteer-extra-plugin-stealth/index.js#L138-L138)
#### [enabledEvasions](https://github.com/berstend/puppeteer-extra/blob/139d9ecf97a46dc383adede213e1a4c707160dca/packages/puppeteer-extra-plugin-stealth/index.js#L136-L136)

@@ -129,0 +129,0 @@ Get all enabled evasions.

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc