chessbot-js / chessbot

[Suspended] Chess bot as Google Chrome extension. Works with chess.com and lichess.org
http://chessbot-js.github.io/chessbot/
MIT License
10 stars 7 forks source link

Detected on chess.com #39

Closed popopxD closed 7 years ago

popopxD commented 7 years ago

Got this message: "We have detected that an extension you have installed may be violating the Fair Play policy and you will not be allowed to play until it is completely removed."

Detecting script: https://betacssjs.chesscomfiles.com/bundles/app/js/vendor/live_internal_vendors.ca06c307.js

Console.log:

["dokkeahnmkbkoijcglpddnkjeipgepcm"]
live_internal_vendors.ca06c307.js:formatted:8689chess cheat extension detected
a.(anonymous function) @ tracker.js:10
track @ live_internal_vendors.ca06c307.js:formatted:8689
i @ live_internal_vendors.ca06c307.js:formatted:1789
(anonymous) @ live_app-en_US.9f4dfd26.js:28653
(anonymous) @ live_internal_vendors.ca06c307.js:formatted:11565
n.onerror @ live_internal_vendors.ca06c307.js:formatted:11554

How did they detect ? Load: chrome-extension://extension_id/img/icon.png

n.src = "chrome-extension://" + e + "/img/icon.png",
            n.onload = function() {
                t(!0)
            }
            ,
            n.onerror = function(e) {
                t("chrome-extension://invalid/" === e.path[0].currentSrc)
            }

Differences:

Denying load of chrome-extension://dokkeahnmkbkoijcglpddnkjeipgepcm/img/icon.png. Resources must be listed in the web_accessible_resources manifest key in order to be loaded by pages outside the extension.
icon.png:1 GET chrome-extension://lohcfjmdomblangndimbjfecoapohjlb/img/icon.png net::ERR_FAILED
icon.png:1 GET chrome-extension://aobaabcegagilfeibfeifjpahgefklon/img/icon.png net::ERR_FAILED
icon.png:1 GET chrome-extension://ekllijndikebdmfpaeegkjjdpjpliahf/img/icon.png net::ERR_FAILED

Workarounds:

isChrome: function() {
            return !(!o["default"].chrome || !o["default"].chrome.webstore)
        },

Solution might be

jfkz commented 7 years ago

Thanks to your work!

jfkz commented 7 years ago

Finally, I fix it.