Skip to content

Instantly share code, notes, and snippets.

View ergcode's full-sized avatar

ergonomic.code ergcode

View GitHub Profile
@ergcode
ergcode / webgl-detection-bypass.js
Created March 26, 2020 16:43 — forked from nicoandmee/webgl-detection-bypass.js
[canvas-webgl-puppeteer-spoof]
() => {
function hookPrototypeMethods(prefix, object) {
// TODO: also hook getters
if (!object) return;
const originals = {};
const prototype = Object.getPrototypeOf(object);
Object
.getOwnPropertyNames(prototype)
.filter((n) => {
try {
@ergcode
ergcode / monitorExecution.js
Created March 26, 2020 16:42 — forked from nicoandmee/monitorExecution.js
inject js to examine detection strategies
const fingerprintingDetection = (function () {
const detectFingerprinting = function () {
function getCallerFile() {
let originalFunc = Error.prepareStackTrace;
let callerfile;
try {
const err = new Error();
let currentfile;
@ergcode
ergcode / clickElementHandle.js
Created March 26, 2020 16:41 — forked from nicoandmee/clickElementHandle.js
clickElementHandle - puppeteer click without bot detect
async clickElementHandle(handle, {
selector,
} = {}) {
return puppeteerErrorRetry(async () => {
if (!handle) {
this.logger.warn('clickElementHandle-empty-handle', await this.dump({
selector,
}));
return false;
}
@ergcode
ergcode / puppeteer-bot.js
Created March 26, 2020 16:39 — forked from nicoandmee/puppeteer-bot.js
disguisePage - undetectable puppeteer
const WEBGL_RENDERERS = ['ANGLE (NVIDIA Quadro 2000M Direct3D11 vs_5_0 ps_5_0)', 'ANGLE (NVIDIA Quadro K420 Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (NVIDIA Quadro 2000M Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (NVIDIA Quadro K2000M Direct3D11 vs_5_0 ps_5_0)', 'ANGLE (Intel(R) HD Graphics Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics Family Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (ATI Radeon HD 3800 Series Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics 4000 Direct3D11 vs_5_0 ps_5_0)', 'ANGLE (Intel(R) HD Graphics 4000 Direct3D11 vs_5_0 ps_5_0)', 'ANGLE (AMD Radeon R9 200 Series Direct3D11 vs_5_0 ps_5_0)', 'ANGLE (Intel(R) HD Graphics Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics Family Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics Family Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics 4000 Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Intel(R) HD Graphics 3000 Direct3D9Ex vs_3_0 ps_3_0)', 'ANGLE (Mobile Intel(R) 4 Seri