【逆向】有大佬知道new init(n).extend 这样的怎么扣吗?
新人小白。想问问有没有大佬知道,类似于new.init(n).extend 怎么继承的另一个函数。并且怎么去扣代码吗?v = k.a.stringify(z()(m)),
还有这个z()(m)到底是啥意思
逆向网站是: aHR0cDovL3d3dy55dW5jYWl0b25nLmNuL3B1Ymxpc2gvcmVzdWx0LnNodG1sLw==
加密值: headers中的token z()返回一个函数 zhuxiangyu1024 发表于 2023-6-28 11:08
z()返回一个函数
哦哦哦懂了,那大佬知道这种继承的网站扣代码的思路吗 直接调用aa() 没补环境!function(e) {
function r(data) {
for (var r, n, l = data, d = data, f = data, i = 0, h = []; i < l.length; i++)
n = l,
Object.prototype.hasOwnProperty.call(o, n) && o && h.push(o),
o = 0;
for (r in d)
Object.prototype.hasOwnProperty.call(d, r) && (e = d);
for (m && m(data); h.length; )
h.shift()();
return c.push.apply(c, f || []),
t()
}
function t() {
for (var e, i = 0; i < c.length; i++) {
for (var r = c, t = !0, n = 1; n < r.length; n++) {
var d = r;
0 !== o && (t = !1)
}
t && (c.splice(i--, 1),
e = l(l.s = r))
}
return e
}
var n = {}
, o = {
52: 0
}
, c = [];
function l(r) {
if (n)
return n.exports;
var t = n = {
i: r,
l: !1,
exports: {}
};
return e.call(t.exports, t, t.exports, l),
t.l = !0,
t.exports
}
l.e = function(e) {
var r = []
, t = o;
if (0 !== t)
if (t)
r.push(t);
else {
var n = new Promise((function(r, n) {
t = o =
}
));
r.push(t = n);
var c, script = document.createElement("script");
script.charset = "utf-8",
script.timeout = 120,
l.nc && script.setAttribute("nonce", l.nc),
script.src = function(e) {
return l.p + "" + ({
0: "commons/88ce4e44",
4: "pages/about/contact.shtml",
5: "pages/about/index.shtml",
6: "pages/about/legal.shtml",
7: "pages/about/license.shtml",
8: "pages/about/privacy.shtml",
9: "pages/about/service.shtml",
10: "pages/analysis/index",
11: "pages/eb/index",
12: "pages/ep/index",
13: "pages/index",
14: "pages/mall/index",
15: "pages/market/products",
16: "pages/market/programme",
17: "pages/market/search/history",
18: "pages/market/search/products",
19: "pages/market/search/programme",
20: "pages/market/search/supplier",
21: "pages/market/supplier",
22: "pages/news/_id",
23: "pages/news/detail/_id",
24: "pages/news/index",
25: "pages/publish/_redirect",
26: "pages/publish/_year/_month/_day/_detail",
27: "pages/publish/demand.shtml",
28: "pages/publish/index",
29: "pages/publish/result.shtml",
30: "pages/publish/result.shtml__old",
31: "pages/publish/search",
32: "pages/publish/subscribe.shtml",
33: "pages/recruit/_id",
34: "pages/recruit/index",
35: "pages/register/guidance",
36: "pages/register/index",
37: "pages/register/success/index",
38: "pages/register/uc",
39: "pages/store/_store/_product/detail",
40: "pages/store/_store/_programme/programme",
41: "pages/store/_store/case",
42: "pages/store/_store/contact",
43: "pages/store/_store/index",
44: "pages/store/_store/product",
45: "pages/store/_store/programme",
46: "pages/store/_store/qualification",
47: "pages/store/_store/searchResult",
48: "pages/survey/_id",
49: "pages/survey/index",
50: "pages/warn/detail/_id",
51: "pages/warn/index"
} || e) + "." + {
0: "f0d572c",
4: "081c068",
5: "2e5a114",
6: "5c23f06",
7: "4e0997f",
8: "46f4d38",
9: "22c79e5",
10: "060eaae",
11: "b92efc6",
12: "d9f9c27",
13: "1941c4a",
14: "a33703a",
15: "c1db378",
16: "e8cec91",
17: "f60bba8",
18: "39c9ebc",
19: "6f1ae0c",
20: "04c9d7f",
21: "84c6463",
22: "3f42973",
23: "ab736ac",
24: "74767a5",
25: "6ee3fcf",
26: "e845f75",
27: "bb561bf",
28: "7514d6b",
29: "c275486",
30: "151cde6",
31: "602793e",
32: "91f936a",
33: "06e1bcb",
34: "7f69974",
35: "961e77f",
36: "c90567b",
37: "358e56c",
38: "160d424",
39: "affc9ae",
40: "5540ffd",
41: "a9ded42",
42: "0bda335",
43: "2795e43",
44: "484eadf",
45: "cf0a9c2",
46: "ef55b18",
47: "581622b",
48: "57cfa9a",
49: "fbc9fe5",
50: "7c3a96f",
51: "538d25a"
} + ".js"
}(e);
var d = new Error;
c = function(r) {
script.onerror = script.onload = null,
clearTimeout(f);
var t = o;
if (0 !== t) {
if (t) {
var n = r && ("load" === r.type ? "missing" : r.type)
, c = r && r.target && r.target.src;
d.message = "Loading chunk " + e + " failed.\n(" + n + ": " + c + ")",
d.name = "ChunkLoadError",
d.type = n,
d.request = c,
t(d)
}
o = void 0
}
}
;
var f = setTimeout((function() {
c({
type: "timeout",
target: script
})
}
), 12e4);
script.onerror = script.onload = c,
document.head.appendChild(script)
}
return Promise.all(r)
}
,
l.m = e,
l.c = n,
l.d = function(e, r, t) {
l.o(e, r) || Object.defineProperty(e, r, {
enumerable: !0,
get: t
})
}
,
l.r = function(e) {
"undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, {
value: "Module"
}),
Object.defineProperty(e, "__esModule", {
value: !0
})
}
,
l.t = function(e, r) {
if (1 & r && (e = l(e)),
8 & r)
return e;
if (4 & r && "object" == typeof e && e && e.__esModule)
return e;
var t = Object.create(null);
if (l.r(t),
Object.defineProperty(t, "default", {
enumerable: !0,
value: e
}),
2 & r && "string" != typeof e)
for (var n in e)
l.d(t, n, function(r) {
return e
}
.bind(null, n));
return t
}
,
l.n = function(e) {
var r = e && e.__esModule ? function() {
return e.default
}
: function() {
return e
}
;
return l.d(r, "a", r),
r
}
,
l.o = function(object, e) {
return Object.prototype.hasOwnProperty.call(object, e)
}
,
l.p = "/_nuxt/",
l.oe = function(e) {
throw console.error(e),
e
}
;
var d = window.webpackJsonp = window.webpackJsonp || []
, f = d.push.bind(d);
d.push = r,
d = d.slice();
for (var i = 0; i < d.length; i++)
r(d);
var m = f;
window._nn = l;
//t()
}({
"297": function(e, t, n) {
var r;
e.exports = (r = n("331"),
function(e) {
var t = r
, n = t.lib
, o = n.WordArray
, c = n.Hasher
, l = t.algo
, d = []
, h = [];
!function() {
function t(t) {
for (var n = e.sqrt(t), r = 2; r <= n; r++)
if (!(t % r))
return !1;
return !0
}
function n(e) {
return 4294967296 * (e - (0 | e)) | 0
}
for (var r = 2, o = 0; o < 64; )
t(r) && (o < 8 && (d = n(e.pow(r, .5))),
h = n(e.pow(r, 1 / 3)),
o++),
r++
}();
var f = []
, m = l.SHA256 = c.extend({
_doReset: function() {
this._hash = new o.init(d.slice(0))
},
_doProcessBlock: function(e, t) {
for (var n = this._hash.words, a = n, b = n, r = n, o = n, c = n, l = n, g = n, d = n, i = 0; i < 64; i++) {
if (i < 16)
f = 0 | e;
else {
var m = f
, v = (m << 25 | m >>> 7) ^ (m << 14 | m >>> 18) ^ m >>> 3
, _ = f
, y = (_ << 15 | _ >>> 17) ^ (_ << 13 | _ >>> 19) ^ _ >>> 10;
f = v + f + y + f
}
var M = a & b ^ a & r ^ b & r
, w = (a << 30 | a >>> 2) ^ (a << 19 | a >>> 13) ^ (a << 10 | a >>> 22)
, L = d + ((c << 26 | c >>> 6) ^ (c << 21 | c >>> 11) ^ (c << 7 | c >>> 25)) + (c & l ^ ~c & g) + h + f;
d = g,
g = l,
l = c,
c = o + L | 0,
o = r,
r = b,
b = a,
a = L + (w + M) | 0
}
n = n + a | 0,
n = n + b | 0,
n = n + r | 0,
n = n + o | 0,
n = n + c | 0,
n = n + l | 0,
n = n + g | 0,
n = n + d | 0
},
_doFinalize: function() {
var data = this._data
, t = data.words
, n = 8 * this._nDataBytes
, r = 8 * data.sigBytes;
return t |= 128 << 24 - r % 32,
t = e.floor(n / 4294967296),
t = n,
data.sigBytes = 4 * t.length,
this._process(),
this._hash
},
clone: function() {
var e = c.clone.call(this);
return e._hash = this._hash.clone(),
e
}
});
t.SHA256 = c._createHelper(m),
t.HmacSHA256 = c._createHmacHelper(m)
}(Math),
r.SHA256)
},
"331":function(e, t, n) {
(function(t) {
var r;
e.exports = (r = r || function(e, r) {
var o;
if ("undefined" != typeof window && window.crypto && (o = window.crypto),
"undefined" != typeof self && self.crypto && (o = self.crypto),
"undefined" != typeof globalThis && globalThis.crypto && (o = globalThis.crypto),
!o && "undefined" != typeof window && window.msCrypto && (o = window.msCrypto),
!o && void 0 !== t && t.crypto && (o = t.crypto),
!o)
try {
o = n("625")
} catch (e) {}
var c = function() {
if (o) {
if ("function" == typeof o.getRandomValues)
try {
return o.getRandomValues(new Uint32Array(1))
} catch (e) {}
if ("function" == typeof o.randomBytes)
try {
return o.randomBytes(4).readInt32LE()
} catch (e) {}
}
throw new Error("Native crypto module could not be used to get secure random number.")
}
, l = Object.create || function() {
function e() {}
return function(t) {
var n;
return e.prototype = t,
n = new e,
e.prototype = null,
n
}
}()
, d = {}
, h = d.lib = {}
, f = h.Base = {
extend: function(e) {
var t = l(this);
return e && t.mixIn(e),
t.hasOwnProperty("init") && this.init !== t.init || (t.init = function() {
t.$super.init.apply(this, arguments)
}
),
t.init.prototype = t,
t.$super = this,
t
},
create: function() {
var e = this.extend();
return e.init.apply(e, arguments),
e
},
init: function() {},
mixIn: function(e) {
for (var t in e)
e.hasOwnProperty(t) && (this = e);
e.hasOwnProperty("toString") && (this.toString = e.toString)
},
clone: function() {
return this.init.prototype.extend(this)
}
}
, m = h.WordArray = f.extend({
init: function(e, t) {
e = this.words = e || [],
this.sigBytes = null != t ? t : 4 * e.length
},
toString: function(e) {
return (e || _).stringify(this)
},
concat: function(e) {
var t = this.words
, n = e.words
, r = this.sigBytes
, o = e.sigBytes;
if (this.clamp(),
r % 4)
for (var i = 0; i < o; i++) {
var c = n >>> 24 - i % 4 * 8 & 255;
t |= c << 24 - (r + i) % 4 * 8
}
else
for (var l = 0; l < o; l += 4)
t = n;
return this.sigBytes += o,
this
},
clamp: function() {
var t = this.words
, n = this.sigBytes;
t &= 4294967295 << 32 - n % 4 * 8,
t.length = e.ceil(n / 4)
},
clone: function() {
var e = f.clone.call(this);
return e.words = this.words.slice(0),
e
},
random: function(e) {
for (var t = [], i = 0; i < e; i += 4)
t.push(c());
return new m.init(t,e)
}
})
, v = d.enc = {}
, _ = v.Hex = {
stringify: function(e) {
for (var t = e.words, n = e.sigBytes, r = [], i = 0; i < n; i++) {
var o = t >>> 24 - i % 4 * 8 & 255;
r.push((o >>> 4).toString(16)),
r.push((15 & o).toString(16))
}
return r.join("")
},
parse: function(e) {
for (var t = e.length, n = [], i = 0; i < t; i += 2)
n |= parseInt(e.substr(i, 2), 16) << 24 - i % 8 * 4;
return new m.init(n,t / 2)
}
}
, y = v.Latin1 = {
stringify: function(e) {
for (var t = e.words, n = e.sigBytes, r = [], i = 0; i < n; i++) {
var o = t >>> 24 - i % 4 * 8 & 255;
r.push(String.fromCharCode(o))
}
return r.join("")
},
parse: function(e) {
for (var t = e.length, n = [], i = 0; i < t; i++)
n |= (255 & e.charCodeAt(i)) << 24 - i % 4 * 8;
return new m.init(n,t)
}
}
, M = v.Utf8 = {
stringify: function(e) {
try {
return decodeURIComponent(escape(y.stringify(e)))
} catch (e) {
throw new Error("Malformed UTF-8 data")
}
},
parse: function(e) {
return y.parse(unescape(encodeURIComponent(e)))
}
}
, w = h.BufferedBlockAlgorithm = f.extend({
reset: function() {
this._data = new m.init,
this._nDataBytes = 0
},
_append: function(data) {
"string" == typeof data && (data = M.parse(data)),
this._data.concat(data),
this._nDataBytes += data.sigBytes
},
_process: function(t) {
var n, data = this._data, r = data.words, o = data.sigBytes, c = this.blockSize, l = o / (4 * c), d = (l = t ? e.ceil(l) : e.max((0 | l) - this._minBufferSize, 0)) * c, h = e.min(4 * d, o);
if (d) {
for (var f = 0; f < d; f += c)
this._doProcessBlock(r, f);
n = r.splice(0, d),
data.sigBytes -= h
}
return new m.init(n,h)
},
clone: function() {
var e = f.clone.call(this);
return e._data = this._data.clone(),
e
},
_minBufferSize: 0
})
, L = (h.Hasher = w.extend({
cfg: f.extend(),
init: function(e) {
this.cfg = this.cfg.extend(e),
this.reset()
},
reset: function() {
w.reset.call(this),
this._doReset()
},
update: function(e) {
return this._append(e),
this._process(),
this
},
finalize: function(e) {
return e && this._append(e),
this._doFinalize()
},
blockSize: 16,
_createHelper: function(e) {
return function(t, n) {
return new e.init(n).finalize(t)
}
},
_createHmacHelper: function(e) {
return function(t, n) {
return new L.HMAC.init(e,n).finalize(t)
}
}
}),
d.algo = {});
return d
}(Math),
r)
}
).call(this, n("69"))
},
"69": function(t, e) {
var g;
g = function() {
return this
}();
try {
g = g || new Function("return this")()
} catch (t) {
"object" == typeof window && (g = window)
}
t.exports = g
},
"625":function(e, t) {}
});
function aa(){
var aaa = window._nn("297");
var z = window._nn.n(aaa);
const y = [];
for (let i = 0; i < 256; ++i)
y.push((i + 256).toString(16).slice(1));
function M(e, t=0) {
return (y] + y] + y] + y] + "-" + y] + y] + "-" + y] + y] + "-" + y] + y] + "-" + y] + y] + y] + y] + y] + y]).toLowerCase()
};
function _stringify(e) {
for (var t = e.words, n = e.sigBytes, r = [], i = 0; i < n; i++) {
var o = t >>> 24 - i % 4 * 8 & 255;
r.push((o >>> 4).toString(16)),
r.push((15 & o).toString(16))
}
return r.join("")
};
var f = {
randomUUID: "undefined" != typeof crypto && crypto.randomUUID && crypto.randomUUID.bind(crypto)
};
var w = function(e, t, n) {
if (f.randomUUID && !t && !e)
return f.randomUUID();
const r = (e = e || {}).random || (e.rng || _)();
if (r = 15 & r | 64,
r = 63 & r | 128,
t) {
n = n || 0;
for (let i = 0; i < 16; ++i)
t = r;
return t
}
return M(r)
};
var f = w().replaceAll("-", ""),
l = Math.floor(Date.now() / 1e3),
m = f.slice(2, 11),
v = _stringify(z()(m)),
pre = v.slice(0, 10),
_ = v.slice(10, 32),
yy = _stringify(z()(l + f + m));
return pre + yy + _
} v = k.a.stringify(z()(m)),
z() 表示调用函数 z,它返回另一个函数作为结果。
z() 返回的函数之后立即被调用,并传入参数 m。因此,z()(m) 是对返回的函数进行调用,并将 m 作为参数传递进去。
这种函数链式调用或者多次函数调用。通过将函数调用链接在一起,可以实现更复杂的功能组合或者链式操作。
z()(m) 表示先调用函数 z,然后将 m 作为参数传递给返回的函数进行调用。该表达式的结果将作为参数传递给函数 stringify,进一步被 k.a.stringify 使用
之于你说的“new.init(n).extend 怎么继承的另一个函数”
定义一个新的类,并让它继承自你想要继承函数的那个类。例如,如果你想要继承的函数来自类 A,你可以创建一个新类 B 并让其继承自类 A。
class B(A):
pass
在新类 B 中,定义你想要添加的函数,并确保使用相同的函数名。你可以在新函数中调用父类的函数,以便重用原始函数的功能
class B(A):
def extend(self, n):
# 在这里添加你想要执行的额外代码
super().extend(n)# 调用父类 A 中的 extend 函数
注意,super() 函数用于调用父类的方法
现在,类 B 已经继承了类 A 中的函数,并添加了新的功能。你可以实例化类 B 的对象,并调用继承的函数及新定义的函数
b = B()
通过这种方式,你可以继承类中的函数,并在新类中添加额外的功能或修改原始函数的行为
b.extend(n)# 调用继承的函数 extend
Miami 发表于 2023-6-28 12:54
直接调用aa() 没补环境!function(e) {
function r(data) {
...
强啊 大佬 law.liu 发表于 2023-6-28 13:25
v = k.a.stringify(z()(m)),
z() 表示调用函数 z,它返回另一个函数作为结果。
讲的很细,这个懂了,但是大佬 那个 代码是webpack脱出来的吗 law.liu 发表于 2023-6-28 13:27
之于你说的“new.init(n).extend 怎么继承的另一个函数”
定义一个新的类,并让它继承自你想要继承函数的 ...
NB 大佬 我搞出来了,您能告诉我 这个JS怎么弄出来的吗?
// 定义基础函数 Base
function Base() {
// 基础函数的逻辑
}
// 在 Base 的原型上添加 anotherMethod 方法
Base.prototype.anotherMethod = function() {
console.log("Another method called");
// 另一个方法的具体实现逻辑
};
// 定义 Init 函数,接收参数 n
function Init(n) {
this.n = n;
}
// 将 Init 的原型设置为 Base 的实例,实现原型继承
Init.prototype = Object.create(Base.prototype);
Init.prototype.constructor = Init;
// 在 Init 的原型上添加 extend 方法
Init.prototype.extend = function() {
console.log("Extend method called");
// extend 方法的具体实现逻辑
};
// 创建 Init 的实例 obj
const obj = new Init(5);
// 调用 extend 方法和继承自 Base 的 anotherMethod 方法
obj.extend();
obj.anotherMethod();
首先定义了 Base 和 Init 两个函数,并分别为它们的原型添加了方法。然后,我们通过创建 Init 的实例 obj,可以调用 extend 方法和继承自 Base 的 anotherMethod 方法。
你可以将上述代码保存为一个 JavaScript 文件,例如ABC.JS,在Node.js 环境下运行以下代码
页:
[1]
2