[PR #2167] [MERGED] [SG-174] Login with Device Request - Mobile #3402

Closed
opened 2025-11-26 23:32:15 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/2167
Author: @andrebispo5
Created: 11/4/2022
Status: Merged
Merged: 11/9/2022
Merged by: @andrebispo5

Base: masterHead: feature/SG-174-login-with-device


📝 Commits (10+)

  • 52d05e5 [SG-174] Add new login request services to Api
  • 86e716a [SG-174] Fix typo
  • 881d7a0 [SG-174] Enable login with device button.
  • d567be1 [SG-174] Add new login request page and viewmodel
  • 82ec0a6 [SG-174] Add new text resources
  • 0882599 [SG-174] Add new RSA Decrypt method with string param
  • d420fd7 [SG-174] Change create login request method
  • df75949 [SG-174] Add new method to auth service to login passwordless
  • b80a4ce [SG-174] Refactor login helper method to work with passwordless
  • fdc8be2 [SG-174] Fix service registration

📊 Changes

25 files changed (+618 additions, -15 deletions)

View changed files

📝 src/App/App.csproj (+3 -0)
📝 src/App/Controls/IconLabelButton/IconLabelButton.xaml (+2 -0)
📝 src/App/Controls/IconLabelButton/IconLabelButton.xaml.cs (+1 -1)
📝 src/App/Pages/Accounts/LoginPage.xaml (+2 -2)
📝 src/App/Pages/Accounts/LoginPage.xaml.cs (+8 -2)
📝 src/App/Pages/Accounts/LoginPageViewModel.cs (+3 -0)
src/App/Pages/Accounts/LoginPasswordlessRequestPage.xaml (+76 -0)
src/App/Pages/Accounts/LoginPasswordlessRequestPage.xaml.cs (+65 -0)
src/App/Pages/Accounts/LoginPasswordlessRequestViewModel.cs (+194 -0)
📝 src/App/Pages/CaptchaProtectedViewModel.cs (+16 -0)
📝 src/App/Resources/AppResources.Designer.cs (+54 -0)
📝 src/App/Resources/AppResources.resx (+18 -0)
📝 src/Core/Abstractions/IApiService.cs (+2 -0)
📝 src/Core/Abstractions/IAuthService.cs (+4 -0)
📝 src/Core/Abstractions/ICryptoService.cs (+1 -0)
src/Core/Models/Request/PasswordlessCreateLoginRequest.cs (+34 -0)
📝 src/Core/Models/Request/TokenRequest.cs (+8 -1)
📝 src/Core/Models/Response/PasswordlessLoginResponse.cs (+2 -0)
📝 src/Core/Services/ApiService.cs (+10 -0)
📝 src/Core/Services/AuthService.cs (+41 -2)

...and 5 more files

📄 Description

Type of change

  • Bug fix
  • New feature development
  • Tech debt (refactoring, code cleanup, dependency upgrades, etc)
  • Build/deploy pipeline (DevOps)
  • Other

Objective

Add a new login option to the methods list. The login with another device will allow users to log into their accounts using a passwordless method.

Code changes

  • src/App/Pages/CaptchaProtectedViewModel.cs: New base method to handle captcha. Older method didn't have any changes to protect other parts of the code that were using it. May be target of some tech dept to change to use the newer method.
  • src/Core/Services/CryptoService.cs: Added parameter to allow to rsa decrypt with a custom private key.

Screenshots

image image image image

Before you submit

  • Please check for formatting errors (dotnet format --verify-no-changes) (required)
  • Please add unit tests where it makes sense to do so (encouraged but not required)
  • If this change requires a documentation update - notify the documentation team
  • If this change has particular deployment requirements - notify the DevOps team

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/2167 **Author:** [@andrebispo5](https://github.com/andrebispo5) **Created:** 11/4/2022 **Status:** ✅ Merged **Merged:** 11/9/2022 **Merged by:** [@andrebispo5](https://github.com/andrebispo5) **Base:** `master` ← **Head:** `feature/SG-174-login-with-device` --- ### 📝 Commits (10+) - [`52d05e5`](https://github.com/bitwarden/android/commit/52d05e5c6d0459d5b17efbea4ee0ed01bd214748) [SG-174] Add new login request services to Api - [`86e716a`](https://github.com/bitwarden/android/commit/86e716aa332e914312b802320c2d1ed3a8ed037c) [SG-174] Fix typo - [`881d7a0`](https://github.com/bitwarden/android/commit/881d7a0c08a525b0b5cd0838abcc10072f3d39fe) [SG-174] Enable login with device button. - [`d567be1`](https://github.com/bitwarden/android/commit/d567be1954e3d157412e4068d095018cede5f32b) [SG-174] Add new login request page and viewmodel - [`82ec0a6`](https://github.com/bitwarden/android/commit/82ec0a664f5586f20731bbb1ee14cdc4224b2cb8) [SG-174] Add new text resources - [`0882599`](https://github.com/bitwarden/android/commit/08825997cf3c4062d565ae7d388016e637ed1807) [SG-174] Add new RSA Decrypt method with string param - [`d420fd7`](https://github.com/bitwarden/android/commit/d420fd715b4728d6c82d6e91d8ee67b0a14b79ec) [SG-174] Change create login request method - [`df75949`](https://github.com/bitwarden/android/commit/df759497a30d8f5a0121ea03be2620f910fc9172) [SG-174] Add new method to auth service to login passwordless - [`b80a4ce`](https://github.com/bitwarden/android/commit/b80a4ce2ebd5e8e4b7cc1fedc2be3a5d807c606a) [SG-174] Refactor login helper method to work with passwordless - [`fdc8be2`](https://github.com/bitwarden/android/commit/fdc8be2c023851bb03f0dca5c0d5ff2cfd93a6a1) [SG-174] Fix service registration ### 📊 Changes **25 files changed** (+618 additions, -15 deletions) <details> <summary>View changed files</summary> 📝 `src/App/App.csproj` (+3 -0) 📝 `src/App/Controls/IconLabelButton/IconLabelButton.xaml` (+2 -0) 📝 `src/App/Controls/IconLabelButton/IconLabelButton.xaml.cs` (+1 -1) 📝 `src/App/Pages/Accounts/LoginPage.xaml` (+2 -2) 📝 `src/App/Pages/Accounts/LoginPage.xaml.cs` (+8 -2) 📝 `src/App/Pages/Accounts/LoginPageViewModel.cs` (+3 -0) ➕ `src/App/Pages/Accounts/LoginPasswordlessRequestPage.xaml` (+76 -0) ➕ `src/App/Pages/Accounts/LoginPasswordlessRequestPage.xaml.cs` (+65 -0) ➕ `src/App/Pages/Accounts/LoginPasswordlessRequestViewModel.cs` (+194 -0) 📝 `src/App/Pages/CaptchaProtectedViewModel.cs` (+16 -0) 📝 `src/App/Resources/AppResources.Designer.cs` (+54 -0) 📝 `src/App/Resources/AppResources.resx` (+18 -0) 📝 `src/Core/Abstractions/IApiService.cs` (+2 -0) 📝 `src/Core/Abstractions/IAuthService.cs` (+4 -0) 📝 `src/Core/Abstractions/ICryptoService.cs` (+1 -0) ➕ `src/Core/Models/Request/PasswordlessCreateLoginRequest.cs` (+34 -0) 📝 `src/Core/Models/Request/TokenRequest.cs` (+8 -1) 📝 `src/Core/Models/Response/PasswordlessLoginResponse.cs` (+2 -0) 📝 `src/Core/Services/ApiService.cs` (+10 -0) 📝 `src/Core/Services/AuthService.cs` (+41 -2) _...and 5 more files_ </details> ### 📄 Description ## Type of change - [ ] Bug fix - [X] New feature development - [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) - [ ] Build/deploy pipeline (DevOps) - [ ] Other ## Objective <!--Describe what the purpose of this PR is. For example: what bug you're fixing or what new feature you're adding--> Add a new login option to the methods list. The login with another device will allow users to log into their accounts using a passwordless method. ## Code changes <!--Explain the changes you've made to each file or major component. This should help the reviewer understand your changes--> <!--Also refer to any related changes or PRs in other repositories--> * **src/App/Pages/CaptchaProtectedViewModel.cs:** New base method to handle captcha. Older method didn't have any changes to protect other parts of the code that were using it. May be target of some tech dept to change to use the newer method. * **src/Core/Services/CryptoService.cs:** Added parameter to allow to rsa decrypt with a custom private key. ## Screenshots <!--Required for any UI changes. Delete if not applicable--> <img width="385" alt="image" src="https://user-images.githubusercontent.com/4648522/200632608-b82a812f-84c1-402a-b2cb-d7775a3e24b8.png"> <img width="390" alt="image" src="https://user-images.githubusercontent.com/4648522/200632624-aa7b1991-5250-4536-8d01-784b22071ac5.png"> <img width="405" alt="image" src="https://user-images.githubusercontent.com/4648522/200632635-9c622b03-fcb0-4001-a732-b66e2a030139.png"> <img width="381" alt="image" src="https://user-images.githubusercontent.com/4648522/200872370-d2721087-fd0c-42a7-bb4c-bdff0fc9aa59.png"> ## Before you submit - Please check for formatting errors (`dotnet format --verify-no-changes`) (required) - Please add **unit tests** where it makes sense to do so (encouraged but not required) - If this change requires a **documentation update** - notify the documentation team - If this change has particular **deployment requirements** - notify the DevOps team --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-26 23:32:15 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#3402