deepwn / deepMiner

deepMiner webminer proxy (update for cryptoNight R)
Other
549 stars 237 forks source link

Review: npm start demo `_verifyThread` never fires & `_useWASM` not working #83

Closed lacvapps closed 5 years ago

lacvapps commented 5 years ago

Describe the bug If you open the miner.html, ready will never fire. The test job will never run.

To Reproduce Steps to reproduce the behavior: line 187 of deepMiner.js 'this._verifyThread.verify' will never fire callback because 'ready' message is never posted

Expected behavior post message ready

Desktop (please complete the following information): Ubuntu 18.04

lacvapps commented 5 years ago

forcing _useWASM to false allows the program to work.

evil7 commented 5 years ago

Hi @lacvapps ! There are some wrong dude. So I think you should know this:

  1. The this._verifyThread.verify is a job only for coinhive. Used to do like reCAPTCHA verify. That's a hashCAPTCHA verify function. Coinhive sending a verify not a job to do this. And the selfTest is the real test for check if can the miner working. I think you have reviewing with a wrong function. This "miner hashing version verify" is selfTest but not _verify.
  2. I have not building with ASMJS module because it's to slow to do hashing at ASMJS. At this time it's 25H/s under WASM but ASMJS is half of WASM. See how slow it is? and that's why we should not use this ASMJS module.
  3. The full API and document come from Coinhive because the worker.js was dumping for Coinhive's miner at first. Some this unused API list in document. Yes but I have no time to nullify them and delete in document and the worker.js. I think it will fix when I rebuild all into Service Worker.
  4. You can read the Testing Notes in README.md and test speed of it by youself. You will know why coinhive quit and why I marked this for leanning at temporary.

But at all thanks for review this project bro.