syncthing/syncthing-macos

Unable to login on fresh install did set gui user and password properties in config.xml

slfhstr opened this issue · 11 comments

Fresh install on Mac Ventura 13.3.1
Can't login to GUI without username and password.
But none set during installation.
No info in docs.

Stop syncthing, and remove the Syncthing folder under ~/Library/Application Support with Finder -> Go -> Go to folder. Then start again and see what happens.

The config.xml in that folder did contain for some odd reason the user and password properties. Which is not default.

    <gui enabled="true" tls="false" debugging="false">
        <address>0.0.0.0:8384</address>
        <user>jerry</user>
        <password>$2a$10$rA9nA5378muXjCngW1iyeu66esWdNtKJarO1vZ.R/wtnWML2Pe4eD</password>
        <apikey>PNNh6CJzTNAGyp7zYsxFXizJdRDwxdVg</apikey>
        <theme>default</theme>
    </gui>

Thank you.
Deleted folder, restarted app.
Folder regenerated.
App starts but shows error in its icon in Mac menu
Trying to open GUI throws up auth box, but blank values not accepted
No info on how to set the username and password

The regenerated folder and config.yml have no entries in section for username and password.

Try to open the config.xml with TextEdit and look for the gui section, then remove the user and password properties. The syncthing macos tray shows error because the API key has changed. It should be set from the apikey property in the config.xml in the Tray icon -> Preferences -> API Key. Then syncthing must be stopped and started again. Hope this helps

I ran through loop of quitting app. deleting folder, starting again, checking config.yml username / password properties, trying with no entries for these and then manually creating them with a crypt hash.
Nothing worked (well, app ran but no login to GUI page was possible)

Checked the logs ...
It seems the app defaults to https://127.0.0.1:8384 as URL for GUI.
BUT .... the logs show that GUI is available on a different port 127.0.0.1:58209

If this port is used, I can access the GUI with manually created username and password.

But I can't set the port through the GUI preferences - reverts to :8384 all the time.
No save button in Preferences.
Can't see where to set it in config.yml.

Working now (subject to actually testing sync between devices)

Can I suggest/request enhancement to standardise on port used

It seems the Open under the menu dropdown and also the Open Synching Web Interface are hard-coded to :8384
Even if the Preferences shows :58209

You should use the Test button when setting the URI to a different IP/port then 127.0.0.1:8384. Then it saves when the circle is green.

Thank you
Did that by luck !

If it works I close the issue, feel free to comment when something is still unclear.

Be aware that deleting the ~/Library/Application Support/Syncthing folder removes the whole configuration. If you forgot your password and trying to reagain access it may be better to try deleting the user/password entries first, I can't confirm because I've now unfortunately nuked my whole config.