Class DevelopmentAdminReset
-D"com.iizix.serveradmin.reset"="1" deletes, at every start while the option is set, what keeps everyone but the enrolled person out of iiziAdmin - so that a rig, a second person or a Browser check can sign in to ServerAdmin on a developer's server once more.What goes (RS-3), in one transaction, after the database is open and before the first session is admitted (JettyRunConfiguration.onStartServer, right after SeedPasswordCheck):
- the second factor: the sealed TOTP secret of
IZS.USER_MFAand the recovery codes ofIZS.USER_MFA_CODES(MFAStore.remove(Connection,long)); - the passkeys: the WebAuthn credentials of
IZS.USER_CREDENTIALS(PasskeyStore.removeAll(Connection,long)); the user handle ofIZS.USER_HANDLESstays - it is an identity, not a factor, and a new passkey is registered under it; - the signed-in devices: every row of
IZS.DEVICE_TOKENS, "stay signed in" and the MFA trust alike (DeviceTokenStore.revokeAll(Connection,long)).
UserMFA, the passkey challenges of PasskeyService) live in memory keyed by session and are empty at a start by construction. The password, the language and every other profile setting are kept (RS-5): after the reset, sign-in runs the normal code. A table the database does not have is looked for, never created.Who (RS-4): iiziAdmin only, the account createBaseTables.sql creates, found by its name; no other member of the administrators group is touched.
When (RS-1, RS-2): the property alone decides, and exactly the value "1"; any other value is off, and nothing in a request, a settings file or the database can set it. A built server (Tycho, Jenkins, shipped) that finds it logs one SEVERE and changes nothing: the mode is SystemConfig.isDevelopmentMode, as SeedPasswordCheck tells it (AP-6).
Loud (RS-6): one WARNING at every start with the option, with the count per kind of what was deleted - never a secret - and the word to remove the option.
The kill switch (the owner, 2026-10-08): ENABLED, in this one place. With it null the feature is gone: run() returns at once and the property is not even read.
- Author:
- Christopher Mindus
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumWhat a start did.static final recordWhat a start did, with the count per kind of what went.Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ObjectThe kill switch of the whole feature, in this one place:Integer.valueOf(1)builds the reset in,nullremoves it -run()answersDevelopmentAdminReset.Outcome.OFFat once and the property "com.iizix.serveradmin.reset" is not read.static final StringThe one value of the property that turns the reset on: "1".static final StringThe system property: "com.iizix.serveradmin.reset"="1" at the start of a development server, read at every start.Method Summary
Modifier and TypeMethodDescriptionstatic DevelopmentAdminReset.Resultrun()Runs the reset at the start of the server, asENABLEDand the property say.
Field Details
ENABLED
The kill switch of the whole feature, in this one place:Integer.valueOf(1)builds the reset in,nullremoves it -run()answersDevelopmentAdminReset.Outcome.OFFat once and the property "com.iizix.serveradmin.reset" is not read. A finalObjectrather than a compile-time constant on purpose: a test handsrun(Object)either value, and nothing that reads this field is inlined by the compiler.PROPERTY
ON
The one value of the property that turns the reset on: "1". Any other value is off.- See Also:
Method Details
run
Runs the reset at the start of the server, asENABLEDand the property say. A failure is logged and never stops the start.- Returns:
- What was done.