Repository navigation
Conversation
Update OteAccountBuilder.addUser to grant RegistrarRole.TECH_CONTACT
("Editor") instead of RegistrarRole.ACCOUNT_MANAGER ("Viewer") across
all provisioned OT&E registrars so new OT&E console users hold
EDIT_REGISTRAR_DETAILS and can self-service configure mTLS client
certificates and IP allowlists via SecurityAction.
Also update ConsoleOteAction.getHandler to check
ConsolePermission.CHECK_ONBOARDING_STATUS via checkPermission (allowing
both global support roles and per-registrar TECH_CONTACT/PRIMARY_CONTACT
users to check OT&E status while returning 403 Forbidden for
unauthorized or disabled registrars) and validate Registrar.Type.OTE
before parsing the base registrar ID.
Update OteAccountBuilderTest and ConsoleOteActionTest to verify
TECH_CONTACT provisioning, self-service SecurityAction certificate and
IP allowlist updates, and ConsoleOteAction GET/POST authorization.
BUG= http://b/586480144
319518b to
1134ece
Compare
|
What are the risks of this change? Might we be unintentionally granting users more access than expected? |
|
Good question. Short answer: this grants no access beyond what support Why the change is needed
What limits the risk
What More context is in http://b/586480144. |
Update OteAccountBuilder.addUser to grant RegistrarRole.TECH_CONTACT
("Editor") instead of RegistrarRole.ACCOUNT_MANAGER ("Viewer") across
all provisioned OT&E registrars so new OT&E console users hold
EDIT_REGISTRAR_DETAILS and can self-service configure mTLS client
certificates and IP allowlists via SecurityAction.
Also update ConsoleOteAction.getHandler to check
ConsolePermission.CHECK_ONBOARDING_STATUS via checkPermission (allowing
both global support roles and per-registrar TECH_CONTACT/PRIMARY_CONTACT
users to check OT&E status while returning 403 Forbidden for
unauthorized or disabled registrars) and validate Registrar.Type.OTE
before parsing the base registrar ID.
Update OteAccountBuilderTest and ConsoleOteActionTest to verify
TECH_CONTACT provisioning, self-service SecurityAction certificate and
IP allowlist updates, and ConsoleOteAction GET/POST authorization.
Background: how OT&E users lost self-service access
RegistrarPoclogin contacts created by the oldOteAccountBuilder.addContactno longer granted any console access.OteAccountBuilderto create consoleUsers and gave themRegistrarRole.ACCOUNT_MANAGERon all four OT&Eregistrars (
-1,-3,-4,-5). At the time this was harmless:the legacy registrar console mapped any registrar role to
OWNER,and
OWNERcould edit certificates and IP allowlists.SecurityActionrequires the per-registrarEDIT_REGISTRAR_DETAILSpermission, which
ACCOUNT_MANAGER("Viewer") does not have. Fromthat point, newly created OT&E users could no longer upload their own
certificates or IP allowlists.
Since then, support has worked around this by hand. After every
"Generate OT&E Account" run, they open the console Users page on each of
the four OT&E registrars and change the generated user from "Viewer" to
"Editor" (
TECH_CONTACT). If that step is missed, the registrar islocked out of self-service certificate and IP setup and has to ask
support again. Related manual repairs of OT&E console users are tracked
in http://b/435167780.
Risk and scope
This change grants no access beyond what support already gives every
OT&E user by hand today. It removes four manual role edits per
onboarding.
OteAccountBuilderandConsoleOteAction.postHandlerboth fail withcheckStateinPRODUCTION.on the generated
Registrar.Type.OTEregistrars. The user hasglobalRole = NONEandisAdmin = false, and gets no role on anyother registrar.
TECH_CONTACTgrantsEDIT_REGISTRAR_DETAILSon those registrars only. Actions that needthe global permission still return 403: changing
allowedTlds,changing
registryLockAllowed(MANAGE_REGISTRARS), and creatingOT&E accounts (
POST /console-api/ote).TECH_CONTACT: managing console users(
MANAGE_USERS,PRIMARY_CONTACTonly), changing the set ofADMIN(primary) contacts, and completing an EPP password reset. A
TECH_CONTACTcan request a reset, but the link goes to theADMINcontact and verifying it requires
MANAGE_USERS.TECH_CONTACTdoes add on these OT&E registrars: editing thecertificate and IP allowlist, non-
ADMINcontacts, and RDAP fields;changing the EPP password (requires the current password); and bulk
domain deletes (
EXECUTE_EPP_COMMANDS). Registry Lock staysunavailable because
registryLockAlloweddefaults tofalse.BUG= http://b/586480144
This change is