import{u as a,P as s,M as e,n as o,Q as t,l as r,$ as n}from"./utils-lib.js?v=1761009159";import{_ as l}from"./index105.js?v=1761009159";import{c as i,r as m,e as p,an as c,w as u,q as _,H as d,v as f,x as j,B as y,I as g,y as w}from"./base-lib.js?v=1761009159";import{aI as S,aJ as b}from"./firewall.js?v=1761009159";import{u as x}from"./column.js?v=1761009159";import{g as E}from"./useStore5.js?v=1761009159";import"./__commonjsHelpers__.js?v=1761009159";import"./index106.js?v=1761009159";const I={class:"py-[.8rem]"},k=i({__name:"index",setup(i){const{refs:{reinforceStatus:k}}=E();a();const v=m(!1),H=m([]),P=[{content:"【异常进程监控】与【SSH服务加固】会占用一定服务器开销"},{content:"开启系统加固功能后，一些如软件安装等敏感操作将被禁止"},{content:"开启【SSH服务加固】之后，用户登录SSH的行为将受到监控，若连续多次登录失败，将采取封IP措施"},{class:"text-warning",content:"【注意】如果您需要安装软件或插件，请先将系统加固关闭！"}],h=async()=>{await s({loading:v,request:S(),data:{list:[Array,H],open:[Boolean,k]}})},A=[{label:"名称",prop:"name"},{label:"描述",prop:"ps"},{label:"状态",render:a=>p(c,{modelValue:a.open,size:"small",onChange:o=>(async(a,o)=>{if(!k.value)return e.error("请先开启系统加固功能");await s({loading:"正在"+(o?"开启":"关闭")+"防护配置，请稍后...",request:b({s_key:a.key}),message:!0}),h()})(a,o)},null)},x([{onClick:async a=>{o({title:"配置【".concat(a.name,"】"),component:()=>"ssh"===a.key?t(()=>import("./row-ssh-config.js?v=1761009159"),__vite__mapDeps([]),import.meta.url):"process"===a.key?t(()=>import("./row-process.js?v=1761009159"),__vite__mapDeps([]),import.meta.url):t(()=>import("./row-reinforce.js?v=1761009159"),__vite__mapDeps([]),import.meta.url),compData:a,area:72})},title:"配置"}])];return u(()=>k.value,a=>{a?h():H.value.forEach(a=>a.open=!1)}),_(h),(a,s)=>{const e=r,o=l,t=n,i=d("bt-loading");return f(),j("div",I,[p(o,null,{content:y(()=>[g(p(e,{column:A,data:w(H),description:"防护配置列表为空"},null,8,["data"]),[[i,w(v)],[i,"正在加载防护配置列表，请稍后...","title"]])]),_:1}),p(t,{options:P,class:"mx-[1.6rem] my-[0.6rem]"})])}}});export{k as default};
function __vite__mapDeps(indexes) {
  if (!__vite__mapDeps.viteFileDeps) {
    __vite__mapDeps.viteFileDeps = []
  }
  return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
}
