妙手:修正误判——提交一直有触发,失败因验证码读错(实测命中率约1/5);建议配 OCR 或人工登录
This commit is contained in:
1 parent
61daff1241
commit
3f60416e9c
3 files changed
+71
No files matched your search
@@ -0,0 +1,14 @@
|
||||
import { listPages, wait } from '/home/admin9webs/shein建品/sh_lib.mjs';
|
||||
import { CDP, SAN as S } from '/tmp/cdp3.mjs';
|
||||
const t=(await listPages()).find(x=>/91miaoshou/i.test(x.url));
|
||||
const c=await CDP.connect(t.webSocketDebuggerUrl);
|
||||
await c.send('Runtime.enable'); await wait(1000);
|
||||
const o=await c.evalJS(`(()=>{
|
||||
const b=document.querySelector('.login-form__submit-btn');
|
||||
const ins=[...document.querySelectorAll('input')].filter(e=>e.offsetParent!==null).map(e=>({ph:e.placeholder||'',val:String(e.value||'').slice(0,3)+'…',dis:e.disabled,ro:e.readOnly}));
|
||||
const txt=(document.body.innerText||'').replace(/\\s+/g,' ');
|
||||
const hints=txt.match(/.{0,16}(锁定|失败|次数|验证|禁用).{0,22}/g);
|
||||
return JSON.stringify({btn: b?{dis:b.disabled, cls:String(b.className).slice(0,60), txt:(b.innerText||'').trim()}:null,
|
||||
ins, hints:(hints||[]).slice(0,6), href:location.href});})()`);
|
||||
console.log('诊断:', S(String(o)).slice(0,900));
|
||||
process.exit(0);
|
||||
Reference in new issue
Block a user