buttercup / buttercup-browser-extension

:earth_asia: Buttercup browser extension
https://buttercup.pw
MIT License
228 stars 42 forks source link

Duplicate entry for the vault #358

Closed eandersons closed 3 years ago

eandersons commented 4 years ago

After one of recent releases (I think it was the one that asked for additional permissions) a duplicate vault entry appeared in the vault list and it cannot be unlocked. I removed the unnecessary vault, but it keeps to reappear after the extension has been disabled and reenabled and after the browser has been closed and reopened.

Details:

rvtb commented 4 years ago

I have the same issue. Some duplicate vault entries appear in the vault list. I can delete them, but they reappear every time the browser or extension is restarted.

OS : Linux and Windows 10 Browser : Firefox 79.0 Extension version : 2.20.1

fifal commented 4 years ago

I have the same issue. I have one original vault and two duplicates. I have tried to delete the duplicates, but they reappear again after the browser is restarted.

OS: Windows 10 Browser: Firefox 79.0 Extension version: 2.20.1

perry-mitchell commented 4 years ago

I think the issue is with sync'ing, but it works fine in Chrome for me. Maybe Firefox managing sync'ing differently. I'll mark this as a bug but I won't have bandwidth to debug it for some time. I'd appreciate help on this if anyone is comfortable debugging it themselves.

eandersons commented 4 years ago

It indeed was Firefox specific issue. There are no duplicate vaults in Firefox Developer Edition 80.0b8 anymore both on Windows 10 and macOS Catalina.

houdini69 commented 4 years ago

I have the same issue with two duplicated vaults reappearing when Firefox is restarted. I tried to add another vault to no avail. The two duplicated vaults couldn't be opened. OS: macOS 10.13.6 Brower: Firefox 79.0 (64 bits) Extension version: 2.20.2 Is there any "preference" files to remove in Firefox profile as removing Buttercup extension and reinstalling it doesn't solve this issue?

houdini69 commented 4 years ago

I have installed successfully Buttercup and a vault in another Firefox profile without duplicated vaults so this bug seems not linked to Firefox.

In my case this issue appeared when I wanted to change the vault type with the same name for the vault (WebDav Nextcloud to WebDav native server). I get duplicated vaults prompts each time with error 404. I can remove them and add a new one but each time I restart Firefox I get the duplicated vaults prompts...

houdini69 commented 4 years ago

I finally reset my Firefox working profile and the duplicated vaults disappeared. However, a new created webdav type vault isn't saved when restarting Firefox.

rvtb commented 3 years ago

I just did a test again, and the problem no longer appears. I think it's related to updating Firefox to version 80.0.

OS : Linux and Windows 10 Browser : Firefox 80.0 Extension version : 2.21.0

eandersons commented 3 years ago

I think the issue is with sync'ing, but it works fine in Chrome for me. Maybe Firefox managing sync'ing differently. I'll mark this as a bug but I won't have bandwidth to debug it for some time. I'd appreciate help on this if anyone is comfortable debugging it themselves.

Yes, this is related to Firefox Sync as extensions and their data is being synchronised. My solution is to give distinctive vault names so I know which is the correct one to unlock on the current computer, and this behaviour is not bothering me anymore. For example:

Vaults unlock page can get quite messy though if there are multiple vaults that are used on different computers and Firefox browser is the main browser on all of them with Firefox Sync enabled.

perry-mitchell commented 3 years ago

My solution is to give distinctive vault names so I know which is the correct one to unlock on the current computer

Another way to mitigate this issue would be to offer a storage choice when creating a vault: https://github.com/buttercup/buttercup-browser-extension/issues/390

I'll close in favour of #390 as it sounds like this issue is with earlier FF versions. Sync is tricky and we obviously need to improve the logic there.

If anyone can reproduce this issue with newer FF versions I'll happily reopen.

eandersons commented 3 years ago

This still happens with extesion version 2.23.1 and Firefox 84.0. I removed all local vaults from extension (actually one vault that was added from multiple computers) and added one again. After a short time it appeared in synced Firefox on another computer and it canot be unlocked. Should there be done something else before adding the vault again?

Anyway, it seems that #390 would be a good solution.

perry-mitchell commented 3 years ago

@eandersons Local vaults cannot be opened from other computers because they cannot have the same local vault setup. So yeah, this will be solved with #390 - I don't see any other way of handling it. It's not a sync issue but rather just a limitation of using local vault sync. In our opinion it's better to use real datasources where possible, though we provide local sync for work arounds in other situations.