Compare commits

...

10 Commits

Author SHA1 Message Date
Jakob Borg
5d8033343f chore: repo mirror job 2025-08-11 22:16:10 +02:00
Jakob Borg
c74d2a9872 chore: update man pages for 2.0 2025-08-11 19:33:32 +02:00
Jakob Borg
3da84804b6 build: just special case stable-v2 for Debian for now 2025-08-11 19:17:33 +02:00
Jakob Borg
5b75c6ddcb build: split apt archive into major version generations 2025-08-11 18:57:18 +02:00
Syncthing Release Automation
ae03854575 chore(gui, man, authors): update docs, translations, and contributors 2025-08-11 04:06:30 +00:00
tomasz1986
ad196173d0 chore(gui): remove redundant "authenticated" conditions from Actions menu (#10235) (#10237)
chore(gui): remove redundant "authenticated" conditions from Actions
menu (#10235)

Due to previous code changes, the whole Actions menu is only available
when the user is logged in. As such, there is no reason to have the same
ng-if="authenticated" condition repeated in other items belonging to it.

Signed-off-by: Tomasz Wilczyński <twilczynski@naver.com>

Signed-off-by: Tomasz Wilczyński <twilczynski@naver.com>
2025-08-10 22:13:53 +02:00
Jakob Borg
d682220305 chore: remove GUI "debugging" toggle, debug HTTP metrics (#10235)
This removes the `debugging` bool under GUI configuration, and two no
longer relevant development endpoints: `httpmetrics` (which I can't
imagine anyone using for anything -- if we need such metrics today, the
right place is the Prometheus exported metrics) and the `peerCompletion`
endpoint (previously used by integration tests).

The debugging bool initially enabled just those two endpoints, which are
not for end users. Then we added profiling and support bundles, which
are very useful indeed for end users to access, and they were hidden
behind the same debug flag. I don't see any reason for keeping that flag
now that these methods are more generally useful.

https://github.com/syncthing/docs/pull/949
2025-08-10 21:14:25 +02:00
Jakob Borg
29e10e00d2 chore(slogutil): ensure quoting of empty and confusing log values (#10236)
Clearer parsing (also for humans)
2025-08-10 08:23:23 +00:00
Jakob Borg
34f61ce464 fix: correct logging of our ID after startup & generate (#10234)
This is one place we actually want the full string.
2025-08-10 06:25:13 +00:00
Ross Smith II
adcbd31e62 fix(test): remove lib/logger from testmocks target (#10231) 2025-08-09 09:56:37 +02:00
30 changed files with 357 additions and 565 deletions

View File

@@ -47,6 +47,7 @@ jobs:
outputs:
version: ${{ steps.get-version.outputs.version }}
release-kind: ${{ steps.get-version.outputs.release-kind }}
release-generation: ${{ steps.get-version.outputs.release-generation }}
go-version: ${{ steps.get-go.outputs.go-version }}
steps:
- uses: actions/checkout@v4
@@ -76,6 +77,12 @@ jobs:
echo "release-kind=$kind" >> "$GITHUB_OUTPUT"
echo "Release kind: $kind"
generation=v1
if [[ $version == v2.* ]] ; then
generation=v2
fi
echo "release-generation=$generation" >> "$GITHUB_OUTPUT"
echo "Release generation: $generation"
- name: Get Go version
id: get-go
run: |
@@ -879,6 +886,7 @@ jobs:
env:
VERSION: ${{ needs.facts.outputs.version }}
RELEASE_KIND: ${{ needs.facts.outputs.release-kind }}
RELEASE_GENERATION: ${{ needs.facts.outputs.release-generation }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
@@ -892,6 +900,9 @@ jobs:
# Decide whether packages should go to stable, candidate or nightly
- name: Prepare packages
run: |
if [[ $RELEASE_KIND == stable && $RELEASE_GENERATION == v2 ]] ; then
RELEASE_KIND=stable-v2
fi
mkdir -p packages/syncthing/$RELEASE_KIND
mv packages/*.deb packages/syncthing/$RELEASE_KIND

18
.github/workflows/mirrors.yaml vendored Normal file
View File

@@ -0,0 +1,18 @@
name: Mirrors
on: [push, delete]
jobs:
codeberg:
name: Mirror to Codeberg
if: github.repository_owner == 'syncthing'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: yesolutions/mirror-action@master
with:
REMOTE: ssh://git@codeberg.org/${{ github.repository }}.git
GIT_SSH_PRIVATE_KEY: ${{ secrets.CODEBERG_PUSH_KEY }}
GIT_SSH_NO_VERIFY_HOST: "true"

View File

@@ -870,7 +870,6 @@ func testmocks() {
"github.com/syncthing/syncthing/lib/connections",
"github.com/syncthing/syncthing/lib/discover",
"github.com/syncthing/syncthing/lib/events",
"github.com/syncthing/syncthing/lib/logger",
"github.com/syncthing/syncthing/lib/model",
"github.com/syncthing/syncthing/lib/protocol",
}

View File

@@ -12,6 +12,7 @@ import (
"context"
"crypto/tls"
"fmt"
"log/slog"
"os"
"github.com/syncthing/syncthing/lib/config"
@@ -20,7 +21,6 @@ import (
"github.com/syncthing/syncthing/lib/locations"
"github.com/syncthing/syncthing/lib/protocol"
"github.com/syncthing/syncthing/lib/syncthing"
"golang.org/x/exp/slog"
)
type CLI struct {
@@ -61,15 +61,16 @@ func Generate(confDir, guiUser, guiPassword string, skipPortProbing bool) error
certFile, keyFile := locations.Get(locations.CertFile), locations.Get(locations.KeyFile)
cert, err := tls.LoadX509KeyPair(certFile, keyFile)
if err == nil {
slog.Warn("Key exists; will not overwrite.")
slog.Warn("Key exists; will not overwrite")
} else {
cert, err = syncthing.GenerateCertificate(certFile, keyFile)
if err != nil {
return fmt.Errorf("create certificate: %w", err)
}
}
myID = protocol.NewDeviceID(cert.Certificate[0])
slog.Info("Genereated new keypair", myID.LogAttr())
slog.Info("Calculated device ID", slog.String("device", myID.String()))
cfgFile := locations.Get(locations.ConfigFile)
cfg, _, err := config.Load(cfgFile, myID, events.NoopLogger)

View File

@@ -82,6 +82,7 @@
"Custom Range": "Custom Range",
"Danger!": "Danger!",
"Database Location": "Database Location",
"Debug": "Debug",
"Debugging Facilities": "Debugging Facilities",
"Default": "Default",
"Default Configuration": "Default Configuration",
@@ -210,6 +211,7 @@
"Incoming Rate Limit (KiB/s)": "Incoming Rate Limit (KiB/s)",
"Incorrect configuration may damage your folder contents and render Syncthing inoperable.": "Incorrect configuration may damage your folder contents and render Syncthing inoperable.",
"Incorrect user name or password.": "Incorrect user name or password.",
"Info": "Info",
"Internally used paths:": "Internally used paths:",
"Introduced By": "Introduced By",
"Introducer": "Introducer",

View File

@@ -108,27 +108,23 @@
<li><a href="" ng-click="about.show()"><span class="fa fa-fw fa-heart"></span>&nbsp;<span translate>About</span></a></li>
</ul>
</li>
<li ng-if="authenticated || config.gui.debugging" class="dropdown action-menu">
<li ng-if="authenticated" class="dropdown action-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
<span class="fa fa-cog"></span>
<span class="hidden-xs" translate>Actions</span>
<span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li ng-if="authenticated"><a href="" ng-click="showSettings()"><span class="fa fa-fw fa-cog"></span>&nbsp;<span translate>Settings</span></a></li>
<li ng-if="authenticated"><a href="" ng-click="showDeviceIdentification(thisDevice())"><span class="fa fa-fw fa-qrcode"></span>&nbsp;<span translate>Show ID</span></a></li>
<li ng-if="authenticated" class="divider" aria-hidden="true"></li>
<li ng-if="authenticated"><a href="" ng-click="advanced()"><span class="fa fa-fw fa-cogs"></span>&nbsp;<span translate>Advanced</span></a></li>
<li ng-if="authenticated"><a href="" ng-click="logging.show()"><span class="fa fa-fw fa-wrench"></span>&nbsp;<span translate>Logs</span></a></li>
<li class="divider" aria-hidden="true" ng-if="config.gui.debugging"></li>
<li><a href="/rest/debug/support" target="_blank" ng-if="config.gui.debugging"><span class="fa fa-fw fa-user-md"></span>&nbsp;<span translate>Support Bundle</span></a></li>
<li ng-if="authenticated" class="divider" aria-hidden="true"></li>
<li ng-if="authenticated && isAuthEnabled()"><a href="" ng-click="logout()"><span class="far fa-fw fa-sign-out"></span>&nbsp;<span translate>Log Out</span></a></li>
<li ng-if="authenticated"><a href="" ng-click="restart()"><span class="fa fa-fw fa-refresh"></span>&nbsp;<span translate>Restart</span></a></li>
<li ng-if="authenticated"><a href="" ng-click="shutdown()"><span class="fa fa-fw fa-power-off"></span>&nbsp;<span translate>Shut Down</span></a></li>
<li><a href="" ng-click="showSettings()"><span class="fa fa-fw fa-cog"></span>&nbsp;<span translate>Settings</span></a></li>
<li><a href="" ng-click="advanced()"><span class="fa fa-fw fa-cogs"></span>&nbsp;<span translate>Advanced</span></a></li>
<li class="divider" aria-hidden="true"></li>
<li><a href="" ng-click="showDeviceIdentification(thisDevice())"><span class="fa fa-fw fa-qrcode"></span>&nbsp;<span translate>Show ID</span></a></li>
<li><a href="" ng-click="logging.show()"><span class="fa fa-fw fa-wrench"></span>&nbsp;<span translate>Logs</span></a></li>
<li><a href="/rest/debug/support" target="_blank"><span class="fa fa-fw fa-user-md"></span>&nbsp;<span translate>Support Bundle</span></a></li>
<li class="divider" aria-hidden="true"></li>
<li ng-if="isAuthEnabled()"><a href="" ng-click="logout()"><span class="far fa-fw fa-sign-out"></span>&nbsp;<span translate>Log Out</span></a></li>
<li><a href="" ng-click="restart()"><span class="fa fa-fw fa-refresh"></span>&nbsp;<span translate>Restart</span></a></li>
<li><a href="" ng-click="shutdown()"><span class="fa fa-fw fa-power-off"></span>&nbsp;<span translate>Shut Down</span></a></li>
</ul>
</li>
</ul>

View File

@@ -116,6 +116,7 @@ func expandAttrs(prefix string, a slog.Attr) []slog.Attr {
}
func appendAttr(sb *strings.Builder, prefix string, a slog.Attr, attrCount *int) {
const confusables = ` "()[]{},`
if a.Key == "" {
return
}
@@ -127,7 +128,7 @@ func appendAttr(sb *strings.Builder, prefix string, a slog.Attr, attrCount *int)
sb.WriteString(a.Key)
sb.WriteRune('=')
v := a.Value.Resolve().String()
if strings.ContainsAny(v, ` "()`) {
if v == "" || strings.ContainsAny(v, confusables) {
v = strconv.Quote(v)
}
sb.WriteString(v)

View File

@@ -24,6 +24,7 @@ func TestFormattingHandler(t *testing.T) {
l := slog.New(h).With("a", "a")
l.Info("A basic info line", "attr1", "val with spaces", "attr2", 2, "attr3", `val"quote`)
l.Info("A basic info line", "attr1", "paren)thesis")
l.Info("An info line with an empty value", "attr1", "")
l.Info("An info line with grouped values", "attr1", "val1", slog.Group("foo", "attr2", 2, slog.Group("bar", "attr3", "3")))
l2 := l.WithGroup("foo")
@@ -39,6 +40,7 @@ func TestFormattingHandler(t *testing.T) {
exp := `
2009-02-13 23:31:30 INF A basic info line (attr1="val with spaces" attr2=2 attr3="val\"quote" a=a log.pkg=slogutil)
2009-02-13 23:31:30 INF A basic info line (attr1="paren)thesis" a=a log.pkg=slogutil)
2009-02-13 23:31:30 INF An info line with an empty value (attr1="" a=a log.pkg=slogutil)
2009-02-13 23:31:30 INF An info line with grouped values (attr1=val1 foo.attr2=2 foo.bar.attr3=3 a=a log.pkg=slogutil)
2009-02-13 23:31:30 INF An info line with grouped values via logger (foo.attr1=val1 foo.attr2=2 a=a log.pkg=slogutil)
2009-02-13 23:31:30 INF An info line with nested grouped values via logger (bar.foo.attr1=val1 bar.foo.attr2=2 a=a log.pkg=slogutil)

View File

@@ -36,7 +36,6 @@ import (
"github.com/calmh/incontainer"
"github.com/julienschmidt/httprouter"
"github.com/prometheus/client_golang/prometheus/promhttp"
"github.com/rcrowley/go-metrics"
"github.com/thejerf/suture/v4"
"github.com/vitrun/qart/qr"
"golang.org/x/text/runes"
@@ -336,16 +335,14 @@ func (s *service) Serve(ctx context.Context) error {
// Debug endpoints, not for general use
debugMux := http.NewServeMux()
debugMux.HandleFunc("/rest/debug/peerCompletion", s.getPeerCompletion)
debugMux.HandleFunc("/rest/debug/httpmetrics", s.getSystemHTTPMetrics)
debugMux.HandleFunc("/rest/debug/cpuprof", s.getCPUProf) // duration
debugMux.HandleFunc("/rest/debug/heapprof", s.getHeapProf)
debugMux.HandleFunc("/rest/debug/support", s.getSupportBundle)
debugMux.HandleFunc("/rest/debug/file", s.getDebugFile)
restMux.Handler(http.MethodGet, "/rest/debug/*method", s.whenDebugging(debugMux))
restMux.Handler(http.MethodGet, "/rest/debug/*method", debugMux)
// A handler that disables caching
noCacheRestMux := noCacheMiddleware(metricsMiddleware(restMux))
noCacheRestMux := noCacheMiddleware(restMux)
// The main routing handler
mux := http.NewServeMux()
@@ -489,9 +486,6 @@ func (*service) VerifyConfiguration(_, to config.Configuration) error {
}
func (s *service) CommitConfiguration(from, to config.Configuration) bool {
// No action required when this changes, so mask the fact that it changed at all.
from.GUI.Debugging = to.GUI.Debugging
if to.GUI == from.GUI {
// No GUI changes, we're done here.
return true
@@ -594,15 +588,6 @@ func corsMiddleware(next http.Handler, allowFrameLoading bool) http.Handler {
})
}
func metricsMiddleware(h http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
t := metrics.GetOrRegisterTimer(r.URL.Path, nil)
t0 := time.Now()
h.ServeHTTP(w, r)
t.UpdateSince(t0)
})
}
func redirectToHTTPSMiddleware(h http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
if r.TLS == nil {
@@ -644,17 +629,6 @@ func localhostMiddleware(h http.Handler) http.Handler {
})
}
func (s *service) whenDebugging(h http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
if s.cfg.GUI().Debugging {
h.ServeHTTP(w, r)
return
}
http.Error(w, "Debugging disabled", http.StatusForbidden)
})
}
func (s *service) getPendingDevices(w http.ResponseWriter, _ *http.Request) {
devices, err := s.model.PendingDevices()
if err != nil {
@@ -1284,26 +1258,6 @@ func (s *service) getSupportBundle(w http.ResponseWriter, r *http.Request) {
io.Copy(w, &zipFilesBuffer)
}
func (*service) getSystemHTTPMetrics(w http.ResponseWriter, _ *http.Request) {
stats := make(map[string]interface{})
metrics.Each(func(name string, intf interface{}) {
if m, ok := intf.(*metrics.StandardTimer); ok {
pct := m.Percentiles([]float64{0.50, 0.95, 0.99})
for i := range pct {
pct[i] /= 1e6 // ns to ms
}
stats[name] = map[string]interface{}{
"count": m.Count(),
"sumMs": m.Sum() / 1e6, // ns to ms
"ratesPerS": []float64{m.Rate1(), m.Rate5(), m.Rate15()},
"percentilesMs": pct,
}
}
})
bs, _ := json.MarshalIndent(stats, "", " ")
w.Write(bs)
}
func (s *service) getSystemDiscovery(w http.ResponseWriter, _ *http.Request) {
devices := make(map[string]discover.CacheEntry)
@@ -1628,35 +1582,6 @@ func (*service) getQR(w http.ResponseWriter, r *http.Request) {
w.Write(code.PNG())
}
func (s *service) getPeerCompletion(w http.ResponseWriter, _ *http.Request) {
tot := map[string]float64{}
count := map[string]float64{}
for _, folder := range s.cfg.Folders() {
for _, device := range folder.DeviceIDs() {
deviceStr := device.String()
if s.model.ConnectedTo(device) {
comp, err := s.model.Completion(device, folder.ID)
if err != nil {
http.Error(w, err.Error(), http.StatusInternalServerError)
return
}
tot[deviceStr] += comp.CompletionPct
} else {
tot[deviceStr] = 0
}
count[deviceStr]++
}
}
comp := map[string]int{}
for device := range tot {
comp[device] = int(tot[device] / count[device])
}
sendJSON(w, comp)
}
func (s *service) getFolderVersions(w http.ResponseWriter, r *http.Request) {
qs := r.URL.Query()
versions, err := s.model.GetFolderVersions(qs.Get("folder"))

View File

@@ -30,7 +30,6 @@ type GUIConfiguration struct {
APIKey string `json:"apiKey" xml:"apikey,omitempty"`
InsecureAdminAccess bool `json:"insecureAdminAccess" xml:"insecureAdminAccess,omitempty"`
Theme string `json:"theme" xml:"theme" default:"default"`
Debugging bool `json:"debugging" xml:"debugging,attr"`
InsecureSkipHostCheck bool `json:"insecureSkipHostcheck" xml:"insecureSkipHostcheck,omitempty"`
InsecureAllowFrameLoading bool `json:"insecureAllowFrameLoading" xml:"insecureAllowFrameLoading,omitempty"`
SendBasicAuthPrompt bool `json:"sendBasicAuthPrompt" xml:"sendBasicAuthPrompt,attr"`

View File

@@ -136,7 +136,7 @@ func (a *App) startup() error {
// Figure out our device ID and log it.
a.myID = protocol.NewDeviceID(a.cert.Certificate[0])
slog.Info("Calculated our device ID", a.myID.LogAttr())
slog.Info("Calculated our device ID", slog.String("device", a.myID.String()))
// Emit the Starting event, now that we know who we are.

View File

@@ -308,9 +308,6 @@ func (s *Service) reportData(ctx context.Context, urVersion int, preview bool) (
if guiCfg.InsecureAdminAccess {
report.GUIStats.InsecureAdminAccess++
}
if guiCfg.Debugging {
report.GUIStats.Debugging++
}
if guiCfg.InsecureSkipHostCheck {
report.GUIStats.InsecureSkipHostCheck++
}

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "STDISCOSRV" "1" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "STDISCOSRV" "1" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
stdiscosrv \- Syncthing Discovery Server
.SH SYNOPSIS
@@ -394,6 +394,6 @@ the discovery server and your particular setup.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "STRELAYSRV" "1" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "STRELAYSRV" "1" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
strelaysrv \- Syncthing Relay Server
.SH SYNOPSIS
@@ -317,6 +317,6 @@ relay://<host name|IP>[:port]/?id=<relay device ID>&token=mySecretToken
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -28,7 +28,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-BEP" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-BEP" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-bep \- Block Exchange Protocol v1
.SH INTRODUCTION AND DEFINITIONS
@@ -267,13 +267,11 @@ message ClusterConfig {
}
message Folder {
string id = 1;
string label = 2;
bool read_only = 3;
bool ignore_permissions = 4;
bool ignore_delete = 5;
bool disable_temp_indexes = 6;
bool paused = 7;
string id = 1;
string label = 2;
FolderType type = 3;
FolderStopReason stop_reason = 7;
reserved 4 to 6;
repeated Device devices = 16;
}
@@ -296,6 +294,18 @@ enum Compression {
NEVER = 1;
ALWAYS = 2;
}
enum FolderType {
FOLDER_TYPE_SEND_RECEIVE = 0;
FOLDER_TYPE_SEND_ONLY = 1;
FOLDER_TYPE_RECEIVE_ONLY = 2;
FOLDER_TYPE_RECEIVE_ENCRYPTED = 3;
}
enum FolderStopReason {
FOLDER_STOP_REASON_RUNNING = 0;
FOLDER_STOP_REASON_PAUSED = 1;
}
.EE
.UNINDENT
.UNINDENT
@@ -311,20 +321,12 @@ the folder.
The \fBlabel\fP field contains the folder label, the human readable name of
the folder.
.sp
The \fBread_only\fP field is set for folders that the device will accept no
updates from the network for.
The \fBfolder_type\fP field contains the type of the folder as defined by the
FolderType enumeration.
.sp
The \fBignore_permissions\fP field is set for folders that the device will not
accept or announce file permissions for.
.sp
The \fBignore_delete\fP field is set for folders that the device will ignore
deletes for.
.sp
The \fBdisable_temp_indexes\fP field is set for folders that will not dispatch
and do not wish to receive progress updates about partially downloaded files
via Download Progress messages.
.sp
The \fBpaused\fP field is set for folders that are currently paused.
The \fBstop_reason\fP field is set for folders that are currently stopped for
any reason. The zero means that the folder is not stopped; further reasons
are defined by the FolderStopReason enumeration.
.sp
The \fBdevices\fP field is a list of devices participating in sharing this
folder.
@@ -430,10 +432,10 @@ enum FileInfoType {
}
message BlockInfo {
int64 offset = 1;
int32 size = 2;
bytes hash = 3;
uint32 weak_hash = 4;
int64 offset = 1;
int32 size = 2;
bytes hash = 3;
reserved 4;
}
message Vector {
@@ -536,6 +538,8 @@ message Request {
int32 size = 5;
bytes hash = 6;
bool from_temporary = 7;
int32 block_no = 9;
reserved 8;
}
.EE
.UNINDENT
@@ -1053,6 +1057,6 @@ process occurs for device A at 15.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-CONFIG" "5" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-CONFIG" "5" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-config \- Syncthing Configuration
.SH SYNOPSIS
@@ -89,9 +89,9 @@ corresponding environment variables (\fB$STDATADIR\fP or \fBSTHOMEDIR\fP).
The database directory contains the following files, among others:
.INDENT 0.0
.TP
.B \fBindex\-\fP\fI*\fP\fB\&.db\fP
A directory holding the database with metadata and hashes of the files
currently on disk and available from peers.
.B \fBindex\-\fP\fI*\fP
The database with metadata and hashes of the files currently on disk and
available from peers.
.TP
.B \fBsyncthing.log\fP
Log output, on some systems.
@@ -139,9 +139,7 @@ may no longer correspond to the defaults.
<pullerPauseS>0</pullerPauseS>
<maxConflicts>\-1</maxConflicts>
<disableSparseFiles>false</disableSparseFiles>
<disableTempIndexes>false</disableTempIndexes>
<paused>false</paused>
<weakHashThresholdPct>25</weakHashThresholdPct>
<markerName>.stfolder</markerName>
<copyOwnershipFromParent>false</copyOwnershipFromParent>
<modTimeWindowS>0</modTimeWindowS>
@@ -167,7 +165,7 @@ may no longer correspond to the defaults.
<untrusted>false</untrusted>
<remoteGUIPort>0</remoteGUIPort>
</device>
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq debugging=\(dqfalse\(dq>
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq>
<address>127.0.0.1:8384</address>
<apikey>k1dnz1Dd0rzTBjjFFh7CXPnrF12C49B1</apikey>
<theme>default</theme>
@@ -215,7 +213,6 @@ may no longer correspond to the defaults.
<stunKeepaliveStartS>180</stunKeepaliveStartS>
<stunKeepaliveMinS>20</stunKeepaliveMinS>
<stunServer>default</stunServer>
<databaseTuning>auto</databaseTuning>
<maxConcurrentIncomingRequestKiB>0</maxConcurrentIncomingRequestKiB>
<announceLANAddresses>true</announceLANAddresses>
<sendFullIndexOnUpgrade>false</sendFullIndexOnUpgrade>
@@ -244,9 +241,7 @@ may no longer correspond to the defaults.
<pullerPauseS>0</pullerPauseS>
<maxConflicts>10</maxConflicts>
<disableSparseFiles>false</disableSparseFiles>
<disableTempIndexes>false</disableTempIndexes>
<paused>false</paused>
<weakHashThresholdPct>25</weakHashThresholdPct>
<markerName>.stfolder</markerName>
<copyOwnershipFromParent>false</copyOwnershipFromParent>
<modTimeWindowS>0</modTimeWindowS>
@@ -336,9 +331,7 @@ GUI.
<pullerPauseS>0</pullerPauseS>
<maxConflicts>\-1</maxConflicts>
<disableSparseFiles>false</disableSparseFiles>
<disableTempIndexes>false</disableTempIndexes>
<paused>false</paused>
<weakHashThresholdPct>25</weakHashThresholdPct>
<markerName>.stfolder</markerName>
<copyOwnershipFromParent>false</copyOwnershipFromParent>
<modTimeWindowS>0</modTimeWindowS>
@@ -580,26 +573,11 @@ sparse files will not be created.
.UNINDENT
.INDENT 0.0
.TP
.B disableTempIndexes
By default, devices exchange information about blocks available in
transfers that are still in progress, which allows other devices to
download parts of files that are not yet fully downloaded on your own
device, essentially making transfers more torrent like. When set to
\fBtrue\fP, such information is not exchanged for this folder.
.UNINDENT
.INDENT 0.0
.TP
.B paused
True if this folder is (temporarily) suspended.
.UNINDENT
.INDENT 0.0
.TP
.B weakHashThresholdPct
Use weak hash if more than the given percentage of the file has changed. Set
to \fB\-1\fP to always use weak hash. Default is \fB25\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B markerName
Name of a directory or file in the folder root to be used as a marker \- see
\fI\%marker FAQ\fP for its purpose.
@@ -945,7 +923,7 @@ The number of connections to this device. See
.INDENT 3.5
.sp
.EX
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq debugging=\(dqfalse\(dq>
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq>
<address>127.0.0.1:8384</address>
<apikey>k1dnz1Dd0rzTBjjFFh7CXPnrF12C49B1</apikey>
<theme>default</theme>
@@ -969,12 +947,6 @@ If set to \fBtrue\fP, TLS (HTTPS) will be enforced. Non\-HTTPS requests will
be redirected to HTTPS. When set to \fBfalse\fP, TLS connections are
still possible but not required.
.UNINDENT
.INDENT 0.0
.TP
.B debugging
This enables \fI\%Profiling\fP and additional endpoints in the REST
API, see \fI\%Debug Endpoints\fP\&.
.UNINDENT
.sp
The following child elements may be present:
.INDENT 0.0
@@ -1196,7 +1168,6 @@ Search filter for user searches.
<stunKeepaliveStartS>180</stunKeepaliveStartS>
<stunKeepaliveMinS>20</stunKeepaliveMinS>
<stunServer>default</stunServer>
<databaseTuning>auto</databaseTuning>
<maxConcurrentIncomingRequestKiB>0</maxConcurrentIncomingRequestKiB>
<announceLANAddresses>true</announceLANAddresses>
<sendFullIndexOnUpgrade>false</sendFullIndexOnUpgrade>
@@ -1488,13 +1459,6 @@ troubles. Defaults to \fBtrue\fP, to help the developers troubleshoot.
.UNINDENT
.INDENT 0.0
.TP
.B databaseTuning
Controls how Syncthing uses the backend key\-value database that stores the
index data and other persistent data it needs. The available options and
implications are explained in a \fI\%separate chapter\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B maxConcurrentIncomingRequestKiB
This limits how many bytes we have “in the air” in the form of response data
being read and processed.
@@ -1509,7 +1473,7 @@ addresses to global discovery.
.TP
.B sendFullIndexOnUpgrade
Controls whether all index data is resent when an upgrade has happened,
equivalent to starting Syncthing with \fI\%\-\-reset\-deltas\fP\&. This used
equivalent to starting Syncthing with \fB\-\-reset\-deltas\fP\&. This used
to be the default behavior in older versions, but is mainly useful as a
troubleshooting step and causes high database churn. The default is now
\fBfalse\fP\&.
@@ -1582,9 +1546,7 @@ are set, \fI\%\-\-auditfile\fP takes priority.
<pullerPauseS>0</pullerPauseS>
<maxConflicts>10</maxConflicts>
<disableSparseFiles>false</disableSparseFiles>
<disableTempIndexes>false</disableTempIndexes>
<paused>false</paused>
<weakHashThresholdPct>25</weakHashThresholdPct>
<markerName>.stfolder</markerName>
<copyOwnershipFromParent>false</copyOwnershipFromParent>
<modTimeWindowS>0</modTimeWindowS>
@@ -1732,6 +1694,6 @@ send only mode for just the configuration folder.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-DEVICE-IDS" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-DEVICE-IDS" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-device-ids \- Understanding Device IDs
.sp
@@ -255,6 +255,6 @@ accepting the connection.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-EVENT-API" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-EVENT-API" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-event-api \- Event API
.SH DESCRIPTION
@@ -1116,6 +1116,6 @@ seconds and is now in state \fBidle\fP\&.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-FAQ" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-FAQ" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-faq \- Frequently Asked Questions
.INDENT 0.0
@@ -544,7 +544,7 @@ files \fBqax\fP, \fBqbx\fP and \fBqcx\fP\&.
To match an actual file \fIcalled\fP \fBq[abc]x\fP the pattern needs to “escape”
the brackets, like so: \fBq\e[abc\e]x\fP\&.
.sp
On Windows, escaping special characters is not supported as the \fB\e\fP
On Windows, use the \fB|\fP character to escape the brackets (\fBq|[abc|]x\fP), as the \fB\e\fP
character is used as a path separator.
.SS How do I access the web GUI from another computer?
.sp
@@ -732,7 +732,7 @@ For example, the two emphasized lines below would be removed from the file.
.INDENT 3.5
.sp
.EX
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq debugging=\(dqfalse\(dq>
<gui enabled=\(dqtrue\(dq tls=\(dqfalse\(dq>
<address>127.0.0.1:8384</address>
<user>syncguy</user>
<password>$2a$10$s9wWHOQe...Cq7GPye69</password>
@@ -745,6 +745,6 @@ For example, the two emphasized lines below would be removed from the file.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-GLOBALDISCO" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-GLOBALDISCO" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-globaldisco \- Global Discovery Protocol v3
.SH ANNOUNCEMENTS
@@ -119,6 +119,6 @@ The discovery server prints its certificate ID in this manner on startup.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-LOCALDISCO" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-LOCALDISCO" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-localdisco \- Local Discovery Protocol v4
.SH MODE OF OPERATION
@@ -114,6 +114,6 @@ between two announces and conclude that the announcing device has restarted.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-NETWORKING" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-NETWORKING" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-networking \- Firewall Setup
.SH ROUTER SETUP
@@ -163,6 +163,6 @@ Syncthing can use a SOCKS5 proxy for outbound connections. Please see \fI\%Using
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -28,7 +28,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-RELAY" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-RELAY" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-relay \- Relay Protocol v1
.SH WHAT IS A RELAY?
@@ -695,6 +695,6 @@ T}
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-REST-API" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-REST-API" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-rest-api \- REST API
.sp
@@ -152,9 +152,7 @@ Returns the current configuration.
\(dqpullerPauseS\(dq: 0,
\(dqmaxConflicts\(dq: \-1,
\(dqdisableSparseFiles\(dq: false,
\(dqdisableTempIndexes\(dq: false,
\(dqpaused\(dq: false,
\(dqweakHashThresholdPct\(dq: 25,
\(dqmarkerName\(dq: \(dq.stfolder\(dq,
\(dqcopyOwnershipFromParent\(dq: false,
\(dqmodTimeWindowS\(dq: 0,
@@ -207,7 +205,6 @@ Returns the current configuration.
\(dqapiKey\(dq: \(dqk1dnz1Dd0rzTBjjFFh7CXPnrF12C49B1\(dq,
\(dqinsecureAdminAccess\(dq: false,
\(dqtheme\(dq: \(dqdefault\(dq,
\(dqdebugging\(dq: false,
\(dqinsecureSkipHostcheck\(dq: false,
\(dqinsecureAllowFrameLoading\(dq: false
},
@@ -273,7 +270,6 @@ Returns the current configuration.
\(dqstunServers\(dq: [
\(dqdefault\(dq
],
\(dqdatabaseTuning\(dq: \(dqauto\(dq,
\(dqmaxConcurrentIncomingRequestKiB\(dq: 0,
\(dqannounceLANAddresses\(dq: true,
\(dqsendFullIndexOnUpgrade\(dq: false,
@@ -328,9 +324,7 @@ Returns the current configuration.
\(dqpullerPauseS\(dq: 0,
\(dqmaxConflicts\(dq: 10,
\(dqdisableSparseFiles\(dq: false,
\(dqdisableTempIndexes\(dq: false,
\(dqpaused\(dq: false,
\(dqweakHashThresholdPct\(dq: 25,
\(dqmarkerName\(dq: \(dq.stfolder\(dq,
\(dqcopyOwnershipFromParent\(dq: false,
\(dqmodTimeWindowS\(dq: 0,
@@ -464,61 +458,6 @@ The connection types are \fBTCP (Client)\fP, \fBTCP (Server)\fP, \fBRelay (Clien
.EE
.UNINDENT
.UNINDENT
.SS GET /rest/system/debug
.sp
Added in version 0.12.0.
.sp
Returns the set of debug facilities and which of them are currently enabled.
.INDENT 0.0
.INDENT 3.5
.sp
.EX
{
\(dqenabled\(dq: [
\(dqbeacon\(dq
],
\(dqfacilities\(dq: {
\(dqbeacon\(dq: \(dqMulticast and broadcast discovery\(dq,
\(dqconfig\(dq: \(dqConfiguration loading and saving\(dq,
\(dqconnections\(dq: \(dqConnection handling\(dq,
\(dqdb\(dq: \(dqThe database layer\(dq,
\(dqdialer\(dq: \(dqDialing connections\(dq,
\(dqdiscover\(dq: \(dqRemote device discovery\(dq,
\(dqevents\(dq: \(dqEvent generation and logging\(dq,
\(dqhttp\(dq: \(dqREST API\(dq,
\(dqmain\(dq: \(dqMain package\(dq,
\(dqmodel\(dq: \(dqThe root hub\(dq,
\(dqprotocol\(dq: \(dqThe BEP protocol\(dq,
\(dqrelay\(dq: \(dqRelay connection handling\(dq,
\(dqscanner\(dq: \(dqFile change detection and hashing\(dq,
\(dqstats\(dq: \(dqPersistent device and folder statistics\(dq,
\(dqsync\(dq: \(dqMutexes\(dq,
\(dqupgrade\(dq: \(dqBinary upgrades\(dq,
\(dqupnp\(dq: \(dqUPnP discovery and port mapping\(dq,
\(dqversioner\(dq: \(dqFile versioning\(dq
}
}
.EE
.UNINDENT
.UNINDENT
.SS POST /rest/system/debug
.sp
Added in version 0.12.0.
.sp
Enables or disables debugging for specified facilities. Give one or both of
\fBenable\fP and \fBdisable\fP query parameters, with comma separated facility
names. To disable debugging of the beacon and discovery packages, and enable it
for config and db:
.INDENT 0.0
.INDENT 3.5
.sp
.EX
$ curl \-H X\-API\-Key:abc123 \-X POST \(aqhttp://localhost:8384/rest/system/debug?disable=beacon,discovery&enable=config,db\(aq
.EE
.UNINDENT
.UNINDENT
.SS GET /rest/system/discovery
.sp
Returns the contents of the local discovery cache.
@@ -612,6 +551,51 @@ the results to message newer than the given timestamp in \X'tty: link https://da
.SS GET /rest/system/log.txt
.sp
Returns the same information, formatted as a text log instead of a JSON object.
.SS GET /rest/system/loglevels
.sp
Added in version 2.0.0.
.sp
Returns the set of log facilities and their current log level.
.INDENT 0.0
.INDENT 3.5
.sp
.EX
{
\(dqlevels\(dq: {
\(dqapi\(dq: \(dqINFO\(dq,
\(dqbeacon\(dq: \(dqINFO\(dq,
...
\(dqversioner\(dq: \(dqINFO\(dq,
\(dqwatchaggregator\(dq: \(dqINFO\(dq
},
\(dqpackages\(dq: {
\(dqapi\(dq: \(dqREST API\(dq,
\(dqbeacon\(dq: \(dqMulticast and broadcast discovery\(dq,
...
\(dqversioner\(dq: \(dqFile versioning\(dq,
\(dqwatchaggregator\(dq: \(dqFilesystem event watcher\(dq
}
}
.EE
.UNINDENT
.UNINDENT
.SS POST /rest/system/loglevels
.sp
Added in version 2.0.0.
.sp
Changes the log level for specified facilities. Post an object with the log
facilites as keys and desired log level (\fBDEBUG\fP, \fBINFO\fP, \fBWARN\fP, or
\fBERROR\fP) as the values.
.INDENT 0.0
.INDENT 3.5
.sp
.EX
$ curl \-H X\-API\-Key:abc123 \-d \(aq{\(dqbeacon\(dq:\(dqDEBUG\(dq,\(dqdiscovery\(dq:\(dqWARN\(dq}\(aq \(aqhttp://localhost:8384/rest/system/loglevels\(aq
.EE
.UNINDENT
.UNINDENT
.SS GET /rest/system/paths
.sp
Added in version 1.21.0.
@@ -631,7 +615,7 @@ and others.
\(dqcertFile\(dq: \(dq/home/user/.config/syncthing/cert.pem\(dq,
\(dqconfig\(dq: \(dq/home/user/.config/syncthing/config.xml\(dq,
\(dqcsrfTokens\(dq: \(dq/home/user/.config/syncthing/csrftokens.txt\(dq,
\(dqdatabase\(dq: \(dq/home/user/.local/share/syncthing/index\-v0.14.0.db\(dq,
\(dqdatabase\(dq: \(dq/home/user/.local/share/syncthing/index\-v2\(dq,
\(dqdefFolder\(dq: \(dq/home/user/Sync\(dq,
\(dqguiAssets\(dq: \(dq/home/user/src/syncthing/gui\(dq,
\(dqhttpsCertFile\(dq: \(dq/home/user/.config/syncthing/https\-cert.pem\(dq,
@@ -681,7 +665,7 @@ curl \-X POST \-H \(dqX\-API\-Key: abc123\(dq http://localhost:8384/rest/system/
.UNINDENT
.UNINDENT
.sp
\fBCaution\fP: See \fI\%\-\-reset\-database\fP for \fB\&.stfolder\fP creation
\fBCaution\fP: See \fB\-\-reset\-database\fP for \fB\&.stfolder\fP creation
side\-effect and caution regarding mountpoints.
.SS POST /rest/system/restart
.sp
@@ -1923,17 +1907,6 @@ Returns the data sent in the anonymous usage report.
.UNINDENT
.SH DEBUG ENDPOINTS
.SS Debug Endpoints
.sp
These endpoints require the \fI\%gui.debugging\fP configuration option to
be enabled and yield an access denied error code otherwise.
.SS GET /rest/debug/peerCompletion
.sp
Summarizes the completion percentage for each remote device. Returns an object
with device IDs as keys and an integer percentage as values.
.SS GET /rest/debug/httpmetrics
.sp
Returns statistics about each served REST API endpoint, to diagnose how much
time was spent generating the responses.
.SS GET /rest/debug/cpuprof
.sp
Used to capture a profile of what Syncthing is doing on the CPU. See
@@ -1982,6 +1955,6 @@ Returns a \fB{\(dqstatus\(dq: \(dqOK\(dq}\fP object.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-SECURITY" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-SECURITY" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-security \- Security Principles
.sp
@@ -167,6 +167,6 @@ avoid leaking keys and metadata. Or, use whole disk encryption.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-STIGNORE" "5" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-STIGNORE" "5" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-stignore \- Prevent files from being synchronized to other nodes
.SH SYNOPSIS
@@ -92,12 +92,32 @@ and does not denote a set of alternatives as above.
\fBNOTE:\fP
.INDENT 2.0
.INDENT 3.5
Escaped characters are not supported on Windows, where \fB\e\fP is the
path separator. If you still need to match files that have square or
curly brackets in their names, one possible workaround is to replace
them with \fB?\fP, which will then match any character. For example,
you can type \fB?banana?\fP to match both \fB[banana]\fP and
\fB{banana}\fP, and so on.
On Windows, \fB\e\fP is the path separator, so use \fB|\fP to escape special
characters. For example, \fB|{banana|}\fP matches
\fB{banana}\fP\&.
.sp
To use \fB\e\fP to escape special characters (and use \fB/\fP as the path separator),
insert a \fB#escape=\e\fP at the top of the file. Heres a short example:
.INDENT 0.0
.INDENT 3.5
.nf
\fB#escape=\e\fP
\fB/foo\fP
\fB/path/bar/\e{banana\e}\fP
\fB/path/baz\e[2\e]/ex\e[3\e].txt\fP
.fi
.sp
.UNINDENT
.UNINDENT
.sp
\fB#escape=\e\fP must be placed at the top of the file, before any patterns,
but leading comments, and blank lines are OK.
.sp
Any files included using \fB#include\fP (see below) will each need their
own \fB#escape=\e\fP\&.
.sp
Using \fB#escape=\e\fP allows the same file to be synced and used on any
operating system.
.UNINDENT
.UNINDENT
.IP \(bu 2
@@ -259,9 +279,15 @@ accepting a folder from a remote device. The GUI suggests the same patterns
when adding a folder manually. In either case, the \fB\&.stignore\fP file is
created with these defaults if none is present yet.
.sp
Added in version 2.0.0: Windows users can now use the pipe character (\fB|\fP) to escape
metacharacters in the \fB\&.stignore\fP file. Additionally, adding
\fB#escape=X\fP to the top of the file, allows users to define \fBX\fP
as the escape character for that particular file.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING-VERSIONING" "7" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING-VERSIONING" "7" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing-versioning \- Keep automatic backups of deleted files by other nodes
.sp
@@ -375,6 +375,6 @@ quoted.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "SYNCTHING" "1" "Aug 01, 2025" "v1.29.7" "Syncthing"
.TH "SYNCTHING" "1" "Aug 11, 2025" "v2.0.0" "Syncthing"
.SH NAME
syncthing \- Syncthing
.SH SYNOPSIS
@@ -36,33 +36,60 @@ syncthing \- Syncthing
.sp
.EX
syncthing [serve]
[\-\-audit] [\-\-auditfile=<file|\-|\-\->] [\-\-browser\-only] [\-\-device\-id]
[\-\-generate=<dir>] [\-\-gui\-address=<address>] [\-\-gui\-apikey=<key>]
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-logfile=<filename>] [\-\-logflags=<flags>]
[\-\-allow\-newer\-config] [\-\-audit] [\-\-auditfile=<file|\-|\-\->]
[\-\-db\-maintenance\-interval=<interval>]
[\-\-db\-delete\-retention\-interval=<interval>]
[\-\-gui\-address=<address>] [\-\-gui\-apikey=<key>]
[\-\-log\-level=<level>] [\-\-log\-file=<filename>]
[\-\-log\-max\-old\-files=<num>] [\-\-log\-max\-size=<num>]
[\-\-no\-browser] [\-\-no\-console] [\-\-no\-restart] [\-\-paths] [\-\-paused]
[\-\-no\-default\-folder] [\-\-skip\-port\-probing]
[\-\-reset\-database] [\-\-reset\-deltas] [\-\-unpaused] [\-\-allow\-newer\-config]
[\-\-upgrade] [\-\-no\-upgrade] [\-\-upgrade\-check] [\-\-upgrade\-to=<url>]
[\-\-no\-browser] [\-\-no\-console]
[\-\-no\-port\-probing] [\-\-no\-restart] [\-\-no\-upgrade]
[\-\-paused] [\-\-unpaused]
[\-\-verbose] [\-\-version] [\-\-help] [\-\-debug\-*]
syncthing generate
[\-\-home=<dir> | \-\-config=<dir>]
[\-\-gui\-user=<username>] [\-\-gui\-password=<password|\->]
[\-\-no\-default\-folder] [\-\-skip\-port\-probing] [\-\-no\-console]
[\-\-help]
syncthing decrypt (\-\-to=<dir> | \-\-verify\-only)
[\-\-password=<pw>] [\-\-folder\-id=<id>] [\-\-token\-path=<file>]
[\-\-continue] [\-\-verbose] [\-\-version] [\-\-help]
<path>
syncthing cli
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-gui\-address=<address>] [\-\-gui\-apikey=<key>]
[\-\-help]
<command> [command options...] [arguments...]
syncthing browser
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-help]
syncthing decrypt (\-\-to=<dir> | \-\-verify\-only)
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-password=<pw>] [\-\-folder\-id=<id>] [\-\-token\-path=<file>]
[\-\-continue] [\-\-verbose] [\-\-help]
<path>
syncthing device\-id
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-help]
syncthing generate
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-gui\-user=<username>] [\-\-gui\-password=<password|\->]
[\-\-no\-port\-probing]
[\-\-help]
syncthing paths
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-help]
syncthing upgrade
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-check\-only] [\-\-from=<url>]
[\-\-help]
syncthing version
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-help]
syncthing debug <command>
[\-\-home=<dir> | \-\-config=<dir> \-\-data=<dir>]
[\-\-help]
.EE
.UNINDENT
.UNINDENT
@@ -82,7 +109,35 @@ frontend communicates with the core application through some HTTP APIs, which
other apps like graphical system integration helpers can use as well, for
greatest flexibility. A link to reach the GUI and API is printed among the first
few log messages.
.SH OPTIONS
.SH COMMON OPTIONS
.INDENT 0.0
.TP
.B \-\-home=<dir>, \-H <dir>
Set common configuration and data directory. The default configuration
directory is \fB$XDG_STATE_HOME/syncthing\fP or
\fB$HOME/.local/state/syncthing\fP (Unix\-like),
\fB$HOME/Library/Application Support/Syncthing\fP (Mac) and
\fB%LOCALAPPDATA%\eSyncthing\fP (Windows).
.UNINDENT
.INDENT 0.0
.TP
.B \-\-config=<dir>, \-C <dir>
Set configuration directory. Alternative to \fB\-\-home\fP and must be used
together with \fB\-\-data\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-data=<dir>, \-D <dir>
Set data (e.g. database) directory. Alternative to \fB\-\-home\fP and must be used
together with \fB\-\-config\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-help, \-h
Show help text about command line usage. Context\-sensitive depending on the
given subcommand.
.UNINDENT
.SH SERVE OPTIONS
.INDENT 0.0
.TP
.B \-\-allow\-newer\-config
@@ -102,18 +157,15 @@ audit events, rather than the timestamped default file name.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-browser\-only
Open the web UI in a browser for an already running Syncthing instance.
.B \-\-db\-maintenance\-interval=<interval>
Database maintenance interval internal database maintenance routines
run this often.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-device\-id
Print device ID to command line.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-generate=<dir>
Generate key and config in specified dir, then exit.
.B \-\-db\-delete\-retention\-interval=<interval>
Database deleted item retention interval deleted items are forgotten
from the database after this interval.
.UNINDENT
.INDENT 0.0
.TP
@@ -132,75 +184,18 @@ Override the API key needed to access the GUI / REST API.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-gui\-password=<password|\->
Specify new GUI authentication password, to update the config file. Read
from the standard input stream if only a single dash (\fB\-\fP) is given. A
plaintext password is hashed before writing to the config file, but an
already bcrypt\-hashed input is stored verbatim. As a special case, giving
the existing password hash as password will leave it untouched.
.B \-\-log\-level=<level>
Set the log level for all packages. Valid levels are DEBUG, INFO, WARN,
and ERROR.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-gui\-user=<username>
Specify new GUI authentication user name, to update the config file.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-help, \-h
Show help text about command line usage. Context\-sensitive depending on the
given subcommand.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-home=<dir>
Set common configuration and data directory. The default configuration
directory is \fB$XDG_STATE_HOME/syncthing\fP or
\fB$HOME/.local/state/syncthing\fP (Unix\-like),
\fB$HOME/Library/Application Support/Syncthing\fP (Mac) and
\fB%LOCALAPPDATA%\eSyncthing\fP (Windows).
.UNINDENT
.INDENT 0.0
.TP
.B \-\-config=<dir>
Set configuration directory. Alternative to \fB\-\-home\fP and must be used
together with \fB\-\-data\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-data=<dir>
Set data (e.g. database) directory. Alternative to \fB\-\-home\fP and must be used
together with \fB\-\-config\fP\&.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-logfile=<filename>
.B \-\-log\-file=<filename>
Set destination filename for logging (use \fB\(dq\-\(dq\fP for stdout, which is the
default option).
.UNINDENT
.INDENT 0.0
.TP
.B \-\-logflags=<flags>
Select information in log line prefix. The \fB\-\-logflags\fP value is a sum of
the following:
.INDENT 7.0
.IP \(bu 2
1: Date
.IP \(bu 2
2: Time
.IP \(bu 2
4: Microsecond time
.IP \(bu 2
8: Long filename
.IP \(bu 2
16: Short filename
.UNINDENT
.sp
To prefix each log line with date and time, set \fB\-\-logflags=3\fP (1 + 2 from
above). The value 0 is used to disable all of the above. The default is to
show time only (2).
.UNINDENT
.INDENT 0.0
.TP
.B \-\-log\-max\-old\-files=<num>
Number of old files to keep (zero to keep only current). Applies only when
log rotation is enabled through \fB\-\-log\-max\-size\fP\&.
@@ -222,9 +217,9 @@ Hide the console window. (On Windows only)
.UNINDENT
.INDENT 0.0
.TP
.B \-\-no\-default\-folder
Dont create a default folder when generating an initial configuration /
starting for the first time.
.B \-\-no\-port\-probing
Dont try to find unused random ports for the GUI and listen address when
generating an initial configuration / starting for the first time.
.UNINDENT
.INDENT 0.0
.TP
@@ -240,37 +235,11 @@ variable, see below.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-paths
Print the paths used for configuration, keys, database, GUI overrides,
default sync folder and the log file.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-paused
Start with all devices and folders paused.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-reset\-database
Reset the database, forcing a full rescan and resync. Create \fI\&.stfolder\fP
folders in each sync folder if they do not already exist. \fBCaution\fP:
Ensure that all sync folders which are mountpoints are already mounted.
Inconsistent versions may result if the mountpoint is later mounted and
contains older versions.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-reset\-deltas
Reset delta index IDs, forcing a full index exchange.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-skip\-port\-probing
Dont try to find unused random ports for the GUI and listen address when
generating an initial configuration / starting for the first time.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-unpaused
Start with all devices and folders unpaused.
.UNINDENT
@@ -281,24 +250,10 @@ Perform upgrade.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-upgrade\-check
Check for available upgrade.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-upgrade\-to=<url>
Force upgrade directly from specified URL.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-verbose
Print verbose log output.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-version
Show version.
.UNINDENT
.SH DECRYPT OPTIONS
.INDENT 0.0
.TP
.B \-\-to=<dir>
@@ -331,6 +286,33 @@ Path to the token file within the folder (used to determine folder ID).
.B \-\-continue
Continue processing next file in case of error, instead of aborting.
.UNINDENT
.SH GENERATE OPTIONS
.INDENT 0.0
.TP
.B \-\-gui\-password=<password|\->
Specify new GUI authentication password, to update the config file. Read
from the standard input stream if only a single dash (\fB\-\fP) is given. A
plaintext password is hashed before writing to the config file, but an
already bcrypt\-hashed input is stored verbatim. As a special case, giving
the existing password hash as password will leave it untouched.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-gui\-user=<username>
Specify new GUI authentication user name, to update the config file.
.UNINDENT
.SH UPGRADE OPTIONS
.INDENT 0.0
.TP
.B \-\-check\-only
Do not upgrade, only indicate whether an upgrade is available.
.UNINDENT
.INDENT 0.0
.TP
.B \-\-from=<url>
Upgrade to the Syncthing version available from loading the package at
the given URL.
.UNINDENT
.SH EXIT CODES
.INDENT 0.0
.TP
@@ -435,160 +417,54 @@ path expansion may not be supported.
.INDENT 0.0
.TP
.B STTRACE
Used to increase the debugging verbosity in specific or all facilities,
generally mapping to a Go package. Enabling any of these also enables
microsecond timestamps, file names plus line numbers. Enter a
comma\-separated string of facilities to trace. \fBsyncthing \-\-help\fP always
outputs an up\-to\-date list. The valid facility strings are:
Used to increase the debugging verbosity in specific facilities,
generally mapping to a Go package. Enter a comma\-separated string of
facilities to trace: \fBapi,beacon\fP\&. Optionally, a log level can be
given per facility to specify something other than DEBUG:
\fBapi:WARN,beacon:ERR\fP, potentially overriding a global \fB\-\-log\-level\fP
adjustment.
.INDENT 7.0
.TP
.B Main and operational facilities:
.INDENT 7.0
.TP
.B config
Configuration loading and saving.
.TP
.B db
The database layer.
.TP
.B main
Main package.
.TP
.B model
The root hub; the largest chunk of the system. File pulling, index
transmission and requests for chunks.
.TP
.B scanner
File change detection and hashing.
.TP
.B versioner
File versioning.
.UNINDENT
.TP
.B Networking facilities:
.INDENT 7.0
.TP
.B beacon
Multicast and broadcast UDP discovery packets: Selected interfaces
and addresses.
.TP
.B connections
Connection handling.
.TP
.B dialer
Dialing connections.
.TP
.B discover
Remote device discovery requests, replies and registration of
devices.
.TP
.B nat
NAT discovery and port mapping.
.TP
.B pmp
NAT\-PMP discovery and port mapping.
.TP
.B protocol
The BEP protocol.
.TP
.B relay
Relay interaction (\fBstrelaysrv\fP).
.TP
.B upnp
UPnP discovery and port mapping.
.UNINDENT
.TP
.B Other facilities:
.INDENT 7.0
.TP
.B fs
Filesystem access.
.TP
.B events
Event generation and logging.
.TP
.B http
REST API.
.TP
.B sha256
SHA256 hashing package (this facility currently unused).
.TP
.B stats
Persistent device and folder statistics.
.TP
.B sync
Mutexes. Used for debugging race conditions and deadlocks.
.TP
.B upgrade
Binary upgrades.
.TP
.B walkfs
Filesystem access while walking.
.TP
.B all
All of the above.
.INDENT 3.5
The valid facility strings are listed below; additionally, \fBsyncthing
serve \-\-help\fP always outputs the most up\-to\-date list.
.INDENT 0.0
.INDENT 3.5
api \- REST API
beacon \- Multicast and broadcast discovery
config \- Configuration loading and saving
connections \- Connection handling
db/sqlite \- SQLite database
dialer \- Dialing connections
discover \- Remote device discovery
events \- Event generation and logging
fs \- Filesystem access
main \- Main package
model \- The root hub
nat \- NAT discovery and port mapping
pmp \- NAT\-PMP discovery and port mapping
protocol \- The BEP protocol
relay/client \- Relay client
scanner \- File change detection and hashing
stun \- STUN functionality
syncthing \- Main run facility
upgrade \- Binary upgrades
upnp \- UPnP discovery and port mapping
ur \- Usage reporting
versioner \- File versioning
watchaggregator \- Filesystem event watcher
.UNINDENT
.UNINDENT
.UNINDENT
.UNINDENT
.TP
.B STBLOCKPROFILE
Write block profiles to \fBblock\-$pid\-$timestamp.pprof\fP every 20 seconds.
.TP
.B STCPUPROFILE
Write a CPU profile to \fBcpu\-$pid.pprof\fP on exit.
.TP
.B STDEADLOCKTIMEOUT
Used for debugging internal deadlocks; sets debug sensitivity. Use only
under direction of a developer.
.TP
.B STLOCKTHRESHOLD
Used for debugging internal deadlocks; sets debug sensitivity. Use only
under direction of a developer.
.TP
.B STGUIADDRESS
Override GUI listen address. Equivalent to passing \fI\%\-\-gui\-address\fP\&.
.TP
.B STGUIAPIKEY
Override the API key needed to access the GUI / REST API. Equivalent to
passing \fI\%\-\-gui\-apikey\fP\&.
.TP
.B STGUIASSETS
Directory to load GUI assets from. Overrides compiled in assets. Useful for
developing webgui, commonly use \fBSTGUIASSETS=gui bin/syncthing\fP\&.
.TP
.B STHEAPPROFILE
Write heap profiles to \fBheap\-$pid\-$timestamp.pprof\fP each time heap usage
increases.
.TP
.B STNODEFAULTFOLDER
Dont create a default folder when starting for the first time. This
variable will be ignored anytime after the first run. Equivalent to the
\fI\%\-\-no\-default\-folder\fP flag.
.TP
.B STNORESTART
Equivalent to the \fI\%\-\-no\-restart\fP flag.
.TP
.B STNOUPGRADE
Disable automatic upgrades. Equivalent to the \fI\%\-\-no\-upgrade\fP flag.
.TP
.B STPROFILER
Set to a listen address such as “127.0.0.1:9090” to start the profiler with
HTTP access, which then can be reached at
\X'tty: link http://localhost:9090/debug/pprof'\fI\%http://localhost:9090/debug/pprof\fP\X'tty: link'\&. See \fBgo tool pprof\fP for more
information.
.TP
.B STPERFSTATS
Write running performance statistics to \fBperf\-$pid.csv\fP\&. Not supported on
Windows.
.TP
.B STRECHECKDBEVERY
Time before folder statistics (file, dir, … counts) are recalculated from
scratch. The given duration must be parseable by Gos \fBtime.ParseDuration\fP\&. If
missing or not parseable, the default value of 1 month is used. To force
recalculation on every startup, set it to \fB1s\fP\&.
.TP
.B STGCINDIRECTEVERY
Sets the time interval in between database garbage collection runs. The
given duration must be parseable by Gos \fBtime.ParseDuration\fP\&.
.B STVERSIONEXTRA
Add extra information to the version string in logs and the version line
in the GUI. Can be set to the name of a wrapper or tool controlling
syncthing to communicate this to the end user.
.TP
.B GOMAXPROCS
Set the maximum number of CPU cores to use. Defaults to all available CPU
@@ -612,6 +488,6 @@ Set to any nonempty value to use it.
.SH AUTHOR
The Syncthing Authors
.SH COPYRIGHT
2014-2019, The Syncthing Authors
2014-2025, The Syncthing Authors
.\" Generated by docutils manpage writer.
.

View File

@@ -65,7 +65,7 @@
<remoteGUIPort>0</remoteGUIPort>
<numConnections>3</numConnections>
</device>
<gui enabled="true" tls="false" debugging="true" sendBasicAuthPrompt="false">
<gui enabled="true" tls="false" sendBasicAuthPrompt="false">
<address>127.0.0.1:8081</address>
<user>testuser</user>
<password>$2a$10$7tKL5uvLDGn5s2VLPM2yWOK/II45az0mTel8hxAUJDRQN1Tk2QYwu</password>

View File

@@ -65,7 +65,7 @@
<remoteGUIPort>0</remoteGUIPort>
<numConnections>3</numConnections>
</device>
<gui enabled="true" tls="false" debugging="true" sendBasicAuthPrompt="false">
<gui enabled="true" tls="false" sendBasicAuthPrompt="false">
<address>127.0.0.1:8082</address>
<metricsWithoutAuth>false</metricsWithoutAuth>
<apikey>abc123</apikey>