-
-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* `refactor: Add IoC and AlertToIoC models` * `refactor: Add IoC and AlertToIoC models` * `refactor: delete ioc from alert` * `refactor: Add IoC collection to list alerts` * `refactor: Add IoC collection to list alerts` * `feat: Add IoC filtering to list alerts` * chore: update dependencies in frontend * feat: add alert iocs list and creation form * feat: add CollapseKeepAlive component * refactor: incident list * feat: improved ioc form validation * feat: add ioc filter on alerts list * `refactor: Update connector IDs for Huntress integration` * precommit fixes --------- Co-authored-by: Davide Di Modica <[email protected]>
- Loading branch information
1 parent
956dd25
commit 73ac945
Showing
23 changed files
with
1,489 additions
and
748 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,6 +31,7 @@ | |
"hoverable", | ||
"iconoir", | ||
"Indicies", | ||
"iocs", | ||
"lastupdate", | ||
"linebreak", | ||
"Logsource", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
backend/alembic/versions/33e4754d845b_add_ioc_table_for_alerts.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
"""Add ioc table for alerts | ||
Revision ID: 33e4754d845b | ||
Revises: a1e4beb87498 | ||
Create Date: 2024-10-30 15:16:50.509086 | ||
""" | ||
from typing import Sequence | ||
from typing import Union | ||
|
||
import sqlalchemy as sa | ||
|
||
from alembic import op | ||
|
||
# revision identifiers, used by Alembic. | ||
revision: str = "33e4754d845b" | ||
down_revision: Union[str, None] = "a1e4beb87498" | ||
branch_labels: Union[str, Sequence[str], None] = None | ||
depends_on: Union[str, Sequence[str], None] = None | ||
|
||
|
||
def upgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
op.create_table( | ||
"incident_management_ioc", | ||
sa.Column("id", sa.Integer(), nullable=False), | ||
sa.Column("value", sa.String(length=250), nullable=False), | ||
sa.Column("type", sa.String(length=50), nullable=False), | ||
sa.Column("description", sa.String(length=10000), nullable=True), | ||
sa.PrimaryKeyConstraint("id"), | ||
) | ||
op.create_table( | ||
"incident_management_alert_to_ioc", | ||
sa.Column("alert_id", sa.Integer(), nullable=False), | ||
sa.Column("ioc_id", sa.Integer(), nullable=False), | ||
sa.ForeignKeyConstraint( | ||
["alert_id"], | ||
["incident_management_alert.id"], | ||
), | ||
sa.ForeignKeyConstraint( | ||
["ioc_id"], | ||
["incident_management_ioc.id"], | ||
), | ||
sa.PrimaryKeyConstraint("alert_id", "ioc_id"), | ||
) | ||
# ### end Alembic commands ### | ||
|
||
|
||
def downgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
op.drop_table("incident_management_alert_to_ioc") | ||
op.drop_table("incident_management_ioc") | ||
# ### end Alembic commands ### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.