Repository navigation
Stable Release PR For 1.6.0.158 - 2026-11-11 - #2093
Merged
Merged
Conversation
Ports the identity half of #2025 (Mikage Mashiro): MachineIdentity, the enroll route's directory-join-target-v1 feature request, the GET /agent/v1/enroll feature probe, and POST /agent/v1/identity/check, with the OpenAPI document and route permissions for them. The target operation feature, rejoin and name fence are left for later pull requests. Two fixes to the ported code: - A refused enroll request no longer writes the stored row. The route is public, so the old upgrade_blocked write let anyone who knew a key's fingerprint block that agent for good. The 409 is thrown with no save, and the now-dead upgrade_blocked marker handling is removed. Route:: agentEnroll now catches the RuntimeException and answers with its code and a reason body. - identity/check returns host_id only when the identity matched. On a mismatch it was the resolved host, which told an enrolled agent which host owned the values it sent. The cancel-route test's shared-error-map check is bounded to _errorResponses(), since the enroll path now documents its own 409 (same change as #2025). Route.php changes without a Route-generic spec change: the new routes are documented by hand in OpenAPI::_fixedPaths-style entries. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 1cf6fcb)
Give MachineIdentity the full PHPDoc header and method docblocks. Build the agentFeatures header and body from MachineIdentity::FEATURE. Rename the stored enrollment marker from _mj1 to _directoryIdentity. Drop the security override from the new OpenAPI operations so they match their agent siblings. Skip the legacy resolver on first contact when the feature is requested, and spell the reason out as an if/elseif chain. Update the route comment for the two new routes. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 70ccd19)
The OpenAPI test read only the constant, so a handler that stopped using MachineIdentity::FEATURE still passed. It now reads the handler source again and requires the header to be built from the constant. The comment above the agent routes still said "the other two are the admin's side of it", which no longer described the routes below it. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit b14ca60)
Ported from #2025 (schema step, schema-expected columns, route column contract, FOG_SCHEMA bump). Changed from #2025: only the two hostDirectory ALTERs are here. The directoryPlacementIntent table and its columns move to a later change. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 018f578)
Ported from #2025: HostDirectory::save() strips the two rejoin columns so a facts or placement save cannot overwrite a claimed operation; the agentrejoinstart permission entry; the Agent class table entries; and the FOGLdap domainContext/computerRecord lookups with their tests. Changed from #2025: hostdirectory hostID, rejoinConfig and rejoinState are listed in Route::$serverOwnedFields so a generic edit cannot write them. domainContext takes no naming-contexts flag and moveTo is untouched; those belong to the placement change. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit b149bd1)
Ported from #2025: DirectoryTask, DirectoryOperation and DirectoryRejoin with their pure tests. Changed from #2025: the global name fence and its session bookkeeping are gone. DirectoryRejoin::change() opens a plain transaction and refuses to nest. connection() refuses to run LDAP inside a transaction. The claim calls the new DirectoryOperation::assertNoOverlap(), which checks other hosts' in-flight footprints and GUID/SID inside the claim transaction and skips (and logs) an unreadable row instead of blocking every host. Host name comparisons use the column collation. blocked() skips the locked write when the reason is unchanged. beforePoll() returns early for a host with directory membership off. The per-call InnoDB engine probes are removed. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 8a8e34c)
Ported from #2025: the beforePoll call, the directory_rejoin, directory_check and directory_hold poll fields, POST /agent/v1/directory/rejoin/start, DirectoryJoin::rejoinCredential() and the attempt_id branch of report(), the placement hold in DirectoryJoin, and the hold gate at the top of DirectoryPlacement::ensure(). Changed from #2025: the feature probe lists both directory-join-target-v1 and directory-task-operations-v1. A host with directory membership off is never observed or noted as blocked, so a poll creates no hostDirectory row and takes no row lock. An unreadable state answers directory_hold true instead of failing the poll, and an unreadable DirectoryJoin state returns no join. DirectoryPlacement keeps its existing placement body and cooldown and drops the fence refusal and the intent dispatch. Wire shapes are unchanged. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 157c0e6)
Ported from #2025: the host Active Directory tab (allow-create, target confirmation, retry, status and history) and its POST handling, with the host AD test. Changed from #2025: target inspection is a POST that checks auth and CSRF instead of a GET link, answered before the edit save path; the candidate block is built by rejoinCandidateHtml(). All output goes through Initiator::e and the new POST reads use filter_input. An unreadable stored state no longer breaks the tab. New: DirectoryRejoin::protectedHosts() and Route::deletemass() refuse to delete a host with an operation in progress or awaiting review (409). DirectoryRejoin::clearReview() lets an operator record a decision for such a host, including one whose row cannot be decoded; it keeps the deploy task counters so the same task is not consumed again, and is audited as host.directory.review_cleared. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit db3f060)
Ported from #2025: the POST /agent/v1/directory/rejoin/start operation, the poll directory_check, directory_rejoin and directory_hold response fields, the poll features, directory_attempt and directory_observation request fields, the result task_id and netbios, and the tests that pin them. Changed from #2025: the enrollment feature probe lists both features in its JSON body as well as its header, and the probe handler keeps a literal header so the OpenAPI example stays tied to it. The enroll and identity/check parts stay as the identity change documents them. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit a17c5e5)
Ported from #2025: the bootstrap, operation, local-marker, retry-protection, verification, UI-save, transaction-crash and claim-race tests, with their fixtures. Each reads FOG_TEST_DSN, skips without it, and works only in the scratch database fog_directory_test. Changed from #2025: the fence cases are gone, the tests build their database from tests/lib/directory-db.php, and the claim-race and transaction-crash tests probe row locks instead of GET_LOCK. The report test keeps the report-transaction cases only. New: review-clear (delete guard and clearReview), bad-row isolation, AD-off poll (no row, no locking read) and deadlock. DirectoryRejoin::change() now answers InnoDB 1213 with rejoin_deadlock_retry and MariaDB 1020 (snapshot isolation) with rejoin_plan_changed, both 409. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 5cdb471)
DirectoryRejoin::beforePoll() no longer answers 409 to a poll that declares no directory features. The agent sends one whenever its feature probe or identity check fails, and the 409 stopped that host's whole poll. Such a poll now returns without planning, claiming or writing, so a pending operation waits. The 409 stays for a poll that declares the task feature without the identity feature. The agentenrollment marker lookup is deleted. change() and clearReview() roll back without inTransaction(), which PHPStan reads as always false. The DB tests read the globals directory-db.php leaves, and the structural findings left are baselined with exact counts. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 88c218c)
Document the rejoin classes, the /agent/v1/result item fields, status values and 409 body; drop the 503 from rejoin/start. Remove the legacy branches, the unused TaskType import, TERMINAL and the test-only deploy(). plan() uses the stricter validName once. The Inspect button disables during its request and reports a failure. Rewrite the observation and placement DB test against a real server with the real poll route. Add the rename-claim, review-clear plan, bad-row plan/poll and deadlock-mapping checks, and drop the baseline entries that only repeated an implied clause. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit ffd3f27)
…409s configure() had become a pass-through to the private configureTarget(), so the body moves into configure() and the tests call it directly. It returns nothing, and its docblock now says so. The 409 description on /agent/v1/result read as a complete list. A directory outage, a lookup error, a concurrent change and an unreadable stored state also answer 409 there, so it now names those too. Also removes an orphaned one-line docblock above plan() and restores the spaces after two assignments. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit e631eb9)
One row per computer object FOG has asked the directory to move, keyed by GUID. It records PREPARED, MAY_HAVE_RUN, SUCCEEDED, UNKNOWN or CANCELED, so a Move that may have reached the directory is never sent again. dpiStatus and dpiHash use utf8mb3_bin so they compare byte for byte. The table has no foreign key to hosts. The rows are history and outlive the host, so the constraint map classes dpiHostID as audit. The relationship counts in ADR 0031 and foreign-keys.md move from 143 to 144. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit ee28b7a)
DirectoryPlacementIntent keeps one row per computer object, keyed by GUID. ensure() writes the row PREPARED, takes the right to send by moving it to MAY_HAVE_RUN in a committed transaction, sends the Move outside any transaction, then stores SUCCEEDED or UNKNOWN. Nothing re-sends a row that may have run. There is no fence: each step takes its own row locks in the order hosts, hostDirectory, directoryPlacementIntent. A PREPARED row whose owner snapshot is stale is canceled by the next prepare. A config change and a native claim cancel PREPARED rows inside their own transactions, and a claim that meets a row that may have run is refused. A host with such a row cannot be deleted until an operator clears an UNKNOWN row on the Active Directory tab. FOGLdap gains the placement lookups (namingContexts, GUID DN, container identity) and reports what a Move learned about its request. moveTo() takes the RDN as a third argument because a GUID DN has none to read. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit da4fe79)
The intent table is utf8mb3, which cannot hold a 4-byte character, so an OU name with one made prepare() fail with error 1366. The payload and the result record are now ASCII-escaped JSON. moveTo() with a GUID DN has no RDN to read from the name. It now refuses that call instead of sending the GUID string as the RDN. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 1663499)
DB tests (scratch MariaDB, skipped without FOG_TEST_DSN) cover the schema, the intent lifecycle, the result format, the whole placement flow, the native-operation order, operator review and clear, a dispatch race across processes, and a real InnoDB deadlock on the result write. Two network-free tests cover the GUID DN and placement context, and a Move by GUID through a fake LDAP transport. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit f80c0d9)
Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 53bf0f7)
A crashed worker left its request MAY_HAVE_RUN, which protected the host from deletion forever. clearIntentReview() now accepts MAY_HAVE_RUN as well as UNKNOWN and records either as CANCELED. It keeps the same guards: the row is locked, the expected GUID must match, and the audit text names the status that was cleared. A worker that calls finish() on a cleared row loses its CAS. The host page warns that the move may have run or may still be running, and that clearing undoes nothing. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 2f74964)
…ar window, dedupe - OpenAPI: the directory/start 409 names directory_placement_target_protected. - DirectoryPlacementIntent: single-underscore private methods; status lists built from ACTIVE; one _cas() and one _projectDn() helper; why-comments restored in ensure(). - FOGLdap: guidBytes() shared with guidDN(); findComputer() removed (no caller left); moves bound by LDAP_OPT_TIMEOUT (MOVE_TIMEOUT). - A MAY_HAVE_RUN row younger than ten minutes (DB clock) cannot be cleared (directory_placement_move_may_be_running); UI text updated. - HostManagement: read the first pending move directly, log a fault, use an import. - DirectoryRejoin::protectedState is private again. - Schema 448: dpiHostID is int(11) to match hostID. - Tests: the LDAP stub calls the real FOGLdap helpers; the raw-DSN probe in optional-columns-carry-defaults is gone; new fresh-MAY_HAVE_RUN test. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> (cherry picked from commit 546d1c5)
- A Move that times out records UNKNOWN, but the directory can still apply it. clearIntentReview now holds UNKNOWN as well as MAY_HAVE_RUN for CLEAR_REVIEW_AFTER (renamed from CLEAR_MAY_HAVE_RUN_AFTER). - A NULL age (zero-date dpiUpdated) counts as old, so a bad row cannot block the clear forever. - REVIEW constant and _statusList() replace the three inline MAY_HAVE_RUN/UNKNOWN lists; ACTIVE uses the same helper. - The UI text takes the window from the constant; the fault log keeps the exception message. - Tests: fresh UNKNOWN refused, zero-date row clears, no column has a default, reuse intentFixtureBytes(), comma spacing. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit ae38c75)
- The UI text takes its minute count through ngettext(), as FOGCore does. - The CLEAR_REVIEW_AFTER docblock no longer repeats the value. - The review test asserts that a zero-date row reads back as a NULL age, so the zero-date clear proves the NULL branch on every CI database. Co-authored-by: Mikage Mashiro <mashiro@midchilda.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit feed142)
The cherry-picks left the agentFeatures literal and its test from an intermediate step. Use the MachineIdentity and DirectoryOperation FEATURE constants, as working-1.6 does.
merge stable - 1.6.0.14 into dev
fogupdater.sh mapped the Beta channel to a hardcoded working-1.6. FOG 1.6.0 is released, so working-1.6 is frozen and will be deleted. A Beta server would then fetch a branch that is gone, or a frozen one. Beta now asks GitHub for refs/heads/working-* over https and takes the newest by version sort (same anchoring and sort -Vr as newestBranch in lib/common/functions.sh). It is a local copy because newestBranch asks the checkout's origin, while this script always downloads from GitHub over https. When no working-* branch exists, the update stops with exit 10. When the remote cannot be reached, it stops with exit 11. It never falls through to stable or dev-branch. updatebranch in .fogsettings still wins. Tests stub git with real ls-remote output and cover the newest pick, version order, the feat/ and zz/ anchoring, the two stops, and the updatebranch override. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
- newestBranch() takes an optional remote URL as its second argument. Callers that pass none keep the origin lookup unchanged. - fogupdater.sh calls newestBranch with GitHub's https URL and the local copy is removed. - With an explicit remote the lookup runs with GIT_ALLOW_PROTOCOL=https and a low-speed bound, so a stalled network cannot hang an unattended update. The origin path is not restricted. - The branch name accepts only [0-9A-Za-z._-] after the prefix, because it is put into raw.githubusercontent.com and archive URLs; # and % are legal in a ref and would cut or alter them. - The Beta path stops with exit 12 when git is missing, instead of reporting the remote as unreachable. - Tests record the git environment and pin it, cover the missing git and the # and % heads. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
bin/bootstrap.sh keeps its own newestBranch, because it runs before there is a checkout to source functions.sh from. Its sed still accepted any character but / after the prefix. A git ref may hold # or %, so a branch such as working-1.99#x would be offered. It now accepts only [0-9A-Za-z._-], the same as lib/common/functions.sh. The test publishes working-1.99#x and rc-1.6.99%2F, which sort highest, and checks that neither is offered. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- newestBranch: the explicit-remote restrictions move to a function-scoped `local -x`, so one ls-remote call serves both the explicit and the origin path. - The fogupdater test ran the Beta lookup twice and read one run. It now runs once and checks the arguments and the environment of that run. - The git stub reads the environment through env(1). The real git is a child process and sees only exported variables, so a restriction that is set but not exported now fails the test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- The git stub reads each variable with printenv(1), which sees only the exported environment, in one process. - The suite unsets the three GIT_* variables before the checks, so a harness that exports them cannot make a missing restriction pass. - A new check runs an explicit lookup and then an origin-path lookup in the same shell. The origin path must see no restriction, which pins both its behavior and the no-leak property of `local -x`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
getOptimalStorageNode() compared `clientload` on the serialized storagenode row. The 1.6 serializer has no such field, so every node compared as null < null and the first node always won. A 32-host deploy put every task on the master, and the group's other nodes took none (forums 18310). The load now comes from StorageNode::getClientLoad(). A unicast host also kept the node it got at task creation. At check-in, a host on a full node waited in line there while other nodes in its group were idle. checkIn() now moves it to the node in the task's storage group with the most free slots. A capture never moves; it must upload to the master. getNodeFailure()'s docblock said it returns an object. It returns a bool. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Storage nodes: balance deploys across a group, and move waiting hosts
FOS decided Windows, Linux or macOS from a hardcoded list of osID
numbers, so every new os row needed a FOS release. Each os row now
carries its family, and the server sends it next to osid.
Schema step 458 adds os.osFamily ENUM('windows','linux','macos',
'other') NOT NULL DEFAULT 'other' and backfills the seeded ids by osID,
never by name: windows 1-7 and 9-11, macos 8, linux 50 and 51. Every
other row keeps 'other'. OS::get('family') reads the column.
osfamily= is emitted where osid= is: BootMenuBase getTasking(),
IpxeBootMenu falseTasking() and service/hostinfo.php. A task with no
image, and an image with no valid OS, send an empty family. FOS reads
an empty osfamily as not sent. No existing osid= emission changes; the
boot menu goldens differ only by the added osfamily= argument.
schema-expected.php: only the os block changed, spliced from a
manifest generated on MariaDB 11.8. The replay skips closure steps,
so the generated osDescription lost its DEFAULT ''; that line is kept
as committed.
tests/upgrade-from-15-ci.test.sh compares osFamily per osID between the
fresh and the upgraded database. route-column-contract.txt gains the
new osFamily column.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Send the OS family to FOS as osfamily (#2083)
v1.6.29 adds the image's OS family to the Capone image line (FOGProject/fog-plugins#43), read by FOS EXP_20261110-164008. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pin fog-plugins v1.6.29: Capone sends the OS family
Problem: a host with no printer level runs at 0, so a new host gets its group's printers but the client does nothing with them until someone sets the level by hand or by mass edit (#2087). Cause: the level has no default tier. An empty hostPrinterLevel is read as 0 everywhere. Fix: Resolver::resolvePrinterLevel() resolves it like a module without the group tier. A host that stores 0, 1 or 2 keeps it. A host that stores '' follows FOG_CLIENT_PRINTERMANAGER_DEFAULT_LEVEL (schema step 459, default 0). The legacy client, the fog-agent printer set, the Printer Deployment report and the host Printers tab all read it there. The host Printers tab gains "Use the server default (now: ...)". Mass edit Clear on all writes '', so hosts can be returned to the default; the group's Mass Edit Member Hosts uses the same form. A group does not grant a level. A host can be in several groups, and a grant only adds. "Highest wins" is not safe: level 2 removes printers, so joining a group would strip them. Amend ADR 0038. The upgrade changes no host. '' already means nobody set a level (1.5 never wrote one at creation), a saved '0' stays the host's own, and the default ships at 0. Refs #2087 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb6e7wUapCX5tZ9WeCf
A legacy FOG Client that fails FOGPage::authorize() retries on every check-in, forever. The server answers HTTP 200 and records nothing, so an admin finds these hosts only from fog.log on each machine (forum topic 18312). Schema step 459 adds the current failure run to `hosts`: since when, the code, the count, and the address of the last failure. authorize() records two codes. 'ist' is a token that is not the host's; Reset Encryption Data ends it. 'dec' is a session key that certDecrypt() cannot open, because the client encrypts for a key this server does not hold; a reset does not end it. '#!ihc' is not recorded: no working client sends an empty or malformed key. The write is a targeted UPDATE, never save(). authorize() can throw after it sets a rotated token, and save() would commit that token. The count increments in SQL. The next stored handshake clears the run, so a host leaves the report when it recovers, not when someone presses the button. A healthy check-in makes no extra write. The new list report, Client Authentication Failures, shows each host with the problem, since when, the count, the source address, the last check-in and the fix. It is gated on the host node, like the other reports over host rows (ADR 0030 decision 4). The four fields are server-owned, so the API refuses writes to them. The record is advisory. The handshake picks the host by MAC, so any machine on the LAN can cause a row. Nothing acts on it automatically. Route::$serverOwnedFields changed and no route was added, so the OpenAPI document needs no hand edit: it reads the same list. Tests: tests/client-auth-failure.test.php runs the Host writers against the fake connection and pins the authorize() wiring by source. tests/schema-459-client-auth-failure-db.test.php runs the real step on a TEMPORARY hosts table, checks the columns against the manifest, and replays the writers' SQL on a real server. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Printer_Deployment::mode() now receives the int from Resolver::resolvePrinterLevel(), and its docblock still said string. The test checked the int cases through array keys. PHP makes '0' and 0 one key, so those cases never ran. They are pairs now. The report SQL is read with preg_grep(), as the other tests read the fake log. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
authorize()'s catch passes '' for each exception it does not record. Only its own guard kept that from writing a row with an empty Problem cell, and the test checked that guard by the absence of a string, so the guard could go and the suite stayed green. The writer now refuses '' itself, and the test executes that. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ature-lu3ev1 Printer level: "Not set" follows a server default
The report told an admin to reinstall the client for a 'dec' failure, on the belief that the client had been set up against another server. The client does not work that way. Zazzles Authentication.HandShake() downloads srvpublic.crt from this server on every handshake and checks it against its pinned CA. A client pinned to another CA refuses the certificate and never sends a key, so the server never sees it. So a real 'dec' means the certificate this server publishes does not match .srvprivate.key, and every host fails at once. The fix is on the server: re-run the installer, which re-issues a mismatched leaf. One host alone showing 'dec' did not come from a working client. The report, the authorize() comment and the step 459 comment now say so. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A plain installer re-run keeps a client certificate that chains to the current CA, even when it pairs with a different key: _createCommLeaf warns and returns. So "re-run the installer" did not fix the case the report is most likely to show. --recreate-keys issues a new pair. The key certDecrypt() reads is the .srvprivate.key under the first readable storage node SSL path, not always the one the installer paired with the published certificate. The texts now say "the key it decrypts with" rather than naming one file. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb4vjzwmwYP54GuG1dH
The host export JS lists its columns by position. It now carries the four schema 459 fields, so export-columns-match-headers passes. legacy-client-ad-vouch looked for 'self::$Host->save();'. authorize() now tests the save result, so the pin drops the ';'. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb4vjzwmwYP54GuG1dH
dev-branch took step 459 for the printer level default (#2088). That step stays 459. The hosts columns for client handshake failures move to step 460, and FOG_SCHEMA goes to 460. The DB test file and the comments follow the new number. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb4vjzwmwYP54GuG1dH
Record legacy client handshake failures and list them in a report
Two defects on dev-branch. Both were found while testing #2088 on the lab. Route::asValue() kept the JSON Content-Type that names() and the other API helpers set. A page that called Route::getNames() went out as application/json. The Printer Deployment report did that when a listed host had a printer, so the browser showed the page source. asValue() now puts back the type the request had. When no type was set yet, it sets PHP's default. Removing the header sends no type at all, and with nosniff the browser still shows text. Directory Membership, Printer Deployment and User Sessions had no case in fog.report.file.js. Their pages showed headers and no rows, with no error and no request. Each now has a case that loads getList, with every column escaped. Tests: route-asvalue-keeps-content-type (3 checks, php-cgi children) and report-tables-wired (every core report table has a JS case). Each fails on the old code. Verified on the 10.255.20.1 lab: the report page is text/html, and all three grids load their rows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb7hBmMUgEKQZ3L7vS4
asValue() keeps the saved type in $keep. The PHP default line moves to _defaultContentType(). The report JS comment moves off the break line. report-tables-wired.test.php now fails a report file that renders no table, instead of a magic floor. Where a report builds each row as one array literal, it also checks that the JS columns are the row keys and that every column escapes. Each new check fails on a dropped column and on a raw column. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb7hBmMUgEKQZ3L7vS4
The merge queue ejected this PR after #2089 merged. The gate flagged Client Authentication's hostLink as an unescaped column. entityLink() escapes the name and casts the id on the server, and the grid must render the link as HTML. The gate now exempts a row key whose value is an entityLink() call. Un-escaping any other column still fails it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JAdRb7hBmMUgEKQZ3L7vS4
Reports: Printer Deployment renders as HTML, and three grids load rows
Forum topic 18314. Capture on a host with no image left "Create new
tasking" on "Loading, please wait..." for good. ?sub=deploy answers 400
"Assigned image is invalid", and the error handler called
modal('hide') inside Bootstrap 5's show transition, which drops it.
The group Tasks tab did not try to hide at all, and hung the same way.
$.taskFormFailed ends the loading state and writes the escaped reason
into the modal, as $.registerMassEdit already does. The host Tasks
tab, the group Tasks tab and the task list re-deploy all use it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAdRb4vjzwmwYP54GuG1dH
Task modal: show a failed form fetch's reason instead of hanging
The idle check in User::_isLoggedIn() redirected to node=logout without looking at the remember-me cookie, and logout() clears that cookie. So Remember Me lasted only until the first idle FOG_INACTIVITY_TIMEOUT (default 1 hour). Forum 18315. It went unseen while PHP's 24-minute session GC deleted the session first: ProcessLogin's cookie replay then signed the user back in. #1306 moved sessions to FOG's own 86400s store, so the session now outlives the timeout and the idle branch fires first. The idle branch now skips the logout when the request carries a valid, unexpired remember-me token that belongs to the signed-in user. The check is UserAuth::matches(). The test drives isLoggedIn() on an idle session and fails under seven mutations of the fix. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-up on #2092: the named helper had one caller, and a reader of _isLoggedIn() now sees why its two cookie reads differ. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Keep a Remember Me session past the inactivity timeout
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request for creating the latest stable release from staged security fixes, bug fixes, and minor enhancements in dev-branch. Created as needed or monthly on 11th of every month (queued in gh actions at 11:11 UTC), released once tests are passing