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

slider-puzzle-captcha

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

slider-puzzle-captcha

drag puzzle to validate captcha

  • 0.1.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

slider puzzle validator

drag puzzle for captcha validation

usage

clone it, and run

npm start

then open 127.0.0.1:3000

use client by browserify or webpack

import sliderPuzzle from 'slider-puzzle-captcha'

let div = document.querySelector('.slider-puzzle')
let removeSliderHandler = sliderPuzzle(div)
// when no need, remove listeners from div
// sliderPuzzle.destroy()

test

npm test
npm run test:client

dist

npm run build:commonjs

server

use pm2 to start src/server/index.js do not forget change src/config.js allowIps to include your request server ip

npm i pm2 -g // if no pm2 in global
npm run production

custom

edit src/config.js and run

npm run dist

api

when server is running, api can be accessed api can be customized by edit config.js

get /captcha return Object {bg: String, puzzle-bg: String, puzzle: String, token: String, ok: Bool}

post /validate post body {token: String, x: Number} return Object {ok: Bool}

Keywords

FAQs

Package last updated on 21 Jul 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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