wazuh-kibana-app/public/templates/agents-fim.html
2016-08-30 05:34:14 -07:00

138 lines
8.0 KiB
HTML

<md-content ng-if="submenuNavItem == 'fim'" ng-show="_agent" class="md-padding">
<div flex ng-controller="fimController" layout="column">
<md-virtual-repeat-container style="min-height: 600px;" >
<md-content layout="row">
<md-card flex="40">
<md-card-title>
<md-card-title-text>
<span class="md-headline">Events</span>
</md-card-title-text>
</md-card-title>
<md-card-content>
<kbn-vis vis-height="100px;" vis-type="histogram" vis-index-pattern="ossec-*" vis-a="(filters:!(),linked:!f,query:(query_string:(analyze_wildcard:!t,query:'rule.groups:%20syscheck')),uiState:(vis:(legendOpen:!f)),vis:(aggs:!((enabled:!t,id:'1',params:(),schema:metric,type:count),(enabled:!t,id:'2',params:(customInterval:'2h',extended_bounds:(),field:'@timestamp',interval:auto,min_doc_count:1),schema:segment,type:date_histogram)),listeners:(),params:(addLegend:!t,addTimeMarker:!f,addTooltip:!t,defaultYExtents:!f,mode:stacked,scale:linear,setYExtents:!f,shareYAxis:!t,times:!(),yAxis:()),title:'New%20Visualization',type:histogram))"
vis-g="(refreshInterval:(display:Off,pause:!f,value:0),time:(from:now-7d,mode:quick,to:now))" vis-filter="{{_agent.name ? 'AgentName:'+_agent.name : '*'}}">
</kbn-vis>
</md-card-content>
</md-card>
<md-card flex="30">
<md-card-title>
<md-card-title-text>
<span class="md-headline">Top users</span>
</md-card-title-text>
</md-card-title>
<md-card-content>
<kbn-vis vis-height="100px;" vis-type="pie" vis-index-pattern="ossec-*" vis-a="(filters:!(),linked:!f,query:(query_string:(analyze_wildcard:!t,query:'*')),uiState:(),vis:(aggs:!((enabled:!t,id:'1',params:(),schema:metric,type:count),(enabled:!t,id:'2',params:(field:SyscheckFile.uname_after,order:desc,orderBy:'1',size:5),schema:segment,type:terms)),listeners:(),params:(addLegend:!t,addTooltip:!t,isDonut:!f,shareYAxis:!t),title:'New%20Visualization',type:pie))"
vis-g="(refreshInterval:(display:Off,pause:!f,value:0),time:(from:now-7d,mode:quick,to:now))" vis-filter="{{'AgentName:'+_agent.name}}">
</kbn-vis>
</md-card-content>
</md-card>
<md-card flex="30">
<md-card-title>
<md-card-title-text>
<span class="md-headline">Top files</span>
</md-card-title-text>
</md-card-title>
<md-card-content>
<kbn-vis vis-height="100px;" vis-type="pie" vis-index-pattern="ossec-*" vis-a="(filters:!(),linked:!f,query:(query_string:(analyze_wildcard:!t,query:'*')),uiState:(),vis:(aggs:!((enabled:!t,id:'1',params:(),schema:metric,type:count),(enabled:!t,id:'2',params:(field:SyscheckFile.path,order:desc,orderBy:'1',size:5),schema:segment,type:terms)),listeners:(),params:(addLegend:!t,addTooltip:!t,isDonut:!f,shareYAxis:!t),title:'New%20Visualization',type:pie))"
vis-g="(refreshInterval:(display:Off,pause:!f,value:0),time:(from:now-7d,mode:quick,to:now))" vis-filter="{{'AgentName:'+_agent.name}}">
</kbn-vis>
</md-card-content>
</md-card>
</md-content>
<div flex layout="row">
<md-content flex id="content" layout="column">
<md-input-container layout="row" class="sideNavBox" ng-if="_agent">
<label for="searchBox">Search</label>
<input type="text" id="searchBox" ng-model="$parent.search" md-autofocus flex>
<md-icon md-font-icon="fa fa-cog" ng-click="showFilesFiltersDialog($event)" />
</md-input-container>
<div flex ng-if="!(_file)">
<md-toolbar layout="row" class="md-hue-3">
<div class="md-toolbar-tools">
<span flex="10" hide-sm hide-xs>Date</span>
<span flex="30">File name</span>
<span flex="10" hide-sm hide-xs>Event</span>
<span flex="10" hide-sm hide-xs>User</span>
<span flex="10" hide-sm hide-xs>Group</span>
<span flex="15" hide-sm hide-xs>Permissions</span>
<span flex="15" hide-sm hide-xs>Size</span>
</div>
</md-toolbar>
<div md-virtual-repeat="file in filesObj" md-on-demand flex layout-align="stretch">
<md-list>
<md-list-item ng-click="showFile[$index] = !showFile[$index]">
<span flex="10" hide-sm hide-xs>{{file.modificationDate}}</span>
<span flex="30">{{file.file.length > 58 ? file.file.substring(0, 55)+'...' : file.file}}</span>
<span flex="10" hide-sm hide-xs>{{file.event.charAt(0).toUpperCase() + file.event.slice(1)}}</span>
<span flex="10" hide-sm hide-xs>{{file.user}}</span>
<span flex="10" hide-sm hide-xs>{{file.group}}</span>
<span flex="15" hide-sm hide-xs>{{file.permissions}}</span>
<span flex="15" hide-sm hide-xs>{{file.size}} bits</span>
</md-list-item>
</md-list>
<md-list ng-show="showFile[$index]">
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>User ID</span>
<span flex="10" hide-sm hide-xs>{{file.uid}}</span>
</md-list-item>
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>Group ID</span>
<span flex="10" hide-sm hide-xs>{{file.gid}}</span>
</md-list-item>
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>Octal permissions</span>
<span flex="10" hide-sm hide-xs>{{file.octalMode}}</span>
</md-list-item>
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>Inode</span>
<span flex="10" hide-sm hide-xs>{{file.inode}}</span>
</md-list-item>
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>SHA1</span>
<span flex="10" hide-sm hide-xs>{{file.sha1}}</span>
</md-list-item>
<md-list-item>
<span style="font-weight: bold" flex="10" hide-sm hide-xs>MD5</span>
<span flex="10" hide-sm hide-xs>{{file.md5}}</span>
</md-list-item>
</md-list>
<md-divider></md-divider>
</div>
</div>
</md-content>
</div>
<div style="display: none">
<div class="md-dialog-container" id="filtersFilesDialog">
<md-dialog layout-padding layout="column" layout-align="space-around center">
<label>Filter by event:</label>
<md-input-container>
<md-select ng-model="eventFilter" ng-change="setEventFilter()" aria-label="Filter by event">
<md-option value="all">All</md-option>
<md-option value="added">Added</md-option>
<md-option value="modified">Modified</md-option>
<md-option value="readded">Re-added</md-option>
<md-option value="">Deleted</md-option>
</md-select>
</md-input-container>
<label>Filter by type:</label>
<md-input-container>
<md-select ng-model="typeFilter" ng-change="setTypeFilter()" aria-label="Filter by type">
<md-option value="all">All</md-option>
<md-option value="file">File</md-option>
<md-option value="registry">Registry</md-option>
</md-select>
</md-input-container>
</md-dialog>
</div>
</div>
</md-virtual-repeat-container>
</div>