forked from p34709852/monkey
cc: Change variables from snake case to camel case for consistency
This commit is contained in:
parent
ee5585af75
commit
e3045c255a
|
@ -53,29 +53,29 @@ class T1086 extends React.Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
segregatePowershellDataPerCategory() {
|
segregatePowershellDataPerCategory() {
|
||||||
let exploit_category_name = 'exploit';
|
let exploitCategoryName = 'exploit';
|
||||||
let pba_category_name = 'post_breach';
|
let pbaCategoryName = 'post_breach';
|
||||||
|
|
||||||
let data_from_exploits = [];
|
let dataFromExploits = [];
|
||||||
let data_from_pbas = [];
|
let dataFromPBAs = [];
|
||||||
|
|
||||||
for (let rowIdx in this.props.data.cmds) {
|
for (let rowIdx in this.props.data.cmds) {
|
||||||
let row = this.props.data.cmds[rowIdx];
|
let row = this.props.data.cmds[rowIdx];
|
||||||
if (row.telem_category == exploit_category_name) {
|
if (row.telem_category == exploitCategoryName) {
|
||||||
data_from_exploits.push(row);
|
dataFromExploits.push(row);
|
||||||
}
|
}
|
||||||
else if (row.telem_category == pba_category_name) {
|
else if (row.telem_category == pbaCategoryName) {
|
||||||
data_from_pbas.push(row);
|
dataFromPBAs.push(row);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return [data_from_exploits, data_from_pbas]
|
return [dataFromExploits, dataFromPBAs]
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
let segregatedData = this.segregatePowershellDataPerCategory();
|
let segregatedData = this.segregatePowershellDataPerCategory();
|
||||||
let data_from_exploits = segregatedData[0];
|
let dataFromExploits = segregatedData[0];
|
||||||
let data_from_pbas = segregatedData[1];
|
let dataFromPBAs = segregatedData[1];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
|
@ -85,17 +85,17 @@ class T1086 extends React.Component {
|
||||||
<div>
|
<div>
|
||||||
<ReactTable
|
<ReactTable
|
||||||
columns={T1086.getPowershellColumnsForExploits()}
|
columns={T1086.getPowershellColumnsForExploits()}
|
||||||
data={data_from_exploits}
|
data={dataFromExploits}
|
||||||
showPagination={false}
|
showPagination={false}
|
||||||
defaultPageSize={data_from_exploits.length}
|
defaultPageSize={dataFromExploits.length}
|
||||||
/>
|
/>
|
||||||
<br/>
|
<br/>
|
||||||
<br/>
|
<br/>
|
||||||
<ReactTable
|
<ReactTable
|
||||||
columns={T1086.getPowershellColumnsForPBAs()}
|
columns={T1086.getPowershellColumnsForPBAs()}
|
||||||
data={data_from_pbas}
|
data={dataFromPBAs}
|
||||||
showPagination={false}
|
showPagination={false}
|
||||||
defaultPageSize={data_from_pbas.length}
|
defaultPageSize={dataFromPBAs.length}
|
||||||
/>
|
/>
|
||||||
</div> : ''}
|
</div> : ''}
|
||||||
<MitigationsComponent mitigations={this.props.data.mitigations}/>
|
<MitigationsComponent mitigations={this.props.data.mitigations}/>
|
||||||
|
|
Loading…
Reference in New Issue