# Use Case 2.6 Change remote PIN
## Overview
| Aspect | Description |
|------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **Summary** | The user changes their PIN by first entering the current one, then choosing and confirming a new PIN that meets policy requirements. |
| **Goal** | Changing the remote PIN. |
| **Preconditions** |
- User completed [UC3.1 Obtain PID from provider](UC3.1_ObtainPidFromProvider.md)
- User completed [UC1.2 Open the app](UC1.2_OpenTheApp.md)
|
| **Postconditions** | - User can use the new PIN in the Wallet.
- User can no longer use the old PIN in the Wallet.
|
| **Triggered by** | - User selects 'Change pin' in [UC9.1 Show app menu](UC9.1_ShowAppMenu.md).
|
| **Additional Documentation** | - [PIN validation](../../architecture/use-cases/pin-validation)
|
| **Possible errors** | - No internet
- Server unreachable
|
| **Logical Test Cases** | - [LTC56 PIN Change Happy flow](../logical-test-cases.md#ltc76)
- [LTC61 PIN entries do not match, try again](../logical-test-cases.md#ltc77)
- [LTC62 PIN entries do not match, choose new PIN](../logical-test-cases.md#ltc76)
- [LTC63 PIN entry does not conform to policy](../logical-test-cases.md#ltc77)
- [LTC64 PIN change fails, could not reach server](../logical-test-cases.md#ltc77)
- [LTC65 PIN change fails, no internet](../logical-test-cases.md#ltc57)
|
---
## Flow
| # | Description | Next |
| ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
| **1** | **PRIMARY SCENARIO** | |
| **1.1** | **System executes partial flow [PF2.4 Confirm a protected action](../partial-flows/PF2.4_ConfirmProtectedAction.md)** | |
| 1.1a | Result: Confirm | 1.2 |
| 1.1b | Result: Back | Back |
| **1.2** | **Displays screen 'Choose new PIN'**- Message: Choose a new 6-digit PIN
- Input: 6 digits (0-9) PIN field
- Actions: Back
| |
| 1.2a | User enters PIN | 1.3 |
| 1.2b | User selects Back | Back |
| 1.2c | Error: No internet | Error flow: No internet |
| 1.2d | Error: Server unreachable | Error flow: Server unreachable |
| **1.3** | **System validates entered PIN against PIN policy**- Duration: 0.0 - 0.1 seconds
| |
| 1.3a | Case: PIN matches PIN policy | 1.4 |
| 1.3b | Case: PIN does not match PIN policy | 2 |
| **1.4** | **System displays screen 'Repeat PIN'**- Message: Repeat your new PIN
- Input: 6 digits (0-9) PIN field
- Actions: Back
| |
| 1.4a | User enters PIN | 1.5 |
| 1.4b | User selects Back | Back |
| **1.5** | **System validates PINs match**- Duration: 0.0 - 0.1 seconds
| |
| 1.5a | Case: PINs match | 1.6 |
| 1.5b | Case: PINs do not match first time | 3 |
| 1.5c | Case: PINs do not match second time | 4 |
| 1.5d | Error: No internet | Error flow: No internet |
| 1.5e | Error: Server unreachable | Error flow: Server unreachable |
| **1.6** | **System displays screen 'PIN change success'**- Message: Success!
- Actions: Dashboard, Settings
| |
| 1.6a | User selects Dashboard | Go to: [UC7.1 Show all available cards](UC7.1_ShowAllAvailableCards.md) |
| 1.6b | User selects Settings | End |
| **2** | **WHEN PIN DOES NOT SATISFY POLICY (TOO SIMPLE)** | |
| **2.1** | **System displays PIN too simple message** | |
| 2.1a | User selects OK | 1.2 |
| **3** | **WHEN PINs ARE NOT EQUAL (FIRST TIME)** | |
| **3.1** | **System displays PIN is different message** | |
| 3.1a | User selects Try again | 1.4 |
| **4** | **WHEN PINs ARE NOT EQUAL (SECOND TIME)** | |
| **4.1** | **System displays PIN is different message** | |
| 4.1a | User selects Choose New Pin | 1.2 |