anti_content获取成功!
This commit is contained in:
@@ -5,29 +5,18 @@ import {genAnti} from "@/api/genAnti";
|
||||
* 向Chrome发送消息
|
||||
* @param message 消息
|
||||
*/
|
||||
export function sendChromeAPIMessage(message) {
|
||||
export async function sendChromeAPIMessage(message) {
|
||||
message.type = 'api'
|
||||
message.url = "https://kuajing.pinduoduo.com/" + message.url;
|
||||
message.anti = message.anti||false
|
||||
message.anti = message.anti || false
|
||||
if (message.needMallId) {
|
||||
// 如果参数中没有携带MallId,则从state中获取
|
||||
if (!message.mallId) {
|
||||
message.mallId = store.state.mallId;
|
||||
}
|
||||
}
|
||||
if(message.anti) {
|
||||
message.anti = genAnti()["messagePack"]({
|
||||
touchEventData: !0,
|
||||
clickEventData: !0,
|
||||
focusblurEventData: !0,
|
||||
changeEventData: !0,
|
||||
locationInfo: !0,
|
||||
referrer: !0,
|
||||
browserSize: !0,
|
||||
browserInfo: !0,
|
||||
token: !0,
|
||||
fingerprint: !0
|
||||
})
|
||||
if (message.anti) {
|
||||
message.anti = await genAnti.a()
|
||||
}
|
||||
return new Promise((resolve) => {
|
||||
// @ts-ignore
|
||||
|
||||
3551
src/api/genAnti.js
3551
src/api/genAnti.js
File diff suppressed because one or more lines are too long
208949
src/api/pddjs.js
Normal file
208949
src/api/pddjs.js
Normal file
File diff suppressed because one or more lines are too long
@@ -1 +1,25 @@
|
||||
console.log('hello world content todo something~')
|
||||
// import {genAnti} from "@/api/genAnti";
|
||||
|
||||
// const popup = document.createElement("div")
|
||||
// popup.innerText = "获取Anti"
|
||||
// const styles = {
|
||||
// position: "fixed",
|
||||
// right: '10px',
|
||||
// top: '60px',
|
||||
// zIndex: 9999,
|
||||
// padding: "8px",
|
||||
// background: "#409EFF",
|
||||
// color: "#fff",
|
||||
// borderRadius: "8px",
|
||||
// cursor: "pointer"
|
||||
// }
|
||||
// for (const e in styles) {
|
||||
// popup.style[e] = styles[e]
|
||||
// }
|
||||
//
|
||||
// popup.addEventListener('click', async () => {
|
||||
// const anti = await genAnti.a()
|
||||
// console.log(anti)
|
||||
// })
|
||||
// document.body.appendChild(popup)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user