Registration (StarkEx Perpetual Trading v1.0)

In StarkEx for Perpetual Trading v2.0, registration is not required for user onboarding. The mapping between the starkKey and the Ethereum address happens in the withdrawal flow by requiring the user to specify a destination Ethereum address. This flow has changed due to the effort to reduce gas costs for users.

registration

In StarkEx, Registration means mapping the user starkKey to his Ethereum Address. This mapping enforces that when funds are removed from an L2 account, only the Ethereum address registered to that account’s starkKey will be able to withdraw the funds on-chain.

Step 1: Off-Chain Registration Request

Alice requests the application operator to register her starkKey under her Ethereum address. If the application chooses to register Alice (each application can have its own registration policy), it signs the mapping with the userAdmin key.

Any number of starkKeys can be mapped to the same Ethereum address.

Step 2: On-Chain Registration Transaction

A transaction is sent to the StarkEx contract, containing the Ethereum address, the starkKey and the signature obtained during the previous step. See register for more information on this function.

On-chain registration can be done by any Ethereum address. For example, the application may choose to do the on-chain registration, obscuring this step from the user.
Note that this operation cannot be harmful to the users in any way.