* feat(Finding): PRWLR-4987 add uid field to Findings
* feat(Scan): PRWLR-4987 implement logic to calculate Finding delta value
* test(Scan): PRWLR-4987 add unit tests for _create_finding_delta
* chore(Spec): PRWLR-4987 update API spec
* chore(Django-filter): PRWLR-4948 bump django-filter version to 24.3
* fix(Middleware): PRWLR-4948 fix logging middleware when auth is not present in request
* fix(Task): PRWLR-4948 fix serializer state values
* chore(Filters): PRWLR-4948 use ChoiceFilter instead of implementing method for basic filters
* chore(Filters): PRWLR-4948 refactor complex filters to reduce complexity
* feat(Findings): initial findings model
* fix(Findings): add view, serializers, migration for enums
* fix(Findings): incomplete jsonb_to_tsvector wrapper
will not run as written
* fix(Findings): use Severity and Status enums from prowler SDK
* tests(Findings): add failing view tests
* fix(Finding): add resource relationship
not returning correct data from serializer, missing links
* fix(FindingSerializer): get Scan & Resource relationships to show up
* fix(FindingFilter): add more filter fields
* fix(FindingFilter): filter on provider id
* fix(FindingSerializer): return Resource in relationship
not ResourceFindingMapping
* fix(FindingModel): update migration
* fix(FindingFilter): full text search on findings
* fix(Resources): include Findings in ResourceSerializer
* fix(FindingFilter): expand text search columns
* fix(DbUtils): docstring, not comment
* fix(BaseViews): remove TODO
comment not applicable right now
* fix(Fixtures): add more findings to fixture file
and change on_delete behavior for resource_finding_mapping
* fix(Resources): rename index to match others
* fix(Findings): update Findigns RLS to allow for full CRUD
eventually we'll let users enter a manual finding
which implies INSERT, UPDATE, DELETE
* fix(Findings): use TextChoices directly for Status enum
* fix(FindingSerializer): build a set instead of a list
* consistency in fixtures
Co-authored-by: Víctor Fernández Poyatos <victor@prowler.com>
* fix(API): update v1 spec for findings
* feat(Findings): store findings in a partitioned table
* fix(Settings): change unit of partition max age
to match unit when creating
* docs(Partitions): document how to manage partitions via manage.py
* fix(Findings): add tag for spec/docs
* fix(Findings): clean up migrations
* fix(Findings): convert scan_id and inserted_at filters into finding.id filters
* fix(Findings): add default filter for today
and set default sort order
* fix(Findings): add default filter for today
and set default sort order
* fix(Findings): update fixtures so datetime matches id
* fix(Findings): partition the ResourceFindingMapping table to match Findings
* docs(Partitions): document postgres config values more
* docs(UUIDUtils): do not use raw query strigns (typo)
* docs(Partitions): change unit in comment description
* fix(Findings): change resource_name & tags to be Finding
* docs(Partitions): change unit in partitions settings docstring
* fix(Findings): remove conflicting logic & filters
* chore: apply suggested changes
* chore: optimize imports
---------
Co-authored-by: Víctor Fernández Poyatos <victor@prowler.com>
* chore(deps): PRWLR-4014 include prowler library in python deps
* feat(Backend,API): PRWLR-4014 add AWS provider test_connection through celery tasks
* fix(Backend,API): PRWLR-4014 fix model handling in celery tasks
* test(Tasks): PRWLR-4014 add unit tests for celery tasks
* docs(API): PRWLR-4014 update endpoint tag
* feat(Backend): PRWLR-4014 add decorator for tenant dependant Celery tasks
* chore(Backend): PRWLR-4014 remove TODOs and improve docstrings
* feat(Backend): PRWLR-4014 replace timezone.now for datetime.now(timezone.utc)
* feat(Backend): PRWLR-4014 use SET LOCAL for api.tenant_id setting
* feat(Backend, Tasks): PRWLR-4014 refactor tasks module to abstract business logic
* fix(Backend): PRWLR-4014 use set_config for RLS config and set transaction at request dispatch level
* fix(Tasks): PRWLR-4014 fix tasks tenant decorator
* chore(Celery): add basic Celery worker with broker only
* chore(Celery): saving progress. Not able to schedule tasks
* fix(Celery): add celery app for use by django
* fix(Celery): register tasks
* fix(Docker): add celery workers to docker-compose
* chore(Celery): add django-celery-results backend
to store results using Django ORM
* fix(Celery): get app config the correct way
* fix(Docker): start connecting docker Celery workers to Valkey
not yet operational
* fix(Celery): get celery & django to work in docker-compose
* docs(Celery): document how to run Celery in development environment
includes changes to support the configuration and deployment
of Celery worker and its dependencies, Valkey and Postgres.
* fix(GHA): add valkey to CI services
* fix(GHA): add valkey to CI services
* fix(GHA): add valkey-cli ping to CI services
* fix(GHA): use right port for valkey
* fix(Views): remove debug task code
* test(Celery): start adding celery task tests
not yet working!
* fix(pyproject): rollback django upgrade
* fix(docker): updated docker runtime and env vars
based on feedback from #20
* fix(Dockerfile): include dependencies for psutil
psutil was introduced by pytest-celery
* fix(Backend): PRWLR-4013 fix celery settings structure
* fix(Celery): update celery app to work with new settings structure
* fix(Views): remove debug task code
* fix(Config): remove debug code
* fix(Celery): update celery app name when running worker
---------
Co-authored-by: Víctor Fernández Poyatos <victor@prowler.com>
* chore(CI): import pre-commit-config.yaml from prowler-cloud/prowler
* chore(CI): import pre-commit-config.yaml from prowler-cloud/prowler
* chore(CI): add safety package to pre-commit
* chore(CI): use poetry run to access venv for local checks
* docs(repo): add community focused docs
* chore(GitHub): add ISSUE_TEMPLATEs
same as prowler-cloud/prowler repo
* chore(CI): add pull-request.yml workflow
runs on PRs and pushes to main
* chore(CI): add additional workflows
same as those on prowler-cloud/prowler
* fix(CI): use correct path
* fix(API): fix flake8 F401 failures
* fix(API, Backend): format with black
* fix( Backend): format with black
* fix(CI): use correct path
* fix(CI): move pyproject.toml
* fix(CI): simplify tools with ruff
* fix(CI): use ruff instead of flake8, black
* fix(CI): change ruff commands for GHA
* fix(CI): use correct ruff command name
* fix(Backend): ruff format
* fix(CI): ignore safety jinja2 vuln id 70612
and add mypy for future usage
* fix(CI): set file path for hadolint
* fix(CI): add dockle
* fix(CI): update dockle version
* fix(CI): fix hadolint errors
* fix(CI): add simple tests for CI
* fix(Docker): multi-stage docker build
* docs(README): update docs for poetry location