Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
d4ddca0
Ajuste
AndreLorenz Dec 13, 2024
191a797
Ajustes
AndreLorenz Jan 24, 2025
3e7c00c
Merge tag '2.2.1' of https://github.com/EvolutionAPI/evolution-api
AndreLorenz Jan 24, 2025
d171b3e
Merge tag '2.2.2' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Jan 31, 2025
5c746b7
Merge tag '2.2.3' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Feb 3, 2025
3ef459c
Ajutes
AndreLorenz Feb 5, 2025
50af57c
Ajustar docker-compose
AndreLorenz Feb 5, 2025
78e3f4a
Atualizar baileys
AndreLorenz May 28, 2025
0eaa163
Merge tag '2.3.0' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Jul 1, 2025
0aec264
Ajsutes
AndreLorenz Jul 1, 2025
9b6dcd7
Ajuste
AndreLorenz Jul 2, 2025
7e572ce
Ajuste
AndreLorenz Jul 2, 2025
da8004e
Merge tag '2.3.1' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Sep 3, 2025
8bc8f9c
Merge tag '2.3.2' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Sep 3, 2025
396629c
Ajuste baileys
AndreLorenz Sep 3, 2025
a2b82d1
Merge tag '2.3.5' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Oct 16, 2025
45165f1
chore(uno): update
AndreLorenz Oct 16, 2025
d614b0d
chore(uno): update
AndreLorenz Oct 16, 2025
7a992f5
Merge tag '2.3.6' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Oct 21, 2025
f7352bd
chore(release): baileys
AndreLorenz Oct 21, 2025
a7f272c
chore(release): ajuste
AndreLorenz Oct 21, 2025
141fcf7
fix: adjust whatsapp cache
AndreLorenz Oct 29, 2025
419c933
fix: update baileys
AndreLorenz Nov 19, 2025
ec734af
Merge tag '2.3.7' of https://github.com/EvolutionAPI/evolution-api in…
AndreLorenz Jun 25, 2026
c539c0f
style: fix lint formatting issues
AndreLorenz Jun 25, 2026
56763fe
style: ajust patches
AndreLorenz Jul 3, 2026
1989bac
style: adjust cb:notification
AndreLorenz Jul 3, 2026
f768a39
Merge tag '2.3.8' into version/2.3.8
DiogoTravalha Dec 2, 2026
f329106
fix(sqs): use local credentials when DEV_QUEUE_URL is set
DiogoTravalha Dec 2, 2026
17d4997
fix(baileys): port status ack patch to rc13
DiogoTravalha Dec 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ RABBITMQ_EVENTS_TYPEBOT_CHANGE_STATUS=false

# SQS - Environment variables
SQS_ENABLED=false
SQS_GLOBAL_QUEUE_NAME=
SQS_ACCESS_KEY_ID=
SQS_SECRET_ACCESS_KEY=
SQS_ACCOUNT_ID=
Expand Down
34 changes: 34 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Debug Evolution API (dev:server)",
"runtimeExecutable": "npm",
"runtimeArgs": ["run", "dev:server"],
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"env": {
"NODE_OPTIONS": "--inspect"
},
"skipFiles": ["<node_internals>/**"],
"resolveSourceMapLocations": [
"${workspaceFolder}/**",
"!**/node_modules/**"
]
},
{
"type": "node",
"request": "attach",
"name": "Attach Evolution API (porta 9229)",
"port": 9229,
"restart": true,
"skipFiles": ["<node_internals>/**"],
"resolveSourceMapLocations": [
"${workspaceFolder}/**",
"!**/node_modules/**"
]
}
]
}
1 change: 1 addition & 0 deletions Docker/swarm/evolution_api_v2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ services:
- RABBITMQ_EVENTS_TYPEBOT_START=false
- RABBITMQ_EVENTS_TYPEBOT_CHANGE_STATUS=false
- SQS_ENABLED=false
- SQS_GLOBAL_QUEUE_NAME=
- SQS_ACCESS_KEY_ID=
- SQS_SECRET_ACCESS_KEY=
- SQS_ACCOUNT_ID=
Expand Down
16 changes: 13 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,30 @@
FROM node:24-alpine AS builder

# Instalar dependências incluindo openssh
RUN apk update && \
apk add --no-cache git ffmpeg wget curl bash openssl
apk add --no-cache git ffmpeg wget curl bash openssl openssh-client

LABEL version="2.3.1" description="Api to control whatsapp features through http requests."
LABEL maintainer="Davidson Gomes" git="https://github.com/DavidsonGomes"
LABEL contact="contato@evolution-api.com"

WORKDIR /evolution

# Configurar SSH para GitHub
RUN mkdir -p -m 0700 ~/.ssh && \
ssh-keyscan github.com >> ~/.ssh/known_hosts

# Montar a chave SSH durante o build (usando BuildKit)
RUN --mount=type=ssh,id=default \
git config --global url."git@github.com:".insteadOf https://github.com/

COPY ./package*.json ./
COPY ./patches ./patches
COPY ./tsconfig.json ./
COPY ./tsup.config.ts ./
COPY ./patches ./patches

RUN npm ci --silent
RUN --mount=type=ssh,id=default npm ci

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Medium · Build scripts can use SSH agent

When a dependency or its install script is malicious or compromised, a compromised dependency install script runs while the forwarded SSH agent is available and can authenticate to GitHub as the builder, accessing repositories permitted to that key. The builder’s private key is not extractable, but its access can be abused during the build.

Restrict the SSH mount to fetching the Git dependency, then run dependency lifecycle scripts without the agent mounted.

Prompt for AI agents
In `Dockerfile` at line 27:

**Build scripts can use SSH agent**

When a dependency or its install script is malicious or compromised, a compromised dependency install script runs while the forwarded SSH agent is available and can authenticate to GitHub as the builder, accessing repositories permitted to that key. The builder’s private key is not extractable, but its access can be abused during the build.

Restrict the SSH mount to fetching the Git dependency, then run dependency lifecycle scripts without the agent mounted.


COPY ./src ./src
COPY ./public ./public
Expand Down Expand Up @@ -58,4 +68,4 @@ ENV DOCKER_ENV=true

EXPOSE 8080

ENTRYPOINT ["/bin/bash", "-c", ". ./Docker/scripts/deploy_database.sh && npm run start:prod" ]
ENTRYPOINT ["/bin/bash", "-c", ". ./Docker/scripts/deploy_database.sh && npm run start:prod" ]
12 changes: 12 additions & 0 deletions UNO_DEPLOY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Para fazer o deploy

Deve fazer o login no ECR

# Dar permissão de execução (só precisa fazer uma vez)
chmod +x build.sh

# Build de teste
./build.sh uno/evolution-test

# Build de produção
./build.sh uno/evolution
40 changes: 40 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
#!/bin/bash

# Script para build do Docker com SSH Agent
# chmod +x build.sh
# Uso: ./build.sh <nome-da-imagem>
# Exemplo: ./build.sh uno/evolution-test
# Exemplo: ./build.sh uno/evolution

set -e # Parar em caso de erro

# Verificar se foi passado o nome da imagem
if [ -z "$1" ]; then
echo "❌ Erro: Você precisa especificar o nome da imagem!"
echo ""
echo "Uso: ./build.sh <nome-da-imagem>"
echo ""
echo "Exemplos:"
echo " ./build.sh uno/evolution-test"
echo " ./build.sh uno/evolution"
exit 1
fi

IMAGE_NAME=$1

echo "🔑 Iniciando SSH Agent..."
eval $(ssh-agent -s)

echo "🔐 Adicionando chave SSH (você precisará digitar a senha)..."
ssh-add ~/.ssh/id_ed25519

echo "🐳 Fazendo build da imagem: $IMAGE_NAME"
export DOCKER_BUILDKIT=1
docker build --ssh default -t "$IMAGE_NAME" .

echo "✅ Build concluído com sucesso!"
echo ""
echo "🧹 Limpando SSH Agent..."
ssh-agent -k

echo "🎉 Pronto! Imagem criada: $IMAGE_NAME"
43 changes: 13 additions & 30 deletions docker-compose.dev.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,18 @@
services:
api:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟠 High · Dev compose omits application services

When A developer starts the documented full development stack with docker-compose.dev.yaml, the development Compose file no longer defines the API or frontend, so the documented full-stack command starts only PostgreSQL and Redis; developers cannot use it to run the application and manager as before.

Keep the API and frontend services in the development Compose file, or update the documented workflow to start them separately.

Prompt for AI agents
In `docker-compose.dev.yaml` at line 2:

**Dev compose omits application services**

When A developer starts the documented full development stack with `docker-compose.dev.yaml`, the development Compose file no longer defines the API or frontend, so the documented full-stack command starts only PostgreSQL and Redis; developers cannot use it to run the application and manager as before.

Keep the API and frontend services in the development Compose file, or update the documented workflow to start them separately.

container_name: evolution_api
image: evolution/api:local
build: .
postgres:
image: postgres
restart: always
ports:
- 8080:8080
volumes:
- evolution_instances:/evolution/instances
networks:
- evolution-net
env_file:
- .env
expose:
- 8080

frontend:
container_name: evolution_frontend
image: evolution/manager:local
build: ./evolution-manager-v2
- '5438:5432'
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=andand123
Comment on lines +6 to +9

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Medium · Dev database exposed with weak credentials

When a developer runs this compose file on a host reachable from an untrusted network, postgreSQL publishes port 5432 on the host’s default interfaces and accepts the fixed postgres/andand123 credentials, so a network attacker can connect and read or modify the development database.

Bind the published port to loopback for local development and require a strong, externally supplied password.

Prompt for AI agents
In `docker-compose.dev.yaml` at lines 6-9:

**Dev database exposed with weak credentials**

When a developer runs this compose file on a host reachable from an untrusted network, postgreSQL publishes port 5432 on the host’s default interfaces and accepts the fixed `postgres`/`andand123` credentials, so a network attacker can connect and read or modify the development database.

Bind the published port to loopback for local development and require a strong, externally supplied password.


redis:
image: redis:latest
restart: always
container_name: redis
command: >
redis-server --port 6379 --appendonly yes
ports:
- "3000:80"
networks:
- evolution-net

volumes:
evolution_instances:


networks:
evolution-net:
name: evolution-net
driver: bridge
- 6379:6379
1 change: 0 additions & 1 deletion evolution-manager-v2
Submodule evolution-manager-v2 deleted from 3137df
Loading