ctest: Restore Nightly tag calculation

Use YYYY-MM-DD for nightly start dates and handle parse failures
before doing date arithmetic. Verify the configured time in the tag.

libarchive commit `422aae80ae` (Date parsing: reject date components
with numbers of more than 4 digits, 2026-05-07), backported to version
3.8.8 by libarchive commit `8cf7393f98` (Merge pull request `#3010`...,
2026-05-07, `v3.8.8~142`), disallows our previous non-standard
hyphen-free date format.

Fixes: #28314
7 files changed