SpyGuard/app/backend/dist/js/chunk-2d0c9378.fb16a6a2.js

2 lines
6.2 KiB
JavaScript
Raw Normal View History

2022-11-06 15:51:33 +01:00
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d0c9378"],{"57cc":function(t,s,i){"use strict";i.r(s);var e=function(){var t=this,s=t._self._c;return s("div",{staticClass:"backend-content",attrs:{id:"content"}},[s("div",{staticClass:"column col-8 col-xs-12"},[s("h3",{staticClass:"s-title"},[t._v("Manage MISP instances")]),s("ul",{staticClass:"tab tab-block"},[s("li",{staticClass:"tab-item"},[s("a",{class:{active:t.tabs.addmisp},attrs:{href:"#"},on:{click:function(s){return t.switch_tab("addmisp")}}},[t._v("Add instance")])]),s("li",{staticClass:"tab-item"},[s("a",{class:{active:t.tabs.instances},attrs:{href:"#"},on:{click:function(s){return t.switch_tab("instances")}}},[t._v("Existing instances")])])]),t.tabs.addmisp?s("div",[s("div",{staticClass:"misp-form"},[s("label",{staticClass:"misp-label"},[t._v("Instance name")]),s("span"),s("input",{directives:[{name:"model",rawName:"v-model",value:t.mispinst.name,expression:"mispinst.name"}],ref:"misp_name",staticClass:"form-input",attrs:{type:"text",placeholder:"CYBERACME MISP",required:""},domProps:{value:t.mispinst.name},on:{input:function(s){s.target.composing||t.$set(t.mispinst,"name",s.target.value)}}}),s("label",{staticClass:"misp-label"},[t._v("Instance URL")]),s("span"),s("input",{directives:[{name:"model",rawName:"v-model",value:t.mispinst.url,expression:"mispinst.url"}],ref:"misp_url",staticClass:"form-input",attrs:{type:"text",placeholder:"https://misp.cyberacme.com",required:""},domProps:{value:t.mispinst.url},on:{input:function(s){s.target.composing||t.$set(t.mispinst,"url",s.target.value)}}}),s("label",{staticClass:"misp-label"},[t._v("Authentication key")]),s("span"),s("input",{directives:[{name:"model",rawName:"v-model",value:t.mispinst.key,expression:"mispinst.key"}],ref:"misp_key",staticClass:"form-input",attrs:{type:"text",placeholder:"OqHSMyAuth3ntic4t10nK3y0MyAuth3ntic4t10nK3y3iiH",required:""},domProps:{value:t.mispinst.key},on:{input:function(s){s.target.composing||t.$set(t.mispinst,"key",s.target.value)}}}),t.mispinst.url.startsWith("https://")?s("label",{staticClass:"misp-label"},[t._v("Verify certificate? ")]):t._e(),t.mispinst.url.startsWith("https://")?s("span"):t._e(),t.mispinst.url.startsWith("https://")?s("div",{staticStyle:{flex:"50%"}},[s("label",{staticClass:"form-switch"},[s("input",{directives:[{name:"model",rawName:"v-model",value:t.mispinst.ssl,expression:"mispinst.ssl"}],attrs:{type:"checkbox"},domProps:{checked:Array.isArray(t.mispinst.ssl)?t._i(t.mispinst.ssl,null)>-1:t.mispinst.ssl},on:{change:function(s){var i=t.mispinst.ssl,e=s.target,a=!!e.checked;if(Array.isArray(i)){var n=null,c=t._i(i,n);e.checked?c<0&&t.$set(t.mispinst,"ssl",i.concat([n])):c>-1&&t.$set(t.mispinst,"ssl",i.slice(0,c).concat(i.slice(c+1)))}else t.$set(t.mispinst,"ssl",a)}}}),s("i",{staticClass:"form-icon"})])]):t._e()]),s("button",{staticClass:"btn-primary btn col-12",on:{click:function(s){return t.add_instance()}}},[t._v("Add MISP instance")]),t.added?s("div",{staticClass:"form-group"},[s("div",{staticClass:"toast toast-success"},[t._v(" ✓ MISP instance added successfully. Redirecting to instances in 2 seconds. ")])]):t._e(),t.error?s("div",{staticClass:"form-group"},[s("div",{staticClass:"toast toast-error"},[t._v(" ✗ MISP instance not added. "+t._s(t.error)+" ")])]):t._e()]):t._e(),t.tabs.instances?s("div",{staticClass:"form-group"},[t.instances.length?s("div",[s("table",{staticClass:"table table-striped table-hover"},[t._m(0),s("tbody",t._l(t.instances,(function(i){return s("tr",{key:i.id},[s("td",[t._v(t._s(i.name))]),s("td",[t._v(t._s(i.url.replace("https://","").replace("http://","")))]),s("td",[t._v(t._s(i.apikey.slice(0,5))+" [...] "+t._s(i.apikey.slice(35,40)))]),s("td",[i.connected?s("span",{staticClass:"instance-online tooltip",attrs:{"data-tooltip":i.lastsync}},[t._v("✓ ONLINE")]):s("span",{staticClass:"instance-offline tooltip",attrs:{"data-tooltip":i.lastsync}},[t._v("⚠ OFFLINE")])]),s("td",[s("button",{staticClass:"btn btn-sm",on:{click:function(s){return t.delete_instance(i)}}},[t._v("Delete")])])])})),0)])]):s("div",[s(
//# sourceMappingURL=chunk-2d0c9378.fb16a6a2.js.map