Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 3 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ Provenance sidecars detect corruption; they do not authenticate an artifact,
because another process running as the same operating-system user can forge the
artifact and its digest. Production therefore keeps runtime code generation off.

- **`netbox-proxbox` 0.0.33 (paired release)** — the NetBox plugin that
- **`netbox-proxbox` 0.0.33.post1 (paired release)** — the NetBox plugin that
consumes this backend. Source:
<https://github.com/emersonfelipesp/netbox-proxbox>. The current release
pairing is `netbox-proxbox 0.0.33 ... proxbox-api 0.0.33rc1 ... proxmox-sdk 0.0.16.post1 ... netbox-sdk 0.0.13`.
pairing is `netbox-proxbox 0.0.33.post1 ... proxbox-api 0.0.33.post1 ... proxmox-sdk 0.0.16.post1 ... netbox-sdk 0.0.13`.
`proxbox-api 0.0.19` ships Proxmox SDN sync collectors, NetBox L2VPN,
RouteTarget, Prefix reconcile, plugin inventory reconciliation, and
VM-interface reconcile idempotency hardening. Operational-verb routes (start/stop/snapshot/migrate)
Expand Down Expand Up @@ -989,7 +989,7 @@ by installing a replacement package that bundles the updated schema.

## Certified Stack Pairing

Current release pairing: `netbox-proxbox 0.0.33 ... proxbox-api 0.0.33rc1 ... proxmox-sdk 0.0.16.post1 ... netbox-sdk 0.0.13`.
Current release pairing: `netbox-proxbox 0.0.33.post1 ... proxbox-api 0.0.33.post1 ... proxmox-sdk 0.0.16.post1 ... netbox-sdk 0.0.13`.

Proxmox node Device names use the effective endpoint/global
`node_device_name_template`. Keep the Proxmox short node name in API paths and
Expand Down
2 changes: 1 addition & 1 deletion contracts/mounted-operations.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion contracts/operation-inventory-integrity.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"mounted-operations.en.md":"34bbcde40a58c6ec9f3978aed0e79399ebc2ff4eef42f3700c73b8fa44e06945","mounted-operations.json":"338f4773e6e2df873591678e16eb01ed1ba116d9b7dc1c0f67e330f58f1ce397","mounted-operations.pt-BR.md":"fe33a3a42dcb7cb2b3287e9b767c03ffc8f281226420befe388c2f8072d7507c","mounted-operations.schema.json":"d057d4db7bdf781eb7b8c61179d8cf0181dda38915b564f0bf08fe189b0f72d8","operation-coverage.schema.json":"a6dd1f1ef48bb31ec37e5965904ded30dc4cb095d8c59f4f3020485bde38e598"}
{"mounted-operations.en.md":"34bbcde40a58c6ec9f3978aed0e79399ebc2ff4eef42f3700c73b8fa44e06945","mounted-operations.json":"8fb6df62a32b644f6816a48cc8cd9ea71523e7197b7461b08e2c188ead9fa15e","mounted-operations.pt-BR.md":"fe33a3a42dcb7cb2b3287e9b767c03ffc8f281226420befe388c2f8072d7507c","mounted-operations.schema.json":"d057d4db7bdf781eb7b8c61179d8cf0181dda38915b564f0bf08fe189b0f72d8","operation-coverage.schema.json":"a6dd1f1ef48bb31ec37e5965904ded30dc4cb095d8c59f4f3020485bde38e598"}
4 changes: 4 additions & 0 deletions docs/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ uv run mkdocs build
## Content Guidelines

- Keep English (`docs/`) and Portuguese (`docs/pt-BR/`) files in sync when updating content.
- The `0.0.33.post1` release notes cover the typed Proxmox ISO
download route (`POST /cloud/storage/download-url`) with its operator
hostname allowlist, and offline-node tolerance in node-interface sync. The
backend-first pairing is `netbox-proxbox 0.0.33.post1`.
- The `0.0.33` release notes cover stable Proxmox VE 9.3 guest UID
identity, node-scoped network-interface reconciliation, and LXC runtime DHCP
address synchronization. Keep the
Expand Down
57 changes: 57 additions & 0 deletions docs/pt-BR/release-notes/version-0.0.33.post1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# proxbox-api 0.0.33.post1

## Resumo

Esta pós-versão adiciona uma rota tipada e auditada que baixa uma imagem ISO para um storage do
Proxmox a partir de uma URL, equivalente à ação "Download from URL" do Proxmox. Ela também mantém a
sincronização de interfaces dos nós funcionando quando um nó de um cluster Proxmox está offline.

A versão não adiciona migração de banco de dados no backend. A versão pareada é
`netbox-proxbox 0.0.33.post1`, que contém a configuração `storage_download_allowed_hosts` lida
por esta rota. Implante este backend primeiro.

## Identidade da versão e compatibilidade

| Componente | Versão ou contrato |
| --- | --- |
| proxbox-api | `0.0.33.post1` |
| Proxmox SDK | `proxmox-sdk 0.0.16.post1` (inalterado) |
| NetBox SDK | `netbox-sdk 0.0.13` (inalterado) |
| Python | 3.12 e 3.13 |
| Migração de banco de dados do backend | Nenhuma |
| Plugin pareado | `netbox-proxbox 0.0.33.post1` |

## Rota tipada de download de ISO no Proxmox

`POST /cloud/storage/download-url` inicia um download de ISO no Proxmox, com verificação de
certificado, em um endpoint Proxmox persistido, e retorna o UPID da tarefa, o nó, o storage, o nome
do arquivo e o ID do volume resultante. O proxy Proxmox gerado em tempo de execução continua somente
leitura: o seu POST de `download-url` rejeitava todas as requisições, então esta rota tipada é a
forma suportada de iniciar um download.

- A requisição é validada de forma estrita: URL HTTPS absoluta sem credenciais e sem porta
diferente de 443, nome de arquivo `.iso` sem separadores de caminho ou `..`, checksum
hexadecimal em minúsculas com o tamanho correspondente a `sha256` ou `sha512`, e nenhum campo
extra.
- O controle de escrita do endpoint é aplicado.
- O hostname da URL deve constar exatamente na configuração `storage_download_allowed_hosts` do
`netbox-proxbox`. Uma lista vazia desativa os downloads. As configurações do plugin ficam em
cache por até cinco minutos, então a remoção de um host pode levar esse tempo para valer aqui.
- As faixas de SSRF configuradas são aplicadas, e o Proxmox sempre verifica o certificado da
origem.
- Os erros usam códigos de motivo estáveis (`download_host_not_allowed`,
`download_allowlist_unavailable`, `download_url_rejected`, `proxmox_session_unavailable`,
`proxmox_download_failed`, `proxmox_invalid_response`) com detalhe limitado e query string da URL
ocultada. O log de auditoria registra somente o host da URL.

A lista de hosts permitidos reduz, mas não elimina, a janela entre a validação da URL e o download
posterior feito pelo host Proxmox. Adicione somente hosts de fornecedores confiáveis sem
redirecionamentos abertos.

## Nós offline na sincronização de interfaces dos nós

Quando um membro de um cluster Proxmox estava offline, o Proxmox respondia à requisição de rede
desse nó com HTTP 595, e a etapa de interfaces de rede da atualização completa falhava para todos os
nós do cluster. A sincronização de interfaces agora ignora os nós que o status do cluster informa
como offline e registra um aviso estruturado `node_offline`, para que os demais nós, as interfaces
das VMs e os endereços IP dos convidados continuem sendo sincronizados. Contribuição da comunidade.
54 changes: 54 additions & 0 deletions docs/release-notes/version-0.0.33.post1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# proxbox-api 0.0.33.post1

## Summary

This post-release adds a typed, audited route that downloads an ISO image into Proxmox storage from
a URL, the equivalent of the Proxmox "Download from URL" action. It also keeps node-interface
synchronization running when one node of a Proxmox cluster is offline.

The release adds no backend database migration. The paired release is `netbox-proxbox 0.0.33.post1`,
which carries the `storage_download_allowed_hosts` plugin setting this route reads. Deploy this
backend first.

## Release identity and compatibility

| Component | Release or contract |
| --- | --- |
| proxbox-api | `0.0.33.post1` |
| Proxmox SDK | `proxmox-sdk 0.0.16.post1` (unchanged) |
| NetBox SDK | `netbox-sdk 0.0.13` (unchanged) |
| Python | 3.12 and 3.13 |
| Backend database migration | None |
| Companion plugin | `netbox-proxbox 0.0.33.post1` |

## Typed Proxmox ISO download route

`POST /cloud/storage/download-url` starts a certificate-verified Proxmox ISO download on one
persisted Proxmox endpoint and returns the Proxmox task UPID, node, storage, filename, and
resulting volume ID. The runtime-generated Proxmox proxy stays read-only: its `download-url` POST
rejected every request, so this typed route is the supported way to start a download.

- The request is validated strictly: an absolute HTTPS URL without userinfo and without a port
other than 443, an `.iso` filename without path separators or `..`, a lowercase hexadecimal
checksum whose length matches `sha256` or `sha512`, and no extra fields.
- The endpoint write gate applies.
- The URL hostname must appear exactly in the `storage_download_allowed_hosts` setting of
`netbox-proxbox`. An empty list disables downloads. Plugin settings are cached for up to five
minutes, so a removal from the list can take that long to apply here.
- The configured SSRF ranges apply, and Proxmox always verifies the source certificate.
- Errors use stable reason codes (`download_host_not_allowed`, `download_allowlist_unavailable`,
`download_url_rejected`, `proxmox_session_unavailable`, `proxmox_download_failed`,
`proxmox_invalid_response`) with bounded detail and redacted URL query strings. The audit log
records only the URL host.

The allowlist reduces, but does not remove, the time-of-check to time-of-use window between URL
validation and the later fetch by the Proxmox host. Add only trusted vendor hosts without open
redirects.

## Offline cluster nodes in node-interface synchronization

When one member of a Proxmox cluster was offline, Proxmox answered its node-network request with
HTTP 595, and the network-interfaces stage of a full update failed for every node in the cluster.
Node-interface synchronization now skips nodes that the cluster status reports as offline and
records a structured `node_offline` stage warning, so the remaining nodes, VM interfaces, and guest
IP addresses still synchronize. Contributed by the community.
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ markdown_extensions:
nav:
- Home: index.md
- Release Notes:
- Version 0.0.33.post1: release-notes/version-0.0.33.post1.md
- Version 0.0.33: release-notes/version-0.0.33.md
- Version 0.0.32: release-notes/version-0.0.32.md
- Version 0.0.31: release-notes/version-0.0.31.md
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ proxbox_api = ["static/*", "static/**/*", "generated/**/*.json", "generated/**/*

[project]
name = "proxbox_api"
version = "0.0.33"
version = "0.0.33.post1"
description = "Proxbox API service made using FastAPI"
readme = "README.md"
requires-python = ">=3.12,<3.14"
Expand Down
2 changes: 1 addition & 1 deletion tests/test_proxmox_sdk_dependency.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from packaging.version import Version

REPO_ROOT = Path(__file__).resolve().parents[1]
PROXBOX_API_VERSION = "0.0.33"
PROXBOX_API_VERSION = "0.0.33.post1"
RELEASE_NOTES_VERSION = "0.0.33"
PROXMOX_SDK_VERSION = "0.0.16.post1"
NETBOX_SDK_VERSION = "0.0.13"
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading