Coming from a discussion in this PR.
Problem
A bad actor can work to gain control of an account from an unsuspecting user by adding the attacker's contact method as a secondary contact method during the company card provisioning flow (it's in the WorkspaceCompanyCardAddWorkEmailPage component), then setting that to the primary contact method (to receive future magic codes).
Solution
- Prompt the user for a magic code (we have this same flow in many different places in the app, so you can use those for inspiration)
- Send that code to the API for setting the new default contact method
- It's fine to assume for now that these requests will always be successful, even if an invalid code is entered. Eventually, the backend will start verifying the codes and return an error message if it isn't successful
cc @rafecolton @shubham1286agra
Issue Owner
Current Issue Owner: @shubham1206agra
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~022049169261097777754
- Upwork Job ID: 2049169261097777754
- Last Price Increase: 2026-05-05
Coming from a discussion in this PR.
Problem
A bad actor can work to gain control of an account from an unsuspecting user by adding the attacker's contact method as a secondary contact method during the company card provisioning flow (it's in the
WorkspaceCompanyCardAddWorkEmailPagecomponent), then setting that to the primary contact method (to receive future magic codes).Solution
cc @rafecolton @shubham1286agra
Issue Owner
Current Issue Owner: @shubham1206agraUpwork Automation - Do Not Edit