-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into PRWLR-5506-microsoft-365-realease-version-…
…1-documentation
- Loading branch information
Showing
2,115 changed files
with
131,331 additions
and
15,137 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 |
---|---|---|
@@ -0,0 +1,94 @@ | ||
#### Important Note #### | ||
# This file is used to store environment variables for the Prowler App. | ||
# For production, it is recommended to use a secure method to store these variables and change the default secret keys. | ||
|
||
#### Prowler UI Configuration #### | ||
PROWLER_UI_VERSION="latest" | ||
SITE_URL=http://localhost:3000 | ||
API_BASE_URL=http://prowler-api:8080/api/v1 | ||
NEXT_PUBLIC_API_DOCS_URL=http://prowler-api:8080/api/v1/docs | ||
AUTH_TRUST_HOST=true | ||
UI_PORT=3000 | ||
# openssl rand -base64 32 | ||
AUTH_SECRET="N/c6mnaS5+SWq81+819OrzQZlmx1Vxtp/orjttJSmw8=" | ||
|
||
#### Prowler API Configuration #### | ||
PROWLER_API_VERSION="stable" | ||
# PostgreSQL settings | ||
# If running Django and celery on host, use 'localhost', else use 'postgres-db' | ||
POSTGRES_HOST=postgres-db | ||
POSTGRES_PORT=5432 | ||
POSTGRES_ADMIN_USER=prowler_admin | ||
POSTGRES_ADMIN_PASSWORD=postgres | ||
POSTGRES_USER=prowler | ||
POSTGRES_PASSWORD=postgres | ||
POSTGRES_DB=prowler_db | ||
|
||
# Valkey settings | ||
# If running Valkey and celery on host, use localhost, else use 'valkey' | ||
VALKEY_HOST=valkey | ||
VALKEY_PORT=6379 | ||
VALKEY_DB=0 | ||
|
||
# Django settings | ||
DJANGO_ALLOWED_HOSTS=localhost,127.0.0.1,prowler-api | ||
DJANGO_BIND_ADDRESS=0.0.0.0 | ||
DJANGO_PORT=8080 | ||
DJANGO_DEBUG=False | ||
DJANGO_SETTINGS_MODULE=config.django.production | ||
# Select one of [ndjson|human_readable] | ||
DJANGO_LOGGING_FORMATTER=human_readable | ||
# Select one of [DEBUG|INFO|WARNING|ERROR|CRITICAL] | ||
# Applies to both Django and Celery Workers | ||
DJANGO_LOGGING_LEVEL=INFO | ||
# Defaults to the maximum available based on CPU cores if not set. | ||
DJANGO_WORKERS=4 | ||
# Token lifetime is in minutes | ||
DJANGO_ACCESS_TOKEN_LIFETIME=30 | ||
# Token lifetime is in minutes | ||
DJANGO_REFRESH_TOKEN_LIFETIME=1440 | ||
DJANGO_CACHE_MAX_AGE=3600 | ||
DJANGO_STALE_WHILE_REVALIDATE=60 | ||
DJANGO_MANAGE_DB_PARTITIONS=True | ||
# openssl genrsa -out private.pem 2048 | ||
DJANGO_TOKEN_SIGNING_KEY="-----BEGIN PRIVATE KEY----- | ||
MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQDs4e+kt7SnUJek | ||
6V5r9zMGzXCoU5qnChfPiqu+BgANyawz+MyVZPs6RCRfeo6tlCknPQtOziyXYM2I | ||
7X+qckmuzsjqp8+u+o1mw3VvUuJew5k2SQLPYwsiTzuFNVJEOgRo3hywGiGwS2iv | ||
/5nh2QAl7fq2qLqZEXQa5+/xJlQggS1CYxOJgggvLyra50QZlBvPve/AxKJ/EV/Q | ||
irWTZU5lLNI8sH2iZR05vQeBsxZ0dCnGMT+vGl+cGkqrvzQzKsYbDmabMcfTYhYi | ||
78fpv6A4uharJFHayypYBjE39PwhMyyeycrNXlpm1jpq+03HgmDuDMHydk1tNwuT | ||
nEC7m7iNAgMBAAECggEAA2m48nJcJbn9SVi8bclMwKkWmbJErOnyEGEy2sTK3Of+ | ||
NWx9BB0FmqAPNxn0ss8K7cANKOhDD7ZLF9E2MO4/HgfoMKtUzHRbM7MWvtEepldi | ||
nnvcUMEgULD8Dk4HnqiIVjt3BdmGiTv46OpBnRWrkSBV56pUL+7msZmMZTjUZvh2 | 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8AqnRjf5R+lyzPqTZCXXb8KTcRvWT4zQa3 | ||
VxyT2PnaSqEcexWUy4+UXoQ= | ||
-----END PRIVATE KEY-----" | ||
# openssl rsa -in private.pem -pubout -out public.pem | ||
DJANGO_TOKEN_VERIFYING_KEY="-----BEGIN PUBLIC KEY----- | ||
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA7OHvpLe0p1CXpOlea/cz | ||
Bs1wqFOapwoXz4qrvgYADcmsM/jMlWT7OkQkX3qOrZQpJz0LTs4sl2DNiO1/qnJJ | ||
rs7I6qfPrvqNZsN1b1LiXsOZNkkCz2MLIk87hTVSRDoEaN4csBohsEtor/+Z4dkA | ||
Je36tqi6mRF0Gufv8SZUIIEtQmMTiYIILy8q2udEGZQbz73vwMSifxFf0Iq1k2VO | ||
ZSzSPLB9omUdOb0HgbMWdHQpxjE/rxpfnBpKq780MyrGGw5mmzHH02IWIu/H6b+g | ||
OLoWqyRR2ssqWAYxN/T8ITMsnsnKzV5aZtY6avtNx4Jg7gzB8nZNbTcLk5xAu5u4 | ||
jQIDAQAB | ||
-----END PUBLIC KEY-----" | ||
# openssl rand -base64 32 | ||
DJANGO_SECRETS_ENCRYPTION_KEY="oE/ltOhp/n1TdbHjVmzcjDPLcLA41CVI/4Rk+UB5ESc=" | ||
DJANGO_BROKER_VISIBILITY_TIMEOUT=86400 |
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 |
---|---|---|
@@ -1,5 +1,6 @@ | ||
* @prowler-cloud/sdk @prowler-cloud/detection-and-remediation | ||
|
||
# To protect a repository fully against unauthorized changes, you also need to define an owner for the CODEOWNERS file itself. | ||
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners#codeowners-and-branch-protection | ||
/* @prowler-cloud/sdk | ||
/.github/ @prowler-cloud/sdk | ||
prowler @prowler-cloud/sdk @prowler-cloud/detection-and-remediation | ||
tests @prowler-cloud/sdk @prowler-cloud/detection-and-remediation | ||
api @prowler-cloud/api | ||
ui @prowler-cloud/ui |
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,3 @@ | ||
name: "API - CodeQL Config" | ||
paths: | ||
- "api/" |
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,4 @@ | ||
name: "SDK - CodeQL Config" | ||
paths-ignore: | ||
- "api/" | ||
- "ui/" |
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,3 @@ | ||
name: "UI - CodeQL Config" | ||
paths: | ||
- "ui/" |
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
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,98 @@ | ||
name: API - Build and Push containers | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
paths: | ||
- "api/**" | ||
- ".github/workflows/api-build-lint-push-containers.yml" | ||
|
||
# Uncomment the code below to test this action on PRs | ||
# pull_request: | ||
# branches: | ||
# - "master" | ||
# paths: | ||
# - "api/**" | ||
# - ".github/workflows/api-build-lint-push-containers.yml" | ||
|
||
release: | ||
types: [published] | ||
|
||
env: | ||
# Tags | ||
LATEST_TAG: latest | ||
RELEASE_TAG: ${{ github.event.release.tag_name }} | ||
STABLE_TAG: stable | ||
|
||
WORKING_DIRECTORY: ./api | ||
|
||
# Container Registries | ||
PROWLERCLOUD_DOCKERHUB_REPOSITORY: prowlercloud | ||
PROWLERCLOUD_DOCKERHUB_IMAGE: prowler-api | ||
|
||
jobs: | ||
repository-check: | ||
name: Repository check | ||
runs-on: ubuntu-latest | ||
outputs: | ||
is_repo: ${{ steps.repository_check.outputs.is_repo }} | ||
steps: | ||
- name: Repository check | ||
id: repository_check | ||
working-directory: /tmp | ||
run: | | ||
if [[ ${{ github.repository }} == "prowler-cloud/prowler" ]] | ||
then | ||
echo "is_repo=true" >> "${GITHUB_OUTPUT}" | ||
else | ||
echo "This action only runs for prowler-cloud/prowler" | ||
echo "is_repo=false" >> "${GITHUB_OUTPUT}" | ||
fi | ||
# Build Prowler OSS container | ||
container-build-push: | ||
needs: repository-check | ||
if: needs.repository-check.outputs.is_repo == 'true' | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ${{ env.WORKING_DIRECTORY }} | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Login to DockerHub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Build and push container image (latest) | ||
# Comment the following line for testing | ||
if: github.event_name == 'push' | ||
uses: docker/build-push-action@v6 | ||
with: | ||
context: ${{ env.WORKING_DIRECTORY }} | ||
# Set push: false for testing | ||
push: true | ||
tags: | | ||
${{ env.PROWLERCLOUD_DOCKERHUB_REPOSITORY }}/${{ env.PROWLERCLOUD_DOCKERHUB_IMAGE }}:${{ env.LATEST_TAG }} | ||
cache-from: type=gha | ||
cache-to: type=gha,mode=max | ||
|
||
- name: Build and push container image (release) | ||
if: github.event_name == 'release' | ||
uses: docker/build-push-action@v6 | ||
with: | ||
context: ${{ env.WORKING_DIRECTORY }} | ||
push: true | ||
tags: | | ||
${{ env.PROWLERCLOUD_DOCKERHUB_REPOSITORY }}/${{ env.PROWLERCLOUD_DOCKERHUB_IMAGE }}:${{ env.RELEASE_TAG }} | ||
${{ env.PROWLERCLOUD_DOCKERHUB_REPOSITORY }}/${{ env.PROWLERCLOUD_DOCKERHUB_IMAGE }}:${{ env.STABLE_TAG }} | ||
cache-from: type=gha | ||
cache-to: type=gha,mode=max |
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.