[PR #2795] [MERGED] [PM-3741] [PM-3750] Improvements to local storage handling #45411

Closed
opened 2026-04-26 12:42:33 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/2795
Author: @mpbw2
Created: 9/25/2023
Status: Merged
Merged: 10/12/2023
Merged by: @mpbw2

Base: masterHead: bugfix/local-data


📝 Commits (3)

  • 841c613 [PM-3741] [PM-3750] Improvements to local storage handling
  • c5f54e4 Update src/Android/MainActivity.cs
  • c334e9e Merge branch 'master' into bugfix/local-data

📊 Changes

4 files changed (+17 additions, -6 deletions)

View changed files

📝 src/Android/Constants.cs (+6 -0)
📝 src/Android/MainActivity.cs (+8 -4)
📝 src/Android/Resources/xml/filepaths.xml (+1 -1)
📝 src/Android/Services/FileService.cs (+2 -1)

📄 Description

Type of change

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

Objective

Improvements to the way we handle file attachment intents and storage restrictions

Code changes

  • FileService.cs / Constants.cs / filepaths.xml: Convert to using specific path for temporary camera images using purpose-driven path restrictions
  • MainActivity.cs: For non-camera attachments do not allow URIs pointing to our app's private storage. For camera attachments use the new temp path defined above. In both cases a resulting filename is required to continue with the attachment process as another layer of security.

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/2795 **Author:** [@mpbw2](https://github.com/mpbw2) **Created:** 9/25/2023 **Status:** ✅ Merged **Merged:** 10/12/2023 **Merged by:** [@mpbw2](https://github.com/mpbw2) **Base:** `master` ← **Head:** `bugfix/local-data` --- ### 📝 Commits (3) - [`841c613`](https://github.com/bitwarden/android/commit/841c613f48cc9e3371621a144115bf66a9241218) [PM-3741] [PM-3750] Improvements to local storage handling - [`c5f54e4`](https://github.com/bitwarden/android/commit/c5f54e4a51f8df48fdbf980574b06dbb1c1863c3) Update src/Android/MainActivity.cs - [`c334e9e`](https://github.com/bitwarden/android/commit/c334e9e2e46c9c49e95510f076659b4f76108cb8) Merge branch 'master' into bugfix/local-data ### 📊 Changes **4 files changed** (+17 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `src/Android/Constants.cs` (+6 -0) 📝 `src/Android/MainActivity.cs` (+8 -4) 📝 `src/Android/Resources/xml/filepaths.xml` (+1 -1) 📝 `src/Android/Services/FileService.cs` (+2 -1) </details> ### 📄 Description ## Type of change - [X] Bug fix - [ ] 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--> Improvements to the way we handle file attachment intents and storage restrictions ## 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--> * **FileService.cs / Constants.cs / filepaths.xml:** Convert to using specific path for temporary camera images using purpose-driven path restrictions * **MainActivity.cs:** For non-camera attachments do not allow URIs pointing to our app's private storage. For camera attachments use the new temp path defined above. In both cases a resulting filename is required to continue with the attachment process as another layer of security. ## 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 2026-04-26 12:42:33 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#45411