- shared/platform-tools: ea3616a → 12f26fd (27 commits). Traz o módulo de audit (f761d99, o pin da frota), «manter sessão iniciada», o registo de segurança da frota (o gancho que o login já tinha passa a funcionar) e a correção do IP do cliente encontrada nesta auditoria (último X-Forwarded-For / X-Real-IP), promovida ao partilhado. client_ip() da app delega nele. - config/functions_audit.php: audit() sobre platform_audit(); tabela audit_log criada no primeiro uso, segredos ocultados, nunca parte a ação. - Registado: login, falha de login, bloqueio por excesso de tentativas, logout, pedidos de recuperação, mudança/definição de palavra-passe, registo e criação de utilizadores, convites, perfil (antes/depois), todas as definições (db_update_setting, com valor anterior), cada passo da lixeira (apagar, restaurar, eliminar de vez) e ações nas mensagens. - Sistema → Auditoria (views/sysadmin/audit.php), só sysadmin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2.1 KiB
platform-tools is vendored here, not a submodule
This directory used to be a git submodule pointing at
git.andmore.pt/andre/platform-tools. On the main branch it is a plain
directory of tracked files.
Frozen at: 12f26fd1cba8ce3229c598ac2f2e9a788cd7cf75 (fix(client_ip): X-Real-IP / último X-Forwarded-For, nunca o primeiro)
— refreshed on 2026-09-25 from ea3616a, 27 commits later. It is the fleet
pin (f761d99, audit module) plus a8c681b (login form pieces, remember
options) and the client-IP fix found in this app's audit.
History: ea3616a (2026-09-13, same pin as fotografia at the time) →
12f26fd (2026-09-25).
Why
The submodule was the single biggest source of deployment failures on this install:
.gitmodulesnamed nobranch, so "Atualizar submódulo" fell back torefs/remotes/origin/HEAD, a ref a plain server-side clone never creates. It failed withUnable to find refs/remotes/origin/HEAD revision.- Its URL used
http://, which the origin answers with 523. - The site is deployed by uploading files. A submodule is invisible to that:
the rest of the tree moved forward while
shared/platform-toolsstayed on an old commit, andconfig/functions_secrets.phpthen died on a missingcompat_secrets.php— taking every page, public ones included, down with it.
A plain directory deploys like every other file. There is no second repository to be out of step with the first.
The trade-off
Fixes to platform-tools no longer arrive by bumping a pin. To take an update:
- Clone or pull
platform-toolssomewhere separate. - Check out the commit you want.
- Copy its files over this directory (delete removed ones).
- Update the SHA above, and commit here with that SHA in the message.
Keep recording the upstream SHA. It is the only thing that makes "which version is this?" answerable.
Note on line endings
social/engine.js, social/functions_publications.php, social/page.js and
social/publications.css are stored upstream with CRLF. They were normalised to
LF when vendored. The content is otherwise byte-identical; diff with
tr -d '\r' to compare against upstream.