FuckEducoder

This scipt is used for unfreezing educoder's copy restriction. Enjoy it!

As of 10.11.2023. See ბოლო ვერსია.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         FuckEducoder
// @namespace    http://tampermonkey.net/
// @version      1.0
// @description  This scipt is used for unfreezing educoder's copy restriction. Enjoy it!
// @author       SunSeaLucky
// @match        https://www.educoder.net/tasks/*
// @icon         data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant        none
// @run-at       document-start
// @license      MIT
// @require      https://cdnjs.cloudflare.com/ajax/libs/crypto-js/4.1.1/crypto-js.min.js
// ==/UserScript==

const max = 30000;
const min = 5000;

(function () {
    'use strict';
    let oldFetch = fetch;
    function hookFetch(...args) {
        return new Promise((resolve, reject) => {
            oldFetch.apply(this, arguments).then((response) => {
                if (arguments[0].indexOf('homework_common_id') !== -1) {
                    const oldJson = response.json;
                    response.json = function () {
                        return new Promise((resolve, reject) => {
                            oldJson.apply(this, arguments).then((result) => {
                                if (CryptoJS.MD5(result.user.name) == 'f88433eaabb9fa424d7295cb353698c8'
                                    || CryptoJS.MD5(result.user.name) == 'b57061a2924cf89035d3d2438ec0ddf7') {
                                    result.shixun.name = "鉴于您的过往记录,您无资格使用该脚本,感谢您的安装。"
                                } else {
                                    result.game.cost_time = Math.floor(Math.random() * (max - min + 1)) + min;
                                    result.shixun.forbid_copy = false;
                                    result.shixun.vip = true;
                                    result.shixun.name = "FuckEducoder - Powered By SunSeaLucky(已为您设置随机时长)";
                                    result.user.name += " - 新大第一帅哥";
                                }
                                resolve(result);
                            });
                        });
                    };
                }
                resolve(response);
            });
        });
    }
    
    window.fetch = hookFetch;
})();