CluPilotCloud/tests
nexxo 272cfe45e8 Keep IP addresses out of a certificate overview
127.0.0.1 was in the list on the live server, marked as console, showing "no
valid certificate: Connection refused" in red. It came from ADMIN_HOSTS, where a
bare IP is deliberately allowed — it is the way back into the console when a
name does not resolve. My filter only asked for a dot, and 127.0.0.1 has three.

Let's Encrypt does not issue for IP addresses, so that row was permanently red
and nobody could ever fix it. A red line that cannot be acted on is worse than
no line: it teaches the reader to skip the colour, which is the one thing the
overview needs them not to do.

Two checks now, not one: the address test, and a last label that is not numeric.
A TLD is never a number, and that also catches the forms FILTER_VALIDATE_IP lets
through.

The row already in the database goes away on the next sync, because otherwise my
mistake would sit on every installation that has already updated. Vanished
config rows are handled by what they carry: one that never had a certificate was
a mistake and is deleted; one that HAS a live certificate becomes a manual entry
instead, so nothing with a running expiry disappears without the operator
deciding. That is a change of mind from the previous commit, which said config
rows are never removed — this case showed the cost of that rule where the row
should never have existed.

2043 tests pass.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-31 01:01:47 +02:00
..
Feature Keep IP addresses out of a certificate overview 2026-07-31 01:01:47 +02:00
Support Let a mailbox send without a password when it never needed one 2026-07-28 05:54:21 +02:00
Unit Say the same thing to the customer, the register and the bank 2026-07-30 01:30:24 +02:00
Pest.php Refuse the sale instead of reaching Stripe without a key 2026-07-30 11:58:01 +02:00
TestCase.php test: do not reach for Redis from the provisioning queue 2026-07-26 02:20:46 +02:00