You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Mutual encrypted sharing doesn't work (both sides with password) #8277
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussion
Please forgive me if I'm wrong here, but I remember this being mentioned on the forum as untested, but as something that "should still work". However, in my testing, it seems to always fail with a "generic error".
On Device 1, add a new folder filled with some files to Syncthing.
Share the folder with Device 2, setting a password on it.
On Device 2, accept the folder, but change the type to "Send & Receive", while also inputting the same password.
The two devices connect and try to sync the files, but the process fails with a "generic error".
All testing was done under Windows 10, on two different PCs. The problem isn't limited to the latest code either, as I've tested Syncthing versions up to v1.18.6, and the same errors pop up on all of them.
I think it's meant to disallow any other folder type as long as the password is empty. Maybe that logic is missing or broken in the GUI code. What would be the purpose for choosing other types without giving the password?
Can you elaborate? I'm not sure I quite understand. Just to be clear, here we're talking about a situation where both sides have been given the password.
To be more specific,
SR/RO (password) --> RE (no password) - syncs fine
RE (no password) --> SR/RO (password) - syncs fine
SR/RO (password) --> SR/RO (password) - generic error
I thought you were talking about a situation where the password is not given on one side.
Oh no, when there is no password, the devices don't even connect displaying an error message. The problem happens only when there is the same password on both sides, yet neither of the two folder types is set to Receive Encrypted.
Aren't your first two examples the same, just backwards?
Yeah, it's the same thing eventually, but I just wanted to point out the direction of sharing the folder in case there's any difference in relation to it.
same password on both sides, yet neither of the two folder types is set to Receive Encrypted.
This is something that used to work, sort off, but it was never a designed feature as there is no point to it (?), so it may have been broken by subsequently added checks.
but it was never a designed feature as there is no point to it (?)
I was actually thinking about this as a possible short-term solution, e.g. when we've a local Receive Encrypted folder that was shared with us previously. One day, we decide that we don't want to encrypt the files anymore and would rather prefer to have it set as SR or RO. However, the original device is located in a place that we've got no immediate access to. Then, at least temporarily, we could just input the original password and sync the folder unencrypted.
I don't think there's a good reason for it to not work, so it's probably just a question of figuring out why it doesn't. (And perhaps figuring out a way to add a test.)
changed the title [-]Syncing a password-protected folder between two devices fails with "generic error" when set to something else than "Receive Encrypted"[/-][+]Mutual encrypted sharing doesn't work (both sides with password)[/+]on Mar 10, 2023
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussion
Activity
acolomb commentedon Apr 13, 2022
I think it's meant to disallow any other folder type as long as the password is empty. Maybe that logic is missing or broken in the GUI code. What would be the purpose for choosing other types without giving the password?
tomasz1986 commentedon Apr 13, 2022
Can you elaborate? I'm not sure I quite understand. Just to be clear, here we're talking about a situation where both sides have been given the password.
To be more specific,
SR/RO (password) --> RE (no password) - syncs fine
RE (no password) --> SR/RO (password) - syncs fine
SR/RO (password) --> SR/RO (password) - generic error
acolomb commentedon Apr 14, 2022
I thought you were talking about a situation where the password is not given on one side. Aren't your first two examples the same, just backwards?
tomasz1986 commentedon Apr 14, 2022
Oh no, when there is no password, the devices don't even connect displaying an error message. The problem happens only when there is the same password on both sides, yet neither of the two folder types is set to Receive Encrypted.
Yeah, it's the same thing eventually, but I just wanted to point out the direction of sharing the folder in case there's any difference in relation to it.
calmh commentedon Apr 15, 2022
This is something that used to work, sort off, but it was never a designed feature as there is no point to it (?), so it may have been broken by subsequently added checks.
tomasz1986 commentedon Apr 15, 2022
I was actually thinking about this as a possible short-term solution, e.g. when we've a local Receive Encrypted folder that was shared with us previously. One day, we decide that we don't want to encrypt the files anymore and would rather prefer to have it set as SR or RO. However, the original device is located in a place that we've got no immediate access to. Then, at least temporarily, we could just input the original password and sync the folder unencrypted.
calmh commentedon Apr 15, 2022
Yeah I could see that being a use case. It's gotta be a small corner of the already small niche though.
tomasz1986 commentedon Apr 15, 2022
That's obviously true 😉. If too difficult or complex to implement, then at least having a useful error message would be nice regardless.
calmh commentedon Apr 15, 2022
I don't think there's a good reason for it to not work, so it's probably just a question of figuring out why it doesn't. (And perhaps figuring out a way to add a test.)
kuzaro commentedon Feb 6, 2023
imsodin commentedon Feb 6, 2023
[-]Syncing a password-protected folder between two devices fails with "generic error" when set to something else than "Receive Encrypted"[/-][+]Mutual encrypted sharing doesn't work (both sides with password)[/+]lib/protocol: Correctly request encrypted block (fixes syncthing#8277)
lib/protocol: Handle encrypted requests without encrypted hash (fixes s…
Merge branch 'main' into windowsfixtests
lib/protocol: Handle encrypted requests without encrypted hash (fixes s…