HEX
Server: nginx/1.28.3
System: Linux ip-172-31-12-242 6.17.0-1007-aws #7~24.04.1-Ubuntu SMP Thu Jan 22 21:04:49 UTC 2026 x86_64
User: root (0)
PHP: 7.4.33
Disabled: passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
Upload Files
File: /www/server/panel/BTPanel/static/js/safeDetect-legacy.js
!function(){function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */var t,o,s="function"==typeof Symbol?Symbol:{},n=s.iterator||"@@iterator",a=s.toStringTag||"@@toStringTag";function c(e,s,n,a){var c=s&&s.prototype instanceof l?s:l,u=Object.create(c.prototype);return r(u,"_invoke",function(e,r,s){var n,a,c,l=0,u=s||[],f=!1,p={p:0,n:0,v:t,a:d,f:d.bind(t,4),d:function(e,r){return n=e,a=0,c=t,p.n=r,i}};function d(e,r){for(a=e,c=r,o=0;!f&&l&&!s&&o<u.length;o++){var s,n=u[o],d=p.p,y=n[2];e>3?(s=y===r)&&(c=n[(a=n[4])?5:(a=3,3)],n[4]=n[5]=t):n[0]<=d&&((s=e<2&&d<n[1])?(a=0,p.v=r,p.n=n[1]):d<y&&(s=e<3||n[0]>r||r>y)&&(n[4]=e,n[5]=r,p.n=y,a=0))}if(s||e>1)return i;throw f=!0,r}return function(s,u,y){if(l>1)throw TypeError("Generator is already running");for(f&&1===u&&d(u,y),a=u,c=y;(o=a<2?t:c)||!f;){n||(a?a<3?(a>1&&(p.n=-1),d(a,c)):p.n=c:p.v=c);try{if(l=2,n){if(a||(s="next"),o=n[s]){if(!(o=o.call(n,c)))throw TypeError("iterator result is not an object");if(!o.done)return o;c=o.value,a<2&&(a=0)}else 1===a&&(o=n.return)&&o.call(n),a<2&&(c=TypeError("The iterator does not provide a '"+s+"' method"),a=1);n=t}else if((o=(f=p.n<0)?c:e.call(r,p))!==i)break}catch(o){n=t,a=1,c=o}finally{l=1}}return{value:o,done:f}}}(e,n,a),!0),u}var i={};function l(){}function u(){}function f(){}o=Object.getPrototypeOf;var p=[][n]?o(o([][n]())):(r(o={},n,function(){return this}),o),d=f.prototype=l.prototype=Object.create(p);function y(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,f):(t.__proto__=f,r(t,a,"GeneratorFunction")),t.prototype=Object.create(d),t}return u.prototype=f,r(d,"constructor",f),r(f,"constructor",u),u.displayName="GeneratorFunction",r(f,a,"GeneratorFunction"),r(d),r(d,a,"Generator"),r(d,n,function(){return this}),r(d,"toString",function(){return"[object Generator]"}),(e=function(){return{w:c,m:y}})()}function r(t,e,o,s){var n=Object.defineProperty;try{n({},"",{})}catch(t){n=0}r=function(t,e,o,s){function a(e,o){r(t,e,function(t){return this._invoke(e,o,t)})}e?n?n(t,e,{value:o,enumerable:!s,configurable:!s,writable:!s}):t[e]=o:(a("next",0),a("throw",1),a("return",2))},r(t,e,o,s)}function o(t,e,r,o,s,n,a){try{var c=t[n](a),i=c.value}catch(t){return void r(t)}c.done?e(i):Promise.resolve(i).then(o,s)}function s(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,o)}return r}function n(e,r,o){return(r=function(e){var r=function(e,r){if("object"!=t(e)||!e)return e;var o=e[Symbol.toPrimitive];if(void 0!==o){var s=o.call(e,r||"default");if("object"!=t(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(e)}(e,"string");return"symbol"==t(r)?r:r+""}(r))in e?Object.defineProperty(e,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[r]=o,e}System.register(["./base-lib-legacy.js?v=1777008528","./utils-lib-legacy.js?v=1777008528","./firewall-legacy.js?v=1777008528","./index-legacy387.js?v=1777008528","./__commonjsHelpers__-legacy.js?v=1777008528","./index-legacy3.js?v=1777008528","./index-legacy119.js?v=1777008528","./index-legacy116.js?v=1777008528"],function(t,r){"use strict";var a,c,i,l,u,f,p,d,y,v,g,m,b,h,w,_,k,S,j,O,x,E,T,P,C,D,G,F,H,A,I;return{setters:[function(t){a=t.c,c=t.t,i=t.r,l=t.H,u=t.g,f=t.o,p=t.I,d=t.J,y=t.p,v=t.j,g=t.k,m=t.q,b=t.L,h=t.C,w=t.F,_=t.e,k=t.x,S=t.s,j=t.y,O=t.v,x=t.B,E=t.aX,T=t.z},function(t){P=t.c,C=t.dD,D=t.R,G=t.d8,F=t.a0,H=t.cZ},function(t){A=t.aS},function(t){I=t.H},null,null,null,null],execute:function(){var r={id:"safeDetectList"},M={class:"progress-header"},N={class:"progress-header-cot"},J={key:0,class:"relative"},L={class:"absolute top-[1.6rem] left-[2.6rem] flex flex-col"},q={class:"progress-header-cot"},z={class:"scanning-progress-title"},B={class:"color-org"},R={class:"color-red"},V={class:"scanning-progress-cont"},X={class:"progress-header-cot"},Z={class:"progress-cont-list"},K=["onClick"],Q={class:"progress_type"},U={class:"progress_status"},W={key:0,class:"text-danger"},Y={key:1,class:"text-warning"},$={key:1},tt={key:2,class:"text-secondary"},et={key:0},rt={key:0,class:"progress_fold"},ot={class:"progress_item_body"},st={class:"info_cont"},nt={class:"info_cont_desc"},at=a({__name:"safeDetect",setup:function(t){var a=P().payment,H=I(),at=c(a.value).authType,ct=i(!1),it=[{color:"#888",text:"未安装"},{color:"#666",text:"良好"},{color:"#e6a23c",text:"警告"},{color:"red",text:"危险"}],lt={system_account:"系统账户",sshd_service:"SSHD远程服务",file_mode:"重要文件权限及属性",software:"重点软件检测",other:"其他项目检测",backdoor:"后门检测",proc:"恶意进程",history:"历史命令",log:"日志排查",rootkit:"rootkit检测"},ut=i({}),ft=l(function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?s(Object(r),!0).forEach(function(e){n(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}({},{scanStatus:!1,isEnd:!1,error:0,warn:0,time:0,progress:0,progressColor:"var(--el-color-primary)",progressConfig:{system_account:[],sshd_service:[],file_mode:[],software:[],other:[],backdoor:[],proc:[],history:[],log:[],rootkit:[]},statusTotal:{},allArr:[],result:{},progressStatus:{},active:{system_account:!1,sshd_service:!1,file_mode:!1,software:!1,other:!1,backdoor:!1,proc:!1,history:!1,log:!1,rootkit:!1}})),pt=function(t){return t+" 分"},dt=null,yt=u(function(){return ft.scanStatus&&!ft.isEnd?"正在扫描":ut.value.status?"上次检测时间 "+("刚刚"===C(ut.value.msg.time)?"一分钟内":C(ut.value.msg.time)):"当前未进行安全检测"}),vt=i(""),gt=i(""),mt=u(function(){return ft.scanStatus&&!ft.isEnd?"正在扫描-".concat(vt.value):ft.isEnd?"检测时间:"+D(ft.time/1e3,"yyyy-MM-dd"):ut.value.status?"若长时间未检测,服务器可能存在安全风险,建议立即检测":"当前安全风险未知,请立即检测"}),bt=function(t,e){if(e.data){var r,o=JSON.parse(e.data.replace(/'/g,'"'));if(o.hasOwnProperty("callback"))null===(r=dt)||void 0===r||r.close(),ft.scanStatus=!1,ft.isEnd=!0,ft.time=(new Date).getTime();else vt.value=o.name,gt.value=o.topic,ft.progress=parseInt(o.progress),ft.progressConfig[o.topic].push(o),ft.progressConfig[o.topic].sort(function(t,e){return 1===t.status&&1!==e.status?1:1!==t.status&&1===e.status?-1:e.status-t.status}),ft.statusTotal[o.topic]=ht(ft.progressConfig[o.topic]),ft.allArr.push(o),3===o.status&&ft.error++,2!==o.status&&3!==o.status||ft.warn++,1!==o.status&&(ft.progressColor="#fc6d26")}},ht=function(t){var e={};return t.forEach(function(t){e[t.status]?e[t.status]++:e[t.status]=1}),e},wt=function(){var t,e;return"ltd"!==at.value?H.openPayView():(ft.scanStatus&&!ft.isEnd||ft.isEnd,ft.scanStatus&&!ft.isEnd?(null===(e=dt)||void 0===e||e.close(),void _t()):(ft.isEnd&&_t(),ft.scanStatus=!0,void(null===(t=dt=F({route:"/ws_project",onMessage:bt}))||void 0===t||t.send({mod_name:"safe_detect",def_name:"get_safe_scan",ws_callback:""}))))},_t=function(){ft.scanStatus=!1,ft.isEnd=!1,ft.error=0,ft.warn=0,ft.time=0,ft.progress=0,ft.progressColor="var(--el-color-primary)",ft.progressConfig={system_account:[],sshd_service:[],file_mode:[],software:[],other:[],backdoor:[],proc:[],history:[],log:[],rootkit:[]},ft.statusTotal={},ft.allArr=[],ft.result={},ft.progressStatus={},ft.active={system_account:!1,sshd_service:!1,file_mode:!1,software:!1,other:!1,backdoor:!1,proc:!1,history:!1,log:!1,rootkit:!1}},kt=function(){var t,r=(t=e().m(function t(){var r;return e().w(function(t){for(;;)switch(t.p=t.n){case 0:return t.p=0,t.n=1,A();case 1:r=t.v,ut.value=r.data,t.n=3;break;case 2:t.p=2,t.v;case 3:return t.a(2)}},t,null,[[0,2]])}),function(){var e=this,r=arguments;return new Promise(function(s,n){var a=t.apply(e,r);function c(t){o(a,s,n,c,i,"next",t)}function i(t){o(a,s,n,c,i,"throw",t)}c(void 0)})});return function(){return r.apply(this,arguments)}}();return f(function(){kt()}),function(t,e){var o,s,n,a=G,c=E,i=T,l=p("bt-loading");return d((v(),g("div",r,[e[6]||(e[6]=m("div",{class:"text-large mb-6"},"服务器安全检测",-1)),m("div",M,[m("div",N,[m("div",{class:b("progresscirclebar "+(y(ut).status?"security ":"")+"text-["+(100===(null===(o=y(ut).msg)||void 0===o?void 0:o.security_count)?" var(--el-color-primary) ":" #fc6d26 ")+"]")},[y(ut).status?(v(),g(w,{key:1},[y(ft).scanStatus&&!y(ft).isEnd?(v(),g("div",J,[_(c,{class:"animate-spin",type:"circle",percentage:70,"show-text":!1,"stroke-width":4,"define-back-color":"#fff",color:y(ft).warn||y(ft).error?"#fc6d26":"var(--el-color-primary)",width:100},null,8,["color"]),m("div",L,[_(a,{class:"w-[full] px-[.4rem]",src:"/firewall/icon-safe-detect".concat(y(ft).warn||y(ft).error?"-org":"",".svg")},null,8,["src"]),e[0]||(e[0]=m("span",{class:"text-small font-bold py-[.4rem] leading-none"}," 安全检测 ",-1))])])):(v(),h(c,{key:1,type:"circle",percentage:null===(s=y(ut).msg)||void 0===s?void 0:s.security_count,format:pt,color:100===(null===(n=y(ut).msg)||void 0===n?void 0:n.security_count)?"var(--el-color-primary)":"#fc6d26",width:100},null,8,["percentage","color"]))],64)):(v(),h(a,{key:0,class:"w-[10rem]",src:"/firewall/icon-safe-detect.svg"}))],2)]),m("div",q,[m("div",z,[y(ft).isEnd?(v(),g(w,{key:1},[e[5]||(e[5]=k(" 检测已完成 ",-1)),y(ft).error>0||y(ft).warn>0?(v(),g(w,{key:0},[e[4]||(e[4]=k(" ,一共发现 ",-1)),y(ft).warn>0?(v(),g(w,{key:0},[m("span",B,S(y(ft).warn),1),e[1]||(e[1]=k(" 项风险项 ",-1))],64)):j("",!0),y(ft).error>0?(v(),g(w,{key:1},[e[2]||(e[2]=k(" (包含 ",-1)),m("span",R,S(y(ft).error),1),e[3]||(e[3]=k(" 项危险项,请立即处理) ",-1))],64)):j("",!0)],64)):j("",!0)],64)):(v(),g(w,{key:0},[k(S(y(yt)),1)],64))]),y(ft).scanStatus?(v(),h(c,{key:0,percentage:y(ft).progress,color:y(ft).warn||y(ft).error?"#fc6d26":"var(--el-color-primary)","stroke-width":10},null,8,["percentage","color"])):j("",!0),m("div",V,S(y(mt)),1)]),m("div",X,[_(i,{type:y(ft).scanStatus&&!y(ft).isEnd?"warning":"primary",onClick:wt,plain:!(!y(ft).scanStatus||y(ft).isEnd)},{default:O(function(){return[k(S(y(ft).scanStatus&&!y(ft).isEnd?"取消扫描":y(ft).isEnd?"重新检测":"立即检测"),1)]}),_:1},8,["type","plain"])])]),m("div",Z,[(v(),g(w,null,x(lt,function(t,e){return m("div",{key:e,class:b([e+"_item "+(y(ft).active[e]?"active":""),"progress_item"])},[m("div",{class:"progress_item_header",onClick:function(t){return function(t){ft.active[t]=!ft.active[t]}(e)}},[m("div",Q,[_(a,{class:"title-icon",src:"/firewall/icon-"+e+".svg"},null,8,["src"]),m("span",null,S(t),1)]),m("div",U,[y(ft).statusTotal[e]?(v(),g(w,{key:0},[y(ft).statusTotal[e][3]||y(ft).statusTotal[e][2]?(v(),g(w,{key:0},[y(ft).statusTotal[e][3]?(v(),g("span",W," 发现"+S(y(ft).statusTotal[e][3])+"项危险 ",1)):j("",!0),y(ft).statusTotal[e][2]?(v(),g("span",Y,S((y(ft).statusTotal[e][3]?"":"发现")+y(ft).statusTotal[e][2])+"项警告 ",1)):j("",!0)],64)):y(ft).scanStatus&&y(gt)==e?(v(),g("span",$," 正在扫描... ")):(v(),g("span",tt,"无风险项"))],64)):(v(),g(w,{key:1},[y(ft).scanStatus&&!y(ft).statusTotal[e]?(v(),g("span",et," 等待扫描 ")):j("",!0)],64))]),y(ft).progressConfig[e]&&y(ft).progressConfig[e].length?(v(),g("div",rt,[_(a,{src:"/firewall/arrow-down.svg",class:"mt-[.6rem]"})])):j("",!0)],8,K),m("div",ot,[y(ft).progressConfig[e]&&y(ft).progressConfig[e].length?(v(!0),g(w,{key:0},x(y(ft).progressConfig[e],function(t,e){return v(),g("div",{key:e,class:b([t.info?"active":"","progress_item_info"])},[m("div",st,[m("div",null,S(t.name.replace("分析网站","")),1),m("div",{class:b("text-["+it[t.status<0?0:t.status].color+"]")},S(it[t.status<0?0:t.status].text),3)]),m("div",nt,S(t.info||""),1)],2)}),128)):j("",!0)])],2)}),64))])])),[[l,y(ct)]])}}});t("default",H(at,[["__scopeId","data-v-7c7093b6"]]))}}})}();