Coder Social home page Coder Social logo

abrahamjuliot / creepjs Goto Github PK

View Code? Open in Web Editor NEW
1.3K 48.0 179.0 22.2 MB

Creepy device and browser fingerprinting

License: MIT License

JavaScript 0.24% TypeScript 97.46% HTML 2.30%
device fingerprinting browser-fingerprinting device-fingerprint security privacy-protection

creepjs's Issues

Maths

Should include custom functions

CSS todo

  • reset
  • mobile first layout (grid or flex)
  • css modal to view details
  • screen animation
  • version icons
  • timezone globe animation
  • math animation
  • error animation

destructure user agent header

https://developer.mozilla.org/en-US/docs/Web/HTTP/Browser_detection_using_the_user_agent
https://developers.whatismybrowser.com/useragents/explore/software_name/chrome
https://stackoverflow.com/questions/19877924/what-is-the-list-of-possible-values-for-navigator-platform-as-of-today

https://es6console.com/kd8cshue/

const getOS = () => {
  const userAgent = 'Mozilla/5.0 (X11; CrOS armv7l 13099.48.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.64 Safari/537.36'
  const os = (
    // order is important
    /windows phone/ig.test(userAgent) ? 'Windows Phone' :
    /win(dows|16|32|64|95|98|nt)|wow64/ig.test(userAgent) ? 'Windows' :
    /android/ig.test(userAgent) ? 'Android' :
    /cros/ig.test(userAgent) ? 'Chrome OS' :
    /linux/ig.test(userAgent) ? 'Linux' :
    /ipad/ig.test(userAgent) ? 'iPad' :
    /iphone/ig.test(userAgent) ? 'iPhone' :
    /ipod/ig.test(userAgent) ? 'iPod' :
    /ios/ig.test(userAgent) ? 'iOS' :
    /mac/ig.test(userAgent) ? 'Mac' :
    'Other'
  )
  return os
}

console.log(getOS())

Detect Brave fingerprint farbling

Tracking:
v2 https://github.com/brave/brave-browser/issues/8787
v3 https://github.com/brave/brave-browser/issues/11770

  • WebGL 1&2 Drawing: ignored
  • WebGL 1&2 Vendor and Render: ignored, with inconsistencies detected
  • WebGL 1&2 Parameters: side stepped through reduction
  • User Agent: bypassed
  • Canvas: detected with trap
  • Web Audio: detected with trap
  • Plugins: inconsistencies detected
  • Hardware Concurrency: ignored
  • Enumerate Devices: bypassed
  • Device Memory: ignored, with occasional inconsistencies detected
  • Fonts: bypassed
  • Languages: lower entropy permitted
  • Storage Quota: lower entropy permitted
  • Network Info: blocked entropy permitted
  • Keyboard: blocked entropy permitted
  • Timezone: pending implementation
  • Voices: bypassed
  • Screen: pending release

Testing at https://dev-pages.bravesoftware.com

webgl2 support

https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext

  1. Detect support
  2. If supported, get vendor and renderer
  3. Renderer must be credible
  4. webgl2/webgl vendors and renderers must match - this is currently not the case in Brave Browser and Privacy Possom
const canvas = document.createElement('canvas')
const webgl2 = canvas.getContext('webgl2')

if (webgl2) {
  const debugRendererExtension = webgl2.getExtension('WEBGL_debug_renderer_info')
  const vendor = webgl2.getParameter(debugRendererExtension.UNMASKED_VENDOR_WEBGL)
  const renderer = webgl2.getParameter(debugRendererExtension.UNMASKED_RENDERER_WEBGL)
}

detect session randomization

  1. Store the initial pure and basic fingerprint hashes in session storage
  2. If either mutates, inform the user: session randomization detected

Animate

  • visitor load (flash then step fade in)
  • initial load (fade in)
  • trash, lies, errors (wobble or bounce)
  • no lies, trash, errors (shadow effect)
  • hover (light green)

Maximize Canvas Entropy via drawImage

const getDateURI = async img => {
  const canvas = document.createElement('canvas')
  const context = canvas.getContext('2d')
  const image = new Image()
  image.crossOrigin = ''
  image.src = img
  return new Promise(resolve => {
  	image.onload = () => {
      context.drawImage(image, 0, 0)
      resolve(canvas.toDataURL())
    }
  })
}
const img = '[high quality img]'
const data = await getDateURI(img)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.