Skip to content

Improved general file system reliability#132

Merged
d2dyno1 merged 55 commits into
masterfrom
general_fs_fixes
Jul 4, 2026
Merged

Improved general file system reliability#132
d2dyno1 merged 55 commits into
masterfrom
general_fs_fixes

Conversation

@d2dyno1

@d2dyno1 d2dyno1 commented Jul 1, 2026

Copy link
Copy Markdown
Member

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to improve overall virtual filesystem reliability and correctness across multiple backends (WinFsp/Dokany/FUSE/WebDAV/Android SAF), mainly by fixing concurrency hazards, making file metadata/size reporting more accurate, and removing debug-time behaviors that could disrupt production use.

Changes:

  • Tighten thread-safety and metadata correctness in WinFsp/Dokany/FUSE handle and stream operations (locking, refreshed metadata, corrected size reporting).
  • Improve Android SAF/provider behavior (faster enumeration, correct document ID/root handling, better error semantics, thumbnail generation updates).
  • Disable filename caching by default and perform broad cleanup/removal of debug artifacts and unused code.

Reviewed changes

Copilot reviewed 66 out of 77 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
tests/SecureFolderFS.Tests/CliTests/Commands/VaultShellCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/VaultRunCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/VaultInfoCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/VaultCreateCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/CredsRemoveCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/CredsChangeCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/Commands/CredsAddCommandTests.cs Whitespace cleanup in CLI test
tests/SecureFolderFS.Tests/CliTests/CliExecutionResult.cs Whitespace cleanup in test helper
src/Shared/SecureFolderFS.Storage/VirtualFileSystem/VirtualFileSystemOptions.cs Disable filename caching by default
src/Platforms/SecureFolderFS.Uno/Views/Settings/PreferencesSettingsPage.xaml.cs WebDAV banner + “Apply” action
src/Platforms/SecureFolderFS.Uno/Views/Settings/PreferencesSettingsPage.xaml Add InfoBar action button
src/Platforms/SecureFolderFS.Uno/UserControls/LoginOptions.xaml.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Uno/TemplateSelectors/LoginTemplateSelector.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Uno/Platforms/Desktop/ServiceImplementation/SkiaVaultCredentialsService.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Uno/Helpers/WebDavRedirectorHelpers.cs Windows WebDAV redirector helpers
src/Platforms/SecureFolderFS.Uno/Dialogs/PaymentDialog.xaml.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Uno/App.xaml.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Views/Modals/Vault/FilePreviewModalPage.xaml.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Views/Modals/Vault/BrowserSearchModalPage.xaml.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/TemplateSelectors/LoginTemplateSelector.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Platforms/iOS/ServiceImplementation/IOSVaultCredentialsService.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Platforms/iOS/ServiceImplementation/IOSShareService.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Platforms/Android/Storage/AndroidStorable.cs Remove debugger breakpoint
src/Platforms/SecureFolderFS.Maui/Platforms/Android/Storage/AndroidFolder.cs Faster enumeration + safer delete
src/Platforms/SecureFolderFS.Maui/Platforms/Android/Storage/AndroidFile.cs Seekable reads + non-truncating writes
src/Platforms/SecureFolderFS.Maui/Platforms/Android/ServiceImplementation/ShareContentProvider.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Platforms/Android/ServiceImplementation/AndroidVaultCredentialsService.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Maui/Platforms/Android/ServiceImplementation/AndroidMediaService.cs Use shared thumbnail helper
src/Platforms/SecureFolderFS.Maui/Platforms/Android/AppModels/StreamedMediaSource.cs Remove duplicate media source
src/Platforms/SecureFolderFS.Cli/CredentialReader.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Cli/CliTypeActivator.cs Remove unused activator helper
src/Platforms/SecureFolderFS.Cli/CliOutput.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Cli/CliGlobalOptions.cs Whitespace cleanup
src/Platforms/SecureFolderFS.Cli/CliCommandHelpers.cs Whitespace cleanup
src/Core/SecureFolderFS.Core.WinFsp/OpenHandles/WinFspFileHandle.cs Refresh metadata + accurate size
src/Core/SecureFolderFS.Core.WinFsp/Callbacks/OnDeviceWinFsp.cs Concurrency + enumeration reliability fixes
src/Core/SecureFolderFS.Core.WinFsp/AppModels/WinFspOptions.cs Disable filename caching by default
src/Core/SecureFolderFS.Core.WinFsp/AppModels/DirectoryEnumerationContext.cs Track directory enumeration state
src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs More resilient HTTP accept/dispatch loop
src/Core/SecureFolderFS.Core.WebDav/AppModels/WebDavOptions.cs Disable filename caching by default
src/Core/SecureFolderFS.Core.MobileFS/SecureFolderFS.Core.MobileFS.csproj Remove redundant compile item
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/Helpers/ThumbnailHelpers.cs Fix thumbnail generation semantics
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/FileSystem/RootCollection.cs Thread-safe root enumeration snapshot
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/FileSystem/ReadWriteCallbacks.cs Correct errno signaling on failures
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/FileSystem/Projections.cs Include last-modified in projection
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/FileSystem/FileSystemProvider.Main.cs SAF correctness + notifications + thumbnails
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/FileSystem/FileSystemProvider.Helpers.cs Document ID/root handling improvements
src/Core/SecureFolderFS.Core.MobileFS/Platforms/Android/AppModels/StreamedMediaSource.cs Shared streamed media data source
src/Core/SecureFolderFS.Core.FUSE/OpenHandles/FuseHandlesManager.cs Correct access flags + stable snapshots
src/Core/SecureFolderFS.Core.FUSE/Callbacks/OnDeviceFuse.cs Locking + correct open/write semantics
src/Core/SecureFolderFS.Core.FUSE/AppModels/FuseOptions.cs Fix option mapping bug
src/Core/SecureFolderFS.Core.FileSystem/UniversalCache.cs Add bounded capacity eviction
src/Core/SecureFolderFS.Core.FileSystem/Streams/StreamsAccess.cs Atomic crypt-file get-or-create
src/Core/SecureFolderFS.Core.FileSystem/Streams/PlaintextStream.cs Correct gap semantics + header locking
src/Core/SecureFolderFS.Core.FileSystem/Storage/StorageProperties/CryptoSizeOfProperty.cs Clamp size for unwritten headers
src/Core/SecureFolderFS.Core.FileSystem/Storage/CryptoStorable.cs Fix root boundary check
src/Core/SecureFolderFS.Core.FileSystem/Storage/CryptoFolder.cs Fix plaintext ID computation
src/Core/SecureFolderFS.Core.FileSystem/Helpers/Paths/PathHelpers.cs macOS mount path handling tweak
src/Core/SecureFolderFS.Core.FileSystem/Helpers/Paths/Native/NativePathHelpers.Directory.cs Ensure full DirectoryId reads
src/Core/SecureFolderFS.Core.FileSystem/Helpers/Paths/Native/NativePathHelpers.cs Safer relative-path computation
src/Core/SecureFolderFS.Core.FileSystem/Helpers/Paths/Abstract/AbstractPathHelpers.Directory.cs Ensure full DirectoryId reads + validate cache
src/Core/SecureFolderFS.Core.FileSystem/FileNames/NameWithDirectoryId.cs Fix equality/hash correctness
src/Core/SecureFolderFS.Core.FileSystem/Extensions/FileHeaderExtensions.cs Synchronize header initialization
src/Core/SecureFolderFS.Core.FileSystem/CryptFiles/OpenCryptFileManager.cs Add atomic GetOrCreate
src/Core/SecureFolderFS.Core.FileSystem/CryptFiles/OpenCryptFile.cs Thread-safe opened-stream tracking
src/Core/SecureFolderFS.Core.FileSystem/Chunks/ChunkWriter.cs Avoid silent data loss on out-of-order writes
src/Core/SecureFolderFS.Core.FileSystem/Chunks/ChunkReader.cs Remove debugger breakpoint
src/Core/SecureFolderFS.Core.FileSystem/Chunks/ChunkAccess.cs Synchronize chunk operations
src/Core/SecureFolderFS.Core.FileSystem/Chunks/CachingChunkAccess.cs Flush correctness + avoid unnecessary flush
src/Core/SecureFolderFS.Core.FileSystem/Buffers/HeaderBuffer.cs Add header synchronization root
src/Core/SecureFolderFS.Core.Dokany/OpenHandles/DokanyHandlesManager.cs Provide security to handles manager
src/Core/SecureFolderFS.Core.Dokany/OpenHandles/DokanyFileHandle.cs Translate plaintext locks to ciphertext
src/Core/SecureFolderFS.Core.Dokany/DokanyFileSystem.cs Pass security into handles manager
src/Core/SecureFolderFS.Core.Dokany/Callbacks/OnDeviceDokany.cs Reliability + atomic replace move
src/Core/SecureFolderFS.Core.Dokany/Callbacks/BaseDokanyCallbacks.cs Lock stream ops + improved error mapping
src/Core/SecureFolderFS.Core.Dokany/AppModels/DokanyOptions.cs Disable filename caching by default

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs Outdated
Comment thread src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs
Comment thread src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs
Comment thread src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs Outdated

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 89 out of 99 changed files in this pull request and generated 2 comments.

Comment thread src/Core/SecureFolderFS.Core.WebDav/WebDavWrapper.cs
Comment thread src/Core/SecureFolderFS.Core.FileSystem/UniversalCache.cs Outdated
@d2dyno1 d2dyno1 requested a review from Copilot July 4, 2026 21:36
@d2dyno1 d2dyno1 marked this pull request as ready for review July 4, 2026 21:36

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@d2dyno1 d2dyno1 requested a review from Copilot July 4, 2026 21:37

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@d2dyno1

d2dyno1 commented Jul 4, 2026

Copy link
Copy Markdown
Member Author

Weird

@d2dyno1 d2dyno1 added the approved The pull request has been reviewed and approved label Jul 4, 2026
@d2dyno1 d2dyno1 merged commit ff4069f into master Jul 4, 2026
49 checks passed
@d2dyno1 d2dyno1 deleted the general_fs_fixes branch July 4, 2026 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved The pull request has been reviewed and approved

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants