pyfsr.cli.appliance.license¶
pyfsr appliance license — licensing / identity verbs.
The device UUID is the value that eats sessions: it doubles as the
cyberpgsql / elastic password, and on a FortiCloud-drifted box the
entitlement UUID that csadm reports diverges from the install-time UUID
that the DB/ES passwords were provisioned with — so csadm’s value silently
fails Postgres auth (see facts). license drift makes that mismatch a
first-class, gate-able check instead of a half-session mystery.
Classes¶
Parsed |
|
Result of comparing the install-time UUID against csadm's entitlement UUID. |
Functions¶
|
Raw |
|
Typed |
|
The install-time device UUID from |
|
The current entitlement device UUID from |
|
The device UUID to use as the DB/ES password: file first, csadm fallback. |
|
Compare the install-time file UUID against csadm's entitlement UUID. |
Module Contents¶
- class pyfsr.cli.appliance.license.LicenseDetails[source]¶
Parsed
csadm license --show-detailsidentity card.total_users/remaining_daysare typed ints;fieldskeeps every rawkey: valuepair so uncommon keys are still reachable.
- pyfsr.cli.appliance.license.show(transport: pyfsr.cli.appliance.transport.Transport) str[source]¶
Raw
csadm license --show-detailsoutput. For a typed result usedetails().
- pyfsr.cli.appliance.license.details(transport: pyfsr.cli.appliance.transport.Transport) LicenseDetails[source]¶
Typed
csadm license --show-details— edition, expiry, user count, UUID.
- pyfsr.cli.appliance.license.device_uuid_from_file(transport: pyfsr.cli.appliance.transport.Transport) str | None[source]¶
The install-time device UUID from
/home/csadmin/device_uuid(no sudo).This is the authoritative DB/ES password value. Returns
Noneif the file is absent or unreadable.
- pyfsr.cli.appliance.license.device_uuid_from_csadm(transport: pyfsr.cli.appliance.transport.Transport) str | None[source]¶
The current entitlement device UUID from
csadm(needs root).On a FortiCloud-drifted box this differs from the file value and will fail
cyberpgsqlauth. ReturnsNoneif csadm fails.
- pyfsr.cli.appliance.license.device_uuid(transport: pyfsr.cli.appliance.transport.Transport) str[source]¶
The device UUID to use as the DB/ES password: file first, csadm fallback.
Mirrors
facts.Facts.device_uuid()so the verb and the DB layer agree on which value is authoritative.
- class pyfsr.cli.appliance.license.DriftReport[source]¶
Result of comparing the install-time UUID against csadm’s entitlement UUID.
- pyfsr.cli.appliance.license.drift(transport: pyfsr.cli.appliance.transport.Transport) DriftReport[source]¶
Compare the install-time file UUID against csadm’s entitlement UUID.
A drift means
csadm’s value would fail Postgres/ES auth; the file value (used by the DB layer) is the one that still works. Either source missing is reported rather than silently treated as a match.