mirror of
https://github.com/infinition/Bjorn.git
synced 2026-03-16 09:02:00 +00:00
Add Loki and Sentinel utility classes for web API endpoints
- Implemented LokiUtils class with GET and POST endpoints for managing scripts, jobs, and payloads. - Added SentinelUtils class with GET and POST endpoints for managing events, rules, devices, and notifications. - Both classes include error handling and JSON response formatting.
This commit is contained in:
493
web/css/pages/zombieland.css
Normal file
493
web/css/pages/zombieland.css
Normal file
@@ -0,0 +1,493 @@
|
||||
/* ==========================================================================
|
||||
ZOMBIELAND (C2 Module) CSS
|
||||
========================================================================== */
|
||||
|
||||
/* Main layout constraints */
|
||||
.zombieland-container.page-with-sidebar {
|
||||
height: calc(100vh - var(--h-topbar, 56px) - var(--h-bottombar, 56px) - 24px);
|
||||
display: flex;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.zl-sidebar.page-sidebar {
|
||||
width: 260px;
|
||||
flex-shrink: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: var(--grad-card);
|
||||
border: 1px solid var(--c-border);
|
||||
border-radius: 12px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.zl-main.page-main {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
/* Sidebar structure */
|
||||
.zl-stats-grid {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr;
|
||||
gap: 8px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
.stat-item {
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
border: 1px solid var(--c-border);
|
||||
padding: 10px;
|
||||
border-radius: 8px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.stat-item .stat-value {
|
||||
font-weight: bold;
|
||||
color: var(--acid);
|
||||
font-size: 1.1rem;
|
||||
}
|
||||
|
||||
.stat-item .stat-label {
|
||||
font-size: 0.8rem;
|
||||
color: var(--muted);
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.zl-toolbar {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
/* Modals */
|
||||
.modal {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background: rgba(0, 0, 0, 0.8);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
.modal-content {
|
||||
background: var(--grad-card);
|
||||
border: 1px solid var(--c-border);
|
||||
padding: 20px;
|
||||
border-radius: 12px;
|
||||
width: 100%;
|
||||
max-width: 400px;
|
||||
}
|
||||
|
||||
/* Main Grid Layout */
|
||||
.zl-main-grid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
|
||||
gap: 12px;
|
||||
flex: 1;
|
||||
/* Takes available space except logs */
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.zl-console-panel,
|
||||
.zl-agents-panel,
|
||||
.zl-logs-panel {
|
||||
border: 1px solid var(--c-border);
|
||||
border-radius: 12px;
|
||||
background: var(--c-panel);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Log Panel underneath */
|
||||
.zl-logs-panel {
|
||||
height: 150px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.zl-panel-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 8px 12px;
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
border-bottom: 1px solid var(--c-border);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.zl-panel-title {
|
||||
font-weight: bold;
|
||||
font-size: 0.9rem;
|
||||
color: var(--acid);
|
||||
}
|
||||
|
||||
.zl-quickbar {
|
||||
display: flex;
|
||||
gap: 4px;
|
||||
}
|
||||
|
||||
.quick-cmd {
|
||||
background: transparent;
|
||||
border: 1px solid var(--c-border-strong);
|
||||
color: var(--muted);
|
||||
font-size: 0.7rem;
|
||||
padding: 2px 6px;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
transition: 0.2s;
|
||||
}
|
||||
|
||||
.quick-cmd:hover {
|
||||
color: var(--acid);
|
||||
border-color: var(--acid);
|
||||
}
|
||||
|
||||
.zl-console-output,
|
||||
.zl-logs-output {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
padding: 10px;
|
||||
font-family: 'Fira Code', monospace;
|
||||
font-size: 0.8rem;
|
||||
background: #020406;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
/* Controls */
|
||||
.zl-console-input-row {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
padding: 8px;
|
||||
border-top: 1px solid var(--c-border);
|
||||
background: var(--c-panel-2);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.zl-target-select,
|
||||
.zl-cmd-input,
|
||||
.zl-search-input {
|
||||
background: #000;
|
||||
color: #fff;
|
||||
border: 1px solid var(--c-border-strong);
|
||||
padding: 6px 10px;
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
.zl-cmd-input {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.zl-toolbar-left {
|
||||
display: flex;
|
||||
position: relative;
|
||||
flex: 1;
|
||||
max-width: 200px;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.zl-search-input {
|
||||
width: 100%;
|
||||
border-radius: 6px;
|
||||
padding: 4px 20px 4px 8px;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.zl-search-clear {
|
||||
position: absolute;
|
||||
right: 5px;
|
||||
top: 5px;
|
||||
color: var(--muted);
|
||||
background: none;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.zl-agents-list {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
padding: 10px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
/* Agent Card Styles */
|
||||
.zl-agent-card {
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
border: 1px solid var(--c-border);
|
||||
border-radius: 8px;
|
||||
padding: 8px 12px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
transition: 0.2s ease-out;
|
||||
}
|
||||
|
||||
.zl-agent-card.selected {
|
||||
border-color: var(--acid);
|
||||
background: rgba(0, 255, 160, 0.05);
|
||||
}
|
||||
|
||||
.zl-agent-card:hover {
|
||||
border-color: var(--c-border-hi);
|
||||
}
|
||||
|
||||
.zl-card-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.zl-card-identity {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.zl-card-hostname {
|
||||
font-weight: bold;
|
||||
color: #fff;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.zl-card-id {
|
||||
font-size: 0.7rem;
|
||||
color: var(--muted);
|
||||
}
|
||||
|
||||
.zl-pill {
|
||||
padding: 2px 8px;
|
||||
border-radius: 12px;
|
||||
font-size: 0.7rem;
|
||||
font-weight: bold;
|
||||
background: #222;
|
||||
}
|
||||
|
||||
.zl-pill.online {
|
||||
color: #00ffa0;
|
||||
background: rgba(0, 255, 160, 0.1);
|
||||
}
|
||||
|
||||
.zl-pill.idle {
|
||||
color: #ffcc00;
|
||||
background: rgba(255, 204, 0, 0.1);
|
||||
}
|
||||
|
||||
.zl-pill.offline {
|
||||
color: #ff3333;
|
||||
background: rgba(255, 51, 51, 0.1);
|
||||
}
|
||||
|
||||
/* ECG Animation */
|
||||
.zl-ecg-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.ecg {
|
||||
width: 100%;
|
||||
height: 24px;
|
||||
max-width: 140px;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
background: rgba(0, 0, 0, 0.5);
|
||||
border-radius: 6px;
|
||||
border: 1px solid #111;
|
||||
}
|
||||
|
||||
.ecg-wrapper {
|
||||
display: flex;
|
||||
width: 300%;
|
||||
animation: ecg-slide linear infinite;
|
||||
}
|
||||
|
||||
.ecg svg {
|
||||
width: 33.33%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.ecg path {
|
||||
fill: none;
|
||||
stroke-width: 1.5;
|
||||
stroke-linecap: round;
|
||||
stroke-linejoin: round;
|
||||
}
|
||||
|
||||
.ecg.green path {
|
||||
stroke: #00ffa0;
|
||||
filter: drop-shadow(0 0 2px #00ffa0);
|
||||
}
|
||||
|
||||
.ecg.yellow path {
|
||||
stroke: #ffcc00;
|
||||
filter: drop-shadow(0 0 2px #ffcc00);
|
||||
}
|
||||
|
||||
.ecg.orange path {
|
||||
stroke: #ff8800;
|
||||
filter: drop-shadow(0 0 2px #ff8800);
|
||||
}
|
||||
|
||||
.ecg.red path {
|
||||
stroke: #ff3333;
|
||||
}
|
||||
|
||||
.ecg.flat .ecg-wrapper {
|
||||
animation: none;
|
||||
}
|
||||
|
||||
@keyframes ecg-slide {
|
||||
0% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
|
||||
100% {
|
||||
transform: translateX(-33.33%);
|
||||
}
|
||||
}
|
||||
|
||||
.zl-ecg-counter {
|
||||
font-size: 0.7rem;
|
||||
color: var(--muted);
|
||||
font-family: monospace;
|
||||
}
|
||||
|
||||
.zl-card-info {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 0.75rem;
|
||||
color: #ccc;
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
padding: 4px 8px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.zl-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
gap: 4px;
|
||||
margin-top: 4px;
|
||||
}
|
||||
|
||||
/* Console output items */
|
||||
.console-line {
|
||||
margin-bottom: 4px;
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.console-time {
|
||||
color: var(--muted);
|
||||
}
|
||||
|
||||
.console-type {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.console-type.tx {
|
||||
color: var(--acid);
|
||||
}
|
||||
|
||||
.console-type.rx {
|
||||
color: #00aaff;
|
||||
}
|
||||
|
||||
.console-type.info {
|
||||
color: #ccc;
|
||||
}
|
||||
|
||||
.console-type.error {
|
||||
color: #ff3333;
|
||||
}
|
||||
|
||||
.console-type.success {
|
||||
color: #00ffa0;
|
||||
}
|
||||
|
||||
.console-target {
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.console-content pre {
|
||||
margin: 0;
|
||||
white-space: pre-wrap;
|
||||
font-family: inherit;
|
||||
}
|
||||
|
||||
.zl-log-line {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
/* Mobile Optimization */
|
||||
@media (max-width: 900px) {
|
||||
.zombieland-container.page-with-sidebar {
|
||||
height: auto;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.zombieland-container .zl-sidebar {
|
||||
width: 100%;
|
||||
max-height: none;
|
||||
flex-shrink: 0;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.zl-stats-grid {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
|
||||
.zl-toolbar {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.zl-main-grid {
|
||||
grid-template-columns: 1fr;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
.zl-console-panel {
|
||||
height: 350px;
|
||||
flex: none;
|
||||
}
|
||||
|
||||
.zl-agents-panel {
|
||||
height: 350px;
|
||||
flex: none;
|
||||
}
|
||||
|
||||
.zl-console-input-row {
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.zl-target-select,
|
||||
.zl-cmd-input {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.zl-card-header {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
gap: 4px;
|
||||
}
|
||||
|
||||
.zl-card-info {
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user