Guest User

Untitled

a guest
Sep 23rd, 2019
1,695
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 48.64 KB | None | 0 0
  1. # vim:ft=yaml
  2.  
  3. ## Server ##
  4.  
  5. # The domain name of the server, with optional explicit port.
  6. # This is used by remote servers to connect to this server,
  7. # e.g. matrix.org, localhost:8080, etc.
  8. # This is also the last part of your UserID.
  9. #
  10. server_name: "m1.local:8008"
  11.  
  12. # When running as a daemon, the file to store the pid in
  13. #
  14. pid_file: /data/homeserver.pid
  15.  
  16. # The path to the web client which will be served at /_matrix/client/
  17. # if 'webclient' is configured under the 'listeners' configuration.
  18. #
  19. #web_client_location: "/path/to/web/root"
  20.  
  21. # The public-facing base URL that clients use to access this HS
  22. # (not including _matrix/...). This is the same URL a user would
  23. # enter into the 'custom HS URL' field on their client. If you
  24. # use synapse with a reverse proxy, this should be the URL to reach
  25. # synapse via the proxy.
  26. #
  27. #public_baseurl: https://example.com/
  28.  
  29. # Set the soft limit on the number of file descriptors synapse can use
  30. # Zero is used to indicate synapse should set the soft limit to the
  31. # hard limit.
  32. #
  33. #soft_file_limit: 0
  34.  
  35. # Set to false to disable presence tracking on this homeserver.
  36. #
  37. #use_presence: false
  38.  
  39. # Whether to require authentication to retrieve profile data (avatars,
  40. # display names) of other users through the client API. Defaults to
  41. # 'false'. Note that profile data is also available via the federation
  42. # API, so this setting is of limited value if federation is enabled on
  43. # the server.
  44. #
  45. #require_auth_for_profile_requests: true
  46.  
  47. # If set to 'false', requires authentication to access the server's public rooms
  48. # directory through the client API. Defaults to 'true'.
  49. #
  50. #allow_public_rooms_without_auth: false
  51.  
  52. # If set to 'false', forbids any other homeserver to fetch the server's public
  53. # rooms directory via federation. Defaults to 'true'.
  54. #
  55. #allow_public_rooms_over_federation: false
  56.  
  57. # The default room version for newly created rooms.
  58. #
  59. # Known room versions are listed here:
  60. # https://matrix.org/docs/spec/#complete-list-of-room-versions
  61. #
  62. # For example, for room version 1, default_room_version should be set
  63. # to "1".
  64. #
  65. #default_room_version: "4"
  66.  
  67. # The GC threshold parameters to pass to `gc.set_threshold`, if defined
  68. #
  69. #gc_thresholds: [700, 10, 10]
  70.  
  71. # Set the limit on the returned events in the timeline in the get
  72. # and sync operations. The default value is -1, means no upper limit.
  73. #
  74. #filter_timeline_limit: 5000
  75.  
  76. # Whether room invites to users on this server should be blocked
  77. # (except those sent by local server admins). The default is False.
  78. #
  79. #block_non_admin_invites: True
  80.  
  81. # Room searching
  82. #
  83. # If disabled, new messages will not be indexed for searching and users
  84. # will receive errors when searching for messages. Defaults to enabled.
  85. #
  86. #enable_search: false
  87.  
  88. # Restrict federation to the following whitelist of domains.
  89. # N.B. we recommend also firewalling your federation listener to limit
  90. # inbound federation traffic as early as possible, rather than relying
  91. # purely on this application-layer restriction.  If not specified, the
  92. # default is to whitelist everything.
  93. #
  94. #federation_domain_whitelist:
  95. #  - lon.example.com
  96. #  - nyc.example.com
  97. #  - syd.example.com
  98.  
  99. # Prevent federation requests from being sent to the following
  100. # blacklist IP address CIDR ranges. If this option is not specified, or
  101. # specified with an empty list, no ip range blacklist will be enforced.
  102. #
  103. # (0.0.0.0 and :: are always blacklisted, whether or not they are explicitly
  104. # listed here, since they correspond to unroutable addresses.)
  105. #
  106. federation_ip_range_blacklist:
  107.  - '127.0.0.0/8'
  108.   - '10.0.0.0/8'
  109.   - '172.16.0.0/12'
  110.   - '192.168.0.0/16'
  111.   - '100.64.0.0/10'
  112.   - '169.254.0.0/16'
  113.   - '::1/128'
  114.   - 'fe80::/64'
  115.   - 'fc00::/7'
  116.  
  117. # List of ports that Synapse should listen on, their purpose and their
  118. # configuration.
  119. #
  120. # Options for each listener include:
  121. #
  122. #   port: the TCP port to bind to
  123. #
  124. #   bind_addresses: a list of local addresses to listen on. The default is
  125. #       'all local interfaces'.
  126. #
  127. #   type: the type of listener. Normally 'http', but other valid options are:
  128. #       'manhole' (see docs/manhole.md),
  129. #       'metrics' (see docs/metrics-howto.rst),
  130. #       'replication' (see docs/workers.rst).
  131. #
  132. #   tls: set to true to enable TLS for this listener. Will use the TLS
  133. #       key/cert specified in tls_private_key_path / tls_certificate_path.
  134. #
  135. #   x_forwarded: Only valid for an 'http' listener. Set to true to use the
  136. #       X-Forwarded-For header as the client IP. Useful when Synapse is
  137. #       behind a reverse-proxy.
  138. #
  139. #   resources: Only valid for an 'http' listener. A list of resources to host
  140. #       on this port. Options for each resource are:
  141. #
  142. #       names: a list of names of HTTP resources. See below for a list of
  143. #           valid resource names.
  144. #
  145. #       compress: set to true to enable HTTP comression for this resource.
  146. #
  147. #   additional_resources: Only valid for an 'http' listener. A map of
  148. #        additional endpoints which should be loaded via dynamic modules.
  149. #
  150. # Valid resource names are:
  151. #
  152. #   client: the client-server API (/_matrix/client), and the synapse admin
  153. #       API (/_synapse/admin). Also implies 'media' and 'static'.
  154. #
  155. #   consent: user consent forms (/_matrix/consent). See
  156. #       docs/consent_tracking.md.
  157. #
  158. #   federation: the server-server API (/_matrix/federation). Also implies
  159. #       'media', 'keys', 'openid'
  160. #
  161. #   keys: the key discovery API (/_matrix/keys).
  162. #
  163. #   media: the media API (/_matrix/media).
  164. #
  165. #   metrics: the metrics interface. See docs/metrics-howto.rst.
  166. #
  167. #   openid: OpenID authentication.
  168. #
  169. #   replication: the HTTP replication API (/_synapse/replication). See
  170. #       docs/workers.rst.
  171. #
  172. #   static: static resources under synapse/static (/_matrix/static). (Mostly
  173. #       useful for 'fallback authentication'.)
  174. #
  175. #   webclient: A web client. Requires web_client_location to be set.
  176. #
  177. listeners:
  178.  # TLS-enabled listener: for when matrix traffic is sent directly to synapse.
  179.   #
  180.   # Disabled by default. To enable it, uncomment the following. (Note that you
  181.   # will also need to give Synapse a TLS key and certificate: see the TLS section
  182.   # below.)
  183.   #
  184.   #- port: 8008
  185.   #  type: http
  186.   #  tls: true
  187.   #  resources:
  188.   #    - names: [client, federation]
  189.  
  190.   # Unsecure HTTP listener: for when matrix traffic passes through a reverse proxy
  191.   # that unwraps TLS.
  192.   #
  193.   # If you plan to use a reverse proxy, please see
  194.   # https://github.com/matrix-org/synapse/blob/master/docs/reverse_proxy.rst.
  195.   #
  196.   - port: 7608
  197.     tls: false
  198.     type: http
  199.     x_forwarded: true
  200.  
  201.     resources:
  202.       - names: [client, federation]
  203.         compress: false
  204.  
  205.     # example additional_resources:
  206.     #
  207.     #additional_resources:
  208.     #  "/_matrix/my/custom/endpoint":
  209.     #    module: my_module.CustomRequestHandler
  210.     #    config: {}
  211.  
  212.   # Turn on the twisted ssh manhole service on localhost on the given
  213.   # port.
  214.   #
  215.   #- port: 9000
  216.   #  bind_addresses: ['::1', '127.0.0.1']
  217.   #  type: manhole
  218.  
  219.  
  220. ## Homeserver blocking ##
  221.  
  222. # How to reach the server admin, used in ResourceLimitError
  223. #
  224. #admin_contact: 'mailto:admin@server.com'
  225.  
  226. # Global blocking
  227. #
  228. #hs_disabled: False
  229. #hs_disabled_message: 'Human readable reason for why the HS is blocked'
  230. #hs_disabled_limit_type: 'error code(str), to help clients decode reason'
  231.  
  232. # Monthly Active User Blocking
  233. #
  234. # Used in cases where the admin or server owner wants to limit to the
  235. # number of monthly active users.
  236. #
  237. # 'limit_usage_by_mau' disables/enables monthly active user blocking. When
  238. # anabled and a limit is reached the server returns a 'ResourceLimitError'
  239. # with error type Codes.RESOURCE_LIMIT_EXCEEDED
  240. #
  241. # 'max_mau_value' is the hard limit of monthly active users above which
  242. # the server will start blocking user actions.
  243. #
  244. # 'mau_trial_days' is a means to add a grace period for active users. It
  245. # means that users must be active for this number of days before they
  246. # can be considered active and guards against the case where lots of users
  247. # sign up in a short space of time never to return after their initial
  248. # session.
  249. #
  250. #limit_usage_by_mau: False
  251. #max_mau_value: 50
  252. #mau_trial_days: 2
  253.  
  254. # If enabled, the metrics for the number of monthly active users will
  255. # be populated, however no one will be limited. If limit_usage_by_mau
  256. # is true, this is implied to be true.
  257. #
  258. #mau_stats_only: False
  259.  
  260. # Sometimes the server admin will want to ensure certain accounts are
  261. # never blocked by mau checking. These accounts are specified here.
  262. #
  263. #mau_limit_reserved_threepids:
  264. #  - medium: 'email'
  265. #    address: 'reserved_user@example.com'
  266.  
  267. # Used by phonehome stats to group together related servers.
  268. #server_context: context
  269.  
  270. # Resource-constrained Homeserver Settings
  271. #
  272. # If limit_remote_rooms.enabled is True, the room complexity will be
  273. # checked before a user joins a new remote room. If it is above
  274. # limit_remote_rooms.complexity, it will disallow joining or
  275. # instantly leave.
  276. #
  277. # limit_remote_rooms.complexity_error can be set to customise the text
  278. # displayed to the user when a room above the complexity threshold has
  279. # its join cancelled.
  280. #
  281. # Uncomment the below lines to enable:
  282. #limit_remote_rooms:
  283. #  enabled: True
  284. #  complexity: 1.0
  285. #  complexity_error: "This room is too complex."
  286.  
  287. # Whether to require a user to be in the room to add an alias to it.
  288. # Defaults to 'true'.
  289. #
  290. #require_membership_for_aliases: false
  291.  
  292. # Whether to allow per-room membership profiles through the send of membership
  293. # events with profile information that differ from the target's global profile.
  294. # Defaults to 'true'.
  295. #
  296. #allow_per_room_profiles: false
  297.  
  298.  
  299. ## TLS ##
  300.  
  301. # PEM-encoded X509 certificate for TLS.
  302. # This certificate, as of Synapse 1.0, will need to be a valid and verifiable
  303. # certificate, signed by a recognised Certificate Authority.
  304. #
  305. # See 'ACME support' below to enable auto-provisioning this certificate via
  306. # Let's Encrypt.
  307. #
  308. # If supplying your own, be sure to use a `.pem` file that includes the
  309. # full certificate chain including any intermediate certificates (for
  310. # instance, if using certbot, use `fullchain.pem` as your certificate,
  311. # not `cert.pem`).
  312. #
  313. #tls_certificate_path: "/data/m1.local:8008.tls.crt"
  314.  
  315. # PEM-encoded private key for TLS
  316. #
  317. #tls_private_key_path: "/data/m1.local:8008.tls.key"
  318.  
  319. # Whether to verify TLS server certificates for outbound federation requests.
  320. #
  321. # Defaults to `true`. To disable certificate verification, uncomment the
  322. # following line.
  323. #
  324. #federation_verify_certificates: false
  325.  
  326. # The minimum TLS version that will be used for outbound federation requests.
  327. #
  328. # Defaults to `1`. Configurable to `1`, `1.1`, `1.2`, or `1.3`. Note
  329. # that setting this value higher than `1.2` will prevent federation to most
  330. # of the public Matrix network: only configure it to `1.3` if you have an
  331. # entirely private federation setup and you can ensure TLS 1.3 support.
  332. #
  333. #federation_client_minimum_tls_version: 1.2
  334.  
  335. # Skip federation certificate verification on the following whitelist
  336. # of domains.
  337. #
  338. # This setting should only be used in very specific cases, such as
  339. # federation over Tor hidden services and similar. For private networks
  340. # of homeservers, you likely want to use a private CA instead.
  341. #
  342. # Only effective if federation_verify_certicates is `true`.
  343. #
  344. #federation_certificate_verification_whitelist:
  345. #  - lon.example.com
  346. #  - *.domain.com
  347. #  - *.onion
  348.  
  349. # List of custom certificate authorities for federation traffic.
  350. #
  351. # This setting should only normally be used within a private network of
  352. # homeservers.
  353. #
  354. # Note that this list will replace those that are provided by your
  355. # operating environment. Certificates must be in PEM format.
  356. #
  357. #federation_custom_ca_list:
  358. #  - myCA1.pem
  359. #  - myCA2.pem
  360. #  - myCA3.pem
  361.  
  362. # ACME support: This will configure Synapse to request a valid TLS certificate
  363. # for your configured `server_name` via Let's Encrypt.
  364. #
  365. # Note that provisioning a certificate in this way requires port 80 to be
  366. # routed to Synapse so that it can complete the http-01 ACME challenge.
  367. # By default, if you enable ACME support, Synapse will attempt to listen on
  368. # port 80 for incoming http-01 challenges - however, this will likely fail
  369. # with 'Permission denied' or a similar error.
  370. #
  371. # There are a couple of potential solutions to this:
  372. #
  373. #  * If you already have an Apache, Nginx, or similar listening on port 80,
  374. #    you can configure Synapse to use an alternate port, and have your web
  375. #    server forward the requests. For example, assuming you set 'port: 8009'
  376. #    below, on Apache, you would write:
  377. #
  378. #    ProxyPass /.well-known/acme-challenge http://localhost:8009/.well-known/acme-challenge
  379. #
  380. #  * Alternatively, you can use something like `authbind` to give Synapse
  381. #    permission to listen on port 80.
  382. #
  383. acme:
  384.    # ACME support is disabled by default. Uncomment the following line
  385.     # (and tls_certificate_path and tls_private_key_path above) to enable it.
  386.     #
  387.     #enabled: true
  388.  
  389.     # Endpoint to use to request certificates. If you only want to test,
  390.     # use Let's Encrypt's staging url:
  391.     #     https://acme-staging.api.letsencrypt.org/directory
  392.     #
  393.     #url: https://acme-v01.api.letsencrypt.org/directory
  394.  
  395.     # Port number to listen on for the HTTP-01 challenge. Change this if
  396.     # you are forwarding connections through Apache/Nginx/etc.
  397.     #
  398.     #port: 80
  399.  
  400.     # Local addresses to listen on for incoming connections.
  401.     # Again, you may want to change this if you are forwarding connections
  402.     # through Apache/Nginx/etc.
  403.     #
  404.     #bind_addresses: ['::', '0.0.0.0']
  405.  
  406.     # How many days remaining on a certificate before it is renewed.
  407.     #
  408.     #reprovision_threshold: 30
  409.  
  410.     # The domain that the certificate should be for. Normally this
  411.     # should be the same as your Matrix domain (i.e., 'server_name'), but,
  412.     # by putting a file at 'https://<server_name>/.well-known/matrix/server',
  413.     # you can delegate incoming traffic to another server. If you do that,
  414.     # you should give the target of the delegation here.
  415.     #
  416.     # For example: if your 'server_name' is 'example.com', but
  417.     # 'https://example.com/.well-known/matrix/server' delegates to
  418.     # 'matrix.example.com', you should put 'matrix.example.com' here.
  419.     #
  420.     # If not set, defaults to your 'server_name'.
  421.     #
  422.     #domain: matrix.example.com
  423.  
  424.     # file to use for the account key. This will be generated if it doesn't
  425.     # exist.
  426.     #
  427.     # If unspecified, we will use CONFDIR/client.key.
  428.     #
  429.     account_key_file: /data/acme_account.key
  430.  
  431. # List of allowed TLS fingerprints for this server to publish along
  432. # with the signing keys for this server. Other matrix servers that
  433. # make HTTPS requests to this server will check that the TLS
  434. # certificates returned by this server match one of the fingerprints.
  435. #
  436. # Synapse automatically adds the fingerprint of its own certificate
  437. # to the list. So if federation traffic is handled directly by synapse
  438. # then no modification to the list is required.
  439. #
  440. # If synapse is run behind a load balancer that handles the TLS then it
  441. # will be necessary to add the fingerprints of the certificates used by
  442. # the loadbalancers to this list if they are different to the one
  443. # synapse is using.
  444. #
  445. # Homeservers are permitted to cache the list of TLS fingerprints
  446. # returned in the key responses up to the "valid_until_ts" returned in
  447. # key. It may be necessary to publish the fingerprints of a new
  448. # certificate and wait until the "valid_until_ts" of the previous key
  449. # responses have passed before deploying it.
  450. #
  451. # You can calculate a fingerprint from a given TLS listener via:
  452. # openssl s_client -connect $host:$port < /dev/null 2> /dev/null |
  453. #   openssl x509 -outform DER | openssl sha256 -binary | base64 | tr -d '='
  454. # or by checking matrix.org/federationtester/api/report?server_name=$host
  455. #
  456. #tls_fingerprints: [{"sha256": "<base64_encoded_sha256_fingerprint>"}]
  457.  
  458.  
  459.  
  460. ## Database ##
  461.  
  462. database:
  463.  # The database engine name
  464.   name: "sqlite3"
  465.   # Arguments to pass to the engine
  466.   args:
  467.    # Path to the database
  468.     database: "/data/homeserver.db"
  469.  
  470. # Number of events to cache in memory.
  471. #
  472. #event_cache_size: 10K
  473.  
  474.  
  475. ## Logging ##
  476.  
  477. # A yaml python logging config file
  478. #
  479. log_config: "/data/m1.local:8008.log.config"
  480.  
  481.  
  482. ## Ratelimiting ##
  483.  
  484. # Ratelimiting settings for client actions (registration, login, messaging).
  485. #
  486. # Each ratelimiting configuration is made of two parameters:
  487. #   - per_second: number of requests a client can send per second.
  488. #   - burst_count: number of requests a client can send before being throttled.
  489. #
  490. # Synapse currently uses the following configurations:
  491. #   - one for messages that ratelimits sending based on the account the client
  492. #     is using
  493. #   - one for registration that ratelimits registration requests based on the
  494. #     client's IP address.
  495. #   - one for login that ratelimits login requests based on the client's IP
  496. #     address.
  497. #   - one for login that ratelimits login requests based on the account the
  498. #     client is attempting to log into.
  499. #   - one for login that ratelimits login requests based on the account the
  500. #     client is attempting to log into, based on the amount of failed login
  501. #     attempts for this account.
  502. #
  503. # The defaults are as shown below.
  504. #
  505. #rc_message:
  506. #  per_second: 0.2
  507. #  burst_count: 10
  508. #
  509. #rc_registration:
  510. #  per_second: 0.17
  511. #  burst_count: 3
  512. #
  513. #rc_login:
  514. #  address:
  515. #    per_second: 0.17
  516. #    burst_count: 3
  517. #  account:
  518. #    per_second: 0.17
  519. #    burst_count: 3
  520. #  failed_attempts:
  521. #    per_second: 0.17
  522. #    burst_count: 3
  523.  
  524.  
  525. # Ratelimiting settings for incoming federation
  526. #
  527. # The rc_federation configuration is made up of the following settings:
  528. #   - window_size: window size in milliseconds
  529. #   - sleep_limit: number of federation requests from a single server in
  530. #     a window before the server will delay processing the request.
  531. #   - sleep_delay: duration in milliseconds to delay processing events
  532. #     from remote servers by if they go over the sleep limit.
  533. #   - reject_limit: maximum number of concurrent federation requests
  534. #     allowed from a single server
  535. #   - concurrent: number of federation requests to concurrently process
  536. #     from a single server
  537. #
  538. # The defaults are as shown below.
  539. #
  540. #rc_federation:
  541. #  window_size: 1000
  542. #  sleep_limit: 10
  543. #  sleep_delay: 500
  544. #  reject_limit: 50
  545. #  concurrent: 3
  546.  
  547. # Target outgoing federation transaction frequency for sending read-receipts,
  548. # per-room.
  549. #
  550. # If we end up trying to send out more read-receipts, they will get buffered up
  551. # into fewer transactions.
  552. #
  553. #federation_rr_transactions_per_room_per_second: 50
  554.  
  555.  
  556.  
  557. ## Media Store ##
  558.  
  559. # Enable the media store service in the Synapse master. Uncomment the
  560. # following if you are using a separate media store worker.
  561. #
  562. #enable_media_repo: false
  563.  
  564. # Directory where uploaded images and attachments are stored.
  565. #
  566. media_store_path: "/data/media_store"
  567.  
  568. # Media storage providers allow media to be stored in different
  569. # locations.
  570. #
  571. #media_storage_providers:
  572. #  - module: file_system
  573. #    # Whether to write new local files.
  574. #    store_local: false
  575. #    # Whether to write new remote media
  576. #    store_remote: false
  577. #    # Whether to block upload requests waiting for write to this
  578. #    # provider to complete
  579. #    store_synchronous: false
  580. #    config:
  581. #       directory: /mnt/some/other/directory
  582.  
  583. # Directory where in-progress uploads are stored.
  584. #
  585. uploads_path: "/data/uploads"
  586.  
  587. # The largest allowed upload size in bytes
  588. #
  589. #max_upload_size: 10M
  590.  
  591. # Maximum number of pixels that will be thumbnailed
  592. #
  593. #max_image_pixels: 32M
  594.  
  595. # Whether to generate new thumbnails on the fly to precisely match
  596. # the resolution requested by the client. If true then whenever
  597. # a new resolution is requested by the client the server will
  598. # generate a new thumbnail. If false the server will pick a thumbnail
  599. # from a precalculated list.
  600. #
  601. #dynamic_thumbnails: false
  602.  
  603. # List of thumbnails to precalculate when an image is uploaded.
  604. #
  605. #thumbnail_sizes:
  606. #  - width: 32
  607. #    height: 32
  608. #    method: crop
  609. #  - width: 96
  610. #    height: 96
  611. #    method: crop
  612. #  - width: 320
  613. #    height: 240
  614. #    method: scale
  615. #  - width: 640
  616. #    height: 480
  617. #    method: scale
  618. #  - width: 800
  619. #    height: 600
  620. #    method: scale
  621.  
  622. # Is the preview URL API enabled?
  623. #
  624. # 'false' by default: uncomment the following to enable it (and specify a
  625. # url_preview_ip_range_blacklist blacklist).
  626. #
  627. #url_preview_enabled: true
  628.  
  629. # List of IP address CIDR ranges that the URL preview spider is denied
  630. # from accessing.  There are no defaults: you must explicitly
  631. # specify a list for URL previewing to work.  You should specify any
  632. # internal services in your network that you do not want synapse to try
  633. # to connect to, otherwise anyone in any Matrix room could cause your
  634. # synapse to issue arbitrary GET requests to your internal services,
  635. # causing serious security issues.
  636. #
  637. # (0.0.0.0 and :: are always blacklisted, whether or not they are explicitly
  638. # listed here, since they correspond to unroutable addresses.)
  639. #
  640. # This must be specified if url_preview_enabled is set. It is recommended that
  641. # you uncomment the following list as a starting point.
  642. #
  643. #url_preview_ip_range_blacklist:
  644. #  - '127.0.0.0/8'
  645. #  - '10.0.0.0/8'
  646. #  - '172.16.0.0/12'
  647. #  - '192.168.0.0/16'
  648. #  - '100.64.0.0/10'
  649. #  - '169.254.0.0/16'
  650. #  - '::1/128'
  651. #  - 'fe80::/64'
  652. #  - 'fc00::/7'
  653.  
  654. # List of IP address CIDR ranges that the URL preview spider is allowed
  655. # to access even if they are specified in url_preview_ip_range_blacklist.
  656. # This is useful for specifying exceptions to wide-ranging blacklisted
  657. # target IP ranges - e.g. for enabling URL previews for a specific private
  658. # website only visible in your network.
  659. #
  660. #url_preview_ip_range_whitelist:
  661. #   - '192.168.1.1'
  662.  
  663. # Optional list of URL matches that the URL preview spider is
  664. # denied from accessing.  You should use url_preview_ip_range_blacklist
  665. # in preference to this, otherwise someone could define a public DNS
  666. # entry that points to a private IP address and circumvent the blacklist.
  667. # This is more useful if you know there is an entire shape of URL that
  668. # you know that will never want synapse to try to spider.
  669. #
  670. # Each list entry is a dictionary of url component attributes as returned
  671. # by urlparse.urlsplit as applied to the absolute form of the URL.  See
  672. # https://docs.python.org/2/library/urlparse.html#urlparse.urlsplit
  673. # The values of the dictionary are treated as an filename match pattern
  674. # applied to that component of URLs, unless they start with a ^ in which
  675. # case they are treated as a regular expression match.  If all the
  676. # specified component matches for a given list item succeed, the URL is
  677. # blacklisted.
  678. #
  679. #url_preview_url_blacklist:
  680. #  # blacklist any URL with a username in its URI
  681. #  - username: '*'
  682. #
  683. #  # blacklist all *.google.com URLs
  684. #  - netloc: 'google.com'
  685. #  - netloc: '*.google.com'
  686. #
  687. #  # blacklist all plain HTTP URLs
  688. #  - scheme: 'http'
  689. #
  690. #  # blacklist http(s)://www.acme.com/foo
  691. #  - netloc: 'www.acme.com'
  692. #    path: '/foo'
  693. #
  694. #  # blacklist any URL with a literal IPv4 address
  695. #  - netloc: '^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$'
  696.  
  697. # The largest allowed URL preview spidering size in bytes
  698. #
  699. #max_spider_size: 10M
  700.  
  701.  
  702. ## Captcha ##
  703. # See docs/CAPTCHA_SETUP for full details of configuring this.
  704.  
  705. # This Home Server's ReCAPTCHA public key.
  706. #
  707. #recaptcha_public_key: "YOUR_PUBLIC_KEY"
  708.  
  709. # This Home Server's ReCAPTCHA private key.
  710. #
  711. #recaptcha_private_key: "YOUR_PRIVATE_KEY"
  712.  
  713. # Enables ReCaptcha checks when registering, preventing signup
  714. # unless a captcha is answered. Requires a valid ReCaptcha
  715. # public/private key.
  716. #
  717. #enable_registration_captcha: false
  718.  
  719. # A secret key used to bypass the captcha test entirely.
  720. #
  721. #captcha_bypass_secret: "YOUR_SECRET_HERE"
  722.  
  723. # The API endpoint to use for verifying m.login.recaptcha responses.
  724. #
  725. #recaptcha_siteverify_api: "https://www.recaptcha.net/recaptcha/api/siteverify"
  726.  
  727.  
  728. ## TURN ##
  729.  
  730. # The public URIs of the TURN server to give to clients
  731. #
  732. #turn_uris: []
  733.  
  734. # The shared secret used to compute passwords for the TURN server
  735. #
  736. #turn_shared_secret: "YOUR_SHARED_SECRET"
  737.  
  738. # The Username and password if the TURN server needs them and
  739. # does not use a token
  740. #
  741. #turn_username: "TURNSERVER_USERNAME"
  742. #turn_password: "TURNSERVER_PASSWORD"
  743.  
  744. # How long generated TURN credentials last
  745. #
  746. #turn_user_lifetime: 1h
  747.  
  748. # Whether guests should be allowed to use the TURN server.
  749. # This defaults to True, otherwise VoIP will be unreliable for guests.
  750. # However, it does introduce a slight security risk as it allows users to
  751. # connect to arbitrary endpoints without having first signed up for a
  752. # valid account (e.g. by passing a CAPTCHA).
  753. #
  754. #turn_allow_guests: True
  755.  
  756.  
  757. ## Registration ##
  758. #
  759. # Registration can be rate-limited using the parameters in the "Ratelimiting"
  760. # section of this file.
  761.  
  762. # Enable registration for new users.
  763. #
  764. #enable_registration: false
  765.  
  766. # Optional account validity configuration. This allows for accounts to be denied
  767. # any request after a given period.
  768. #
  769. # ``enabled`` defines whether the account validity feature is enabled. Defaults
  770. # to False.
  771. #
  772. # ``period`` allows setting the period after which an account is valid
  773. # after its registration. When renewing the account, its validity period
  774. # will be extended by this amount of time. This parameter is required when using
  775. # the account validity feature.
  776. #
  777. # ``renew_at`` is the amount of time before an account's expiry date at which
  778. # Synapse will send an email to the account's email address with a renewal link.
  779. # This needs the ``email`` and ``public_baseurl`` configuration sections to be
  780. # filled.
  781. #
  782. # ``renew_email_subject`` is the subject of the email sent out with the renewal
  783. # link. ``%(app)s`` can be used as a placeholder for the ``app_name`` parameter
  784. # from the ``email`` section.
  785. #
  786. # Once this feature is enabled, Synapse will look for registered users without an
  787. # expiration date at startup and will add one to every account it found using the
  788. # current settings at that time.
  789. # This means that, if a validity period is set, and Synapse is restarted (it will
  790. # then derive an expiration date from the current validity period), and some time
  791. # after that the validity period changes and Synapse is restarted, the users'
  792. # expiration dates won't be updated unless their account is manually renewed. This
  793. # date will be randomly selected within a range [now + period - d ; now + period],
  794. # where d is equal to 10% of the validity period.
  795. #
  796. #account_validity:
  797. #  enabled: True
  798. #  period: 6w
  799. #  renew_at: 1w
  800. #  renew_email_subject: "Renew your %(app)s account"
  801. #  # Directory in which Synapse will try to find the HTML files to serve to the
  802. #  # user when trying to renew an account. Optional, defaults to
  803. #  # synapse/res/templates.
  804. #  template_dir: "res/templates"
  805. #  # HTML to be displayed to the user after they successfully renewed their
  806. #  # account. Optional.
  807. #  account_renewed_html_path: "account_renewed.html"
  808. #  # HTML to be displayed when the user tries to renew an account with an invalid
  809. #  # renewal token. Optional.
  810. #  invalid_token_html_path: "invalid_token.html"
  811.  
  812. # Time that a user's session remains valid for, after they log in.
  813. #
  814. # Note that this is not currently compatible with guest logins.
  815. #
  816. # Note also that this is calculated at login time: changes are not applied
  817. # retrospectively to users who have already logged in.
  818. #
  819. # By default, this is infinite.
  820. #
  821. #session_lifetime: 24h
  822.  
  823. # The user must provide all of the below types of 3PID when registering.
  824. #
  825. #registrations_require_3pid:
  826. #  - email
  827. #  - msisdn
  828.  
  829. # Explicitly disable asking for MSISDNs from the registration
  830. # flow (overrides registrations_require_3pid if MSISDNs are set as required)
  831. #
  832. #disable_msisdn_registration: true
  833.  
  834. # Mandate that users are only allowed to associate certain formats of
  835. # 3PIDs with accounts on this server.
  836. #
  837. #allowed_local_3pids:
  838. #  - medium: email
  839. #    pattern: '.*@matrix\.org'
  840. #  - medium: email
  841. #    pattern: '.*@vector\.im'
  842. #  - medium: msisdn
  843. #    pattern: '\+44'
  844.  
  845. # Enable 3PIDs lookup requests to identity servers from this server.
  846. #
  847. #enable_3pid_lookup: true
  848.  
  849. # If set, allows registration of standard or admin accounts by anyone who
  850. # has the shared secret, even if registration is otherwise disabled.
  851. #
  852. registration_shared_secret: "N~~=O2YC_X5u7ThkSctc5o^xue&*esBH-9KWVRp=jQ,5_-,L0;"
  853.  
  854. # Set the number of bcrypt rounds used to generate password hash.
  855. # Larger numbers increase the work factor needed to generate the hash.
  856. # The default number is 12 (which equates to 2^12 rounds).
  857. # N.B. that increasing this will exponentially increase the time required
  858. # to register or login - e.g. 24 => 2^24 rounds which will take >20 mins.
  859. #
  860. #bcrypt_rounds: 12
  861.  
  862. # Allows users to register as guests without a password/email/etc, and
  863. # participate in rooms hosted on this server which have been made
  864. # accessible to anonymous users.
  865. #
  866. #allow_guest_access: false
  867.  
  868. # The identity server which we suggest that clients should use when users log
  869. # in on this server.
  870. #
  871. # (By default, no suggestion is made, so it is left up to the client.
  872. # This setting is ignored unless public_baseurl is also set.)
  873. #
  874. #default_identity_server: https://matrix.org
  875.  
  876. # The list of identity servers trusted to verify third party
  877. # identifiers by this server.
  878. #
  879. # Also defines the ID server which will be called when an account is
  880. # deactivated (one will be picked arbitrarily).
  881. #
  882. #trusted_third_party_id_servers:
  883. #  - matrix.org
  884. #  - vector.im
  885.  
  886. # Users who register on this homeserver will automatically be joined
  887. # to these rooms
  888. #
  889. #auto_join_rooms:
  890. #  - "#example:example.com"
  891.  
  892. # Where auto_join_rooms are specified, setting this flag ensures that the
  893. # the rooms exist by creating them when the first user on the
  894. # homeserver registers.
  895. # Setting to false means that if the rooms are not manually created,
  896. # users cannot be auto-joined since they do not exist.
  897. #
  898. #autocreate_auto_join_rooms: true
  899.  
  900.  
  901. ## Metrics ###
  902.  
  903. # Enable collection and rendering of performance metrics
  904. #
  905. #enable_metrics: False
  906.  
  907. # Enable sentry integration
  908. # NOTE: While attempts are made to ensure that the logs don't contain
  909. # any sensitive information, this cannot be guaranteed. By enabling
  910. # this option the sentry server may therefore receive sensitive
  911. # information, and it in turn may then diseminate sensitive information
  912. # through insecure notification channels if so configured.
  913. #
  914. #sentry:
  915. #    dsn: "..."
  916.  
  917. # Whether or not to report anonymized homeserver usage statistics.
  918. report_stats: true
  919.  
  920.  
  921. ## API Configuration ##
  922.  
  923. # A list of event types that will be included in the room_invite_state
  924. #
  925. #room_invite_state_types:
  926. #  - "m.room.join_rules"
  927. #  - "m.room.canonical_alias"
  928. #  - "m.room.avatar"
  929. #  - "m.room.encryption"
  930. #  - "m.room.name"
  931.  
  932.  
  933. # A list of application service config files to use
  934. #
  935. #app_service_config_files:
  936. #  - app_service_1.yaml
  937. #  - app_service_2.yaml
  938.  
  939. # Uncomment to enable tracking of application service IP addresses. Implicitly
  940. # enables MAU tracking for application service users.
  941. #
  942. #track_appservice_user_ips: True
  943.  
  944.  
  945. # a secret which is used to sign access tokens. If none is specified,
  946. # the registration_shared_secret is used, if one is given; otherwise,
  947. # a secret key is derived from the signing key.
  948. #
  949. macaroon_secret_key: "A.1-xa0U8Q6W:MxnLaDZzQd#BUX7noKdHU_0:tnGc1i+p-vcnb"
  950.  
  951. # a secret which is used to calculate HMACs for form values, to stop
  952. # falsification of values. Must be specified for the User Consent
  953. # forms to work.
  954. #
  955. form_secret: "lHz6tx33IcHD+zr,RiuCy6PL1_;.fZpP9nl#Jqv*G,~c9NTd2L"
  956.  
  957. ## Signing Keys ##
  958.  
  959. # Path to the signing key to sign messages with
  960. #
  961. signing_key_path: "/data/m1.local:8008.signing.key"
  962.  
  963. # The keys that the server used to sign messages with but won't use
  964. # to sign new messages. E.g. it has lost its private key
  965. #
  966. #old_signing_keys:
  967. #  "ed25519:auto":
  968. #    # Base64 encoded public key
  969. #    key: "The public part of your old signing key."
  970. #    # Millisecond POSIX timestamp when the key expired.
  971. #    expired_ts: 123456789123
  972.  
  973. # How long key response published by this server is valid for.
  974. # Used to set the valid_until_ts in /key/v2 APIs.
  975. # Determines how quickly servers will query to check which keys
  976. # are still valid.
  977. #
  978. #key_refresh_interval: 1d
  979.  
  980. # The trusted servers to download signing keys from.
  981. #
  982. # When we need to fetch a signing key, each server is tried in parallel.
  983. #
  984. # Normally, the connection to the key server is validated via TLS certificates.
  985. # Additional security can be provided by configuring a `verify key`, which
  986. # will make synapse check that the response is signed by that key.
  987. #
  988. # This setting supercedes an older setting named `perspectives`. The old format
  989. # is still supported for backwards-compatibility, but it is deprecated.
  990. #
  991. # Options for each entry in the list include:
  992. #
  993. #    server_name: the name of the server. required.
  994. #
  995. #    verify_keys: an optional map from key id to base64-encoded public key.
  996. #       If specified, we will check that the response is signed by at least
  997. #       one of the given keys.
  998. #
  999. #    accept_keys_insecurely: a boolean. Normally, if `verify_keys` is unset,
  1000. #       and federation_verify_certificates is not `true`, synapse will refuse
  1001. #       to start, because this would allow anyone who can spoof DNS responses
  1002. #       to masquerade as the trusted key server. If you know what you are doing
  1003. #       and are sure that your network environment provides a secure connection
  1004. #       to the key server, you can set this to `true` to override this
  1005. #       behaviour.
  1006. #
  1007. # An example configuration might look like:
  1008. #
  1009. #trusted_key_servers:
  1010. #  - server_name: "my_trusted_server.example.com"
  1011. #    verify_keys:
  1012. #      "ed25519:auto": "abcdefghijklmnopqrstuvwxyzabcdefghijklmopqr"
  1013. #  - server_name: "my_other_trusted_server.example.com"
  1014. #
  1015. # The default configuration is:
  1016. #
  1017. #trusted_key_servers:
  1018. #  - server_name: "matrix.org"
  1019.  
  1020.  
  1021. # Enable SAML2 for registration and login. Uses pysaml2.
  1022. #
  1023. # `sp_config` is the configuration for the pysaml2 Service Provider.
  1024. # See pysaml2 docs for format of config.
  1025. #
  1026. # Default values will be used for the 'entityid' and 'service' settings,
  1027. # so it is not normally necessary to specify them unless you need to
  1028. # override them.
  1029. #
  1030. # Once SAML support is enabled, a metadata file will be exposed at
  1031. # https://<server>:<port>/_matrix/saml2/metadata.xml, which you may be able to
  1032. # use to configure your SAML IdP with. Alternatively, you can manually configure
  1033. # the IdP to use an ACS location of
  1034. # https://<server>:<port>/_matrix/saml2/authn_response.
  1035. #
  1036. #saml2_config:
  1037. #  sp_config:
  1038. #    # point this to the IdP's metadata. You can use either a local file or
  1039. #    # (preferably) a URL.
  1040. #    metadata:
  1041. #      #local: ["saml2/idp.xml"]
  1042. #      remote:
  1043. #        - url: https://our_idp/metadata.xml
  1044. #
  1045. #    # By default, the user has to go to our login page first. If you'd like to
  1046. #    # allow IdP-initiated login, set 'allow_unsolicited: True' in a
  1047. #    # 'service.sp' section:
  1048. #    #
  1049. #    #service:
  1050. #    #  sp:
  1051. #    #    allow_unsolicited: True
  1052. #
  1053. #    # The examples below are just used to generate our metadata xml, and you
  1054. #    # may well not need it, depending on your setup. Alternatively you
  1055. #    # may need a whole lot more detail - see the pysaml2 docs!
  1056. #
  1057. #    description: ["My awesome SP", "en"]
  1058. #    name: ["Test SP", "en"]
  1059. #
  1060. #    organization:
  1061. #      name: Example com
  1062. #      display_name:
  1063. #        - ["Example co", "en"]
  1064. #      url: "http://example.com"
  1065. #
  1066. #    contact_person:
  1067. #      - given_name: Bob
  1068. #        sur_name: "the Sysadmin"
  1069. #        email_address": ["admin@example.com"]
  1070. #        contact_type": technical
  1071. #
  1072. #  # Instead of putting the config inline as above, you can specify a
  1073. #  # separate pysaml2 configuration file:
  1074. #  #
  1075. #  config_path: "/data/sp_conf.py"
  1076. #
  1077. #  # the lifetime of a SAML session. This defines how long a user has to
  1078. #  # complete the authentication process, if allow_unsolicited is unset.
  1079. #  # The default is 5 minutes.
  1080. #  #
  1081. #  # saml_session_lifetime: 5m
  1082.  
  1083.  
  1084.  
  1085. # Enable CAS for registration and login.
  1086. #
  1087. #cas_config:
  1088. #   enabled: true
  1089. #   server_url: "https://cas-server.com"
  1090. #   service_url: "https://homeserver.domain.com:8448"
  1091. #   #required_attributes:
  1092. #   #    name: value
  1093.  
  1094.  
  1095. # The JWT needs to contain a globally unique "sub" (subject) claim.
  1096. #
  1097. #jwt_config:
  1098. #   enabled: true
  1099. #   secret: "a secret"
  1100. #   algorithm: "HS256"
  1101.  
  1102.  
  1103. password_config:
  1104.   # Uncomment to disable password login
  1105.    #
  1106.    #enabled: false
  1107.  
  1108.    # Uncomment to disable authentication against the local password
  1109.    # database. This is ignored if `enabled` is false, and is only useful
  1110.    # if you have other password_providers.
  1111.    #
  1112.    #localdb_enabled: false
  1113.  
  1114.    # Uncomment and change to a secret random string for extra security.
  1115.    # DO NOT CHANGE THIS AFTER INITIAL SETUP!
  1116.    #
  1117.    #pepper: "EVEN_MORE_SECRET"
  1118.  
  1119.  
  1120.  
  1121. # Enable sending emails for password resets, notification events or
  1122. # account expiry notices
  1123. #
  1124. # If your SMTP server requires authentication, the optional smtp_user &
  1125. # smtp_pass variables should be used
  1126. #
  1127. #email:
  1128. #   enable_notifs: false
  1129. #   smtp_host: "localhost"
  1130. #   smtp_port: 25 # SSL: 465, STARTTLS: 587
  1131. #   smtp_user: "exampleusername"
  1132. #   smtp_pass: "examplepassword"
  1133. #   require_transport_security: False
  1134. #   notif_from: "Your Friendly %(app)s Home Server <noreply@example.com>"
  1135. #   app_name: Matrix
  1136. #
  1137. #   # Enable email notifications by default
  1138. #   #
  1139. #   notif_for_new_users: True
  1140. #
  1141. #   # Defining a custom URL for Riot is only needed if email notifications
  1142. #   # should contain links to a self-hosted installation of Riot; when set
  1143. #   # the "app_name" setting is ignored
  1144. #   #
  1145. #   riot_base_url: "http://localhost/riot"
  1146. #
  1147. #   # Enable sending password reset emails via the configured, trusted
  1148. #   # identity servers
  1149. #   #
  1150. #   # IMPORTANT! This will give a malicious or overtaken identity server
  1151. #   # the ability to reset passwords for your users! Make absolutely sure
  1152. #   # that you want to do this! It is strongly recommended that password
  1153. #   # reset emails be sent by the homeserver instead
  1154. #   #
  1155. #   # If this option is set to false and SMTP options have not been
  1156. #   # configured, resetting user passwords via email will be disabled
  1157. #   #
  1158. #   #trust_identity_server_for_password_resets: false
  1159. #
  1160. #   # Configure the time that a validation email or text message code
  1161. #   # will expire after sending
  1162. #   #
  1163. #   # This is currently used for password resets
  1164. #   #
  1165. #   #validation_token_lifetime: 1h
  1166. #
  1167. #   # Template directory. All template files should be stored within this
  1168. #   # directory. If not set, default templates from within the Synapse
  1169. #   # package will be used
  1170. #   #
  1171. #   # For the list of default templates, please see
  1172. #   # https://github.com/matrix-org/synapse/tree/master/synapse/res/templates
  1173. #   #
  1174. #   #template_dir: res/templates
  1175. #
  1176. #   # Templates for email notifications
  1177. #   #
  1178. #   notif_template_html: notif_mail.html
  1179. #   notif_template_text: notif_mail.txt
  1180. #
  1181. #   # Templates for account expiry notices
  1182. #   #
  1183. #   expiry_template_html: notice_expiry.html
  1184. #   expiry_template_text: notice_expiry.txt
  1185. #
  1186. #   # Templates for password reset emails sent by the homeserver
  1187. #   #
  1188. #   #password_reset_template_html: password_reset.html
  1189. #   #password_reset_template_text: password_reset.txt
  1190. #
  1191. #   # Templates for password reset success and failure pages that a user
  1192. #   # will see after attempting to reset their password
  1193. #   #
  1194. #   #password_reset_template_success_html: password_reset_success.html
  1195. #   #password_reset_template_failure_html: password_reset_failure.html
  1196.  
  1197.  
  1198. #password_providers:
  1199. #    - module: "ldap_auth_provider.LdapAuthProvider"
  1200. #      config:
  1201. #        enabled: true
  1202. #        uri: "ldap://ldap.example.com:389"
  1203. #        start_tls: true
  1204. #        base: "ou=users,dc=example,dc=com"
  1205. #        attributes:
  1206. #           uid: "cn"
  1207. #           mail: "email"
  1208. #           name: "givenName"
  1209. #        #bind_dn:
  1210. #        #bind_password:
  1211. #        #filter: "(objectClass=posixAccount)"
  1212.  
  1213.  
  1214.  
  1215. # Clients requesting push notifications can either have the body of
  1216. # the message sent in the notification poke along with other details
  1217. # like the sender, or just the event ID and room ID (`event_id_only`).
  1218. # If clients choose the former, this option controls whether the
  1219. # notification request includes the content of the event (other details
  1220. # like the sender are still included). For `event_id_only` push, it
  1221. # has no effect.
  1222. #
  1223. # For modern android devices the notification content will still appear
  1224. # because it is loaded by the app. iPhone, however will send a
  1225. # notification saying only that a message arrived and who it came from.
  1226. #
  1227. #push:
  1228. #  include_content: true
  1229.  
  1230.  
  1231. #spam_checker:
  1232. #  module: "my_custom_project.SuperSpamChecker"
  1233. #  config:
  1234. #    example_option: 'things'
  1235.  
  1236.  
  1237. # Uncomment to allow non-server-admin users to create groups on this server
  1238. #
  1239. #enable_group_creation: true
  1240.  
  1241. # If enabled, non server admins can only create groups with local parts
  1242. # starting with this prefix
  1243. #
  1244. #group_creation_prefix: "unofficial/"
  1245.  
  1246.  
  1247.  
  1248. # User Directory configuration
  1249. #
  1250. # 'enabled' defines whether users can search the user directory. If
  1251. # false then empty responses are returned to all queries. Defaults to
  1252. # true.
  1253. #
  1254. # 'search_all_users' defines whether to search all users visible to your HS
  1255. # when searching the user directory, rather than limiting to users visible
  1256. # in public rooms.  Defaults to false.  If you set it True, you'll have to
  1257. # rebuild the user_directory search indexes, see
  1258. # https://github.com/matrix-org/synapse/blob/master/docs/user_directory.md
  1259. #
  1260. #user_directory:
  1261. #  enabled: true
  1262. #  search_all_users: false
  1263.  
  1264.  
  1265. # User Consent configuration
  1266. #
  1267. # for detailed instructions, see
  1268. # https://github.com/matrix-org/synapse/blob/master/docs/consent_tracking.md
  1269. #
  1270. # Parts of this section are required if enabling the 'consent' resource under
  1271. # 'listeners', in particular 'template_dir' and 'version'.
  1272. #
  1273. # 'template_dir' gives the location of the templates for the HTML forms.
  1274. # This directory should contain one subdirectory per language (eg, 'en', 'fr'),
  1275. # and each language directory should contain the policy document (named as
  1276. # '<version>.html') and a success page (success.html).
  1277. #
  1278. # 'version' specifies the 'current' version of the policy document. It defines
  1279. # the version to be served by the consent resource if there is no 'v'
  1280. # parameter.
  1281. #
  1282. # 'server_notice_content', if enabled, will send a user a "Server Notice"
  1283. # asking them to consent to the privacy policy. The 'server_notices' section
  1284. # must also be configured for this to work. Notices will *not* be sent to
  1285. # guest users unless 'send_server_notice_to_guests' is set to true.
  1286. #
  1287. # 'block_events_error', if set, will block any attempts to send events
  1288. # until the user consents to the privacy policy. The value of the setting is
  1289. # used as the text of the error.
  1290. #
  1291. # 'require_at_registration', if enabled, will add a step to the registration
  1292. # process, similar to how captcha works. Users will be required to accept the
  1293. # policy before their account is created.
  1294. #
  1295. # 'policy_name' is the display name of the policy users will see when registering
  1296. # for an account. Has no effect unless `require_at_registration` is enabled.
  1297. # Defaults to "Privacy Policy".
  1298. #
  1299. #user_consent:
  1300. #  template_dir: res/templates/privacy
  1301. #  version: 1.0
  1302. #  server_notice_content:
  1303. #    msgtype: m.text
  1304. #    body: >-
  1305. #      To continue using this homeserver you must review and agree to the
  1306. #      terms and conditions at %(consent_uri)s
  1307. #  send_server_notice_to_guests: True
  1308. #  block_events_error: >-
  1309. #    To continue using this homeserver you must review and agree to the
  1310. #    terms and conditions at %(consent_uri)s
  1311. #  require_at_registration: False
  1312. #  policy_name: Privacy Policy
  1313. #
  1314.  
  1315.  
  1316.  
  1317. # Local statistics collection. Used in populating the room directory.
  1318. #
  1319. # 'bucket_size' controls how large each statistics timeslice is. It can
  1320. # be defined in a human readable short form -- e.g. "1d", "1y".
  1321. #
  1322. # 'retention' controls how long historical statistics will be kept for.
  1323. # It can be defined in a human readable short form -- e.g. "1d", "1y".
  1324. #
  1325. #
  1326. #stats:
  1327. #   enabled: true
  1328. #   bucket_size: 1d
  1329. #   retention: 1y
  1330.  
  1331.  
  1332. # Server Notices room configuration
  1333. #
  1334. # Uncomment this section to enable a room which can be used to send notices
  1335. # from the server to users. It is a special room which cannot be left; notices
  1336. # come from a special "notices" user id.
  1337. #
  1338. # If you uncomment this section, you *must* define the system_mxid_localpart
  1339. # setting, which defines the id of the user which will be used to send the
  1340. # notices.
  1341. #
  1342. # It's also possible to override the room name, the display name of the
  1343. # "notices" user, and the avatar for the user.
  1344. #
  1345. #server_notices:
  1346. #  system_mxid_localpart: notices
  1347. #  system_mxid_display_name: "Server Notices"
  1348. #  system_mxid_avatar_url: "mxc://server.com/oumMVlgDnLYFaPVkExemNVVZ"
  1349. #  room_name: "Server Notices"
  1350.  
  1351.  
  1352.  
  1353. # Uncomment to disable searching the public room list. When disabled
  1354. # blocks searching local and remote room lists for local and remote
  1355. # users by always returning an empty list for all queries.
  1356. #
  1357. #enable_room_list_search: false
  1358.  
  1359. # The `alias_creation` option controls who's allowed to create aliases
  1360. # on this server.
  1361. #
  1362. # The format of this option is a list of rules that contain globs that
  1363. # match against user_id, room_id and the new alias (fully qualified with
  1364. # server name). The action in the first rule that matches is taken,
  1365. # which can currently either be "allow" or "deny".
  1366. #
  1367. # Missing user_id/room_id/alias fields default to "*".
  1368. #
  1369. # If no rules match the request is denied. An empty list means no one
  1370. # can create aliases.
  1371. #
  1372. # Options for the rules include:
  1373. #
  1374. #   user_id: Matches against the creator of the alias
  1375. #   alias: Matches against the alias being created
  1376. #   room_id: Matches against the room ID the alias is being pointed at
  1377. #   action: Whether to "allow" or "deny" the request if the rule matches
  1378. #
  1379. # The default is:
  1380. #
  1381. #alias_creation_rules:
  1382. #  - user_id: "*"
  1383. #    alias: "*"
  1384. #    room_id: "*"
  1385. #    action: allow
  1386.  
  1387. # The `room_list_publication_rules` option controls who can publish and
  1388. # which rooms can be published in the public room list.
  1389. #
  1390. # The format of this option is the same as that for
  1391. # `alias_creation_rules`.
  1392. #
  1393. # If the room has one or more aliases associated with it, only one of
  1394. # the aliases needs to match the alias rule. If there are no aliases
  1395. # then only rules with `alias: *` match.
  1396. #
  1397. # If no rules match the request is denied. An empty list means no one
  1398. # can publish rooms.
  1399. #
  1400. # Options for the rules include:
  1401. #
  1402. #   user_id: Matches agaisnt the creator of the alias
  1403. #   room_id: Matches against the room ID being published
  1404. #   alias: Matches against any current local or canonical aliases
  1405. #            associated with the room
  1406. #   action: Whether to "allow" or "deny" the request if the rule matches
  1407. #
  1408. # The default is:
  1409. #
  1410. #room_list_publication_rules:
  1411. #  - user_id: "*"
  1412. #    alias: "*"
  1413. #    room_id: "*"
  1414. #    action: allow
  1415.  
  1416.  
  1417. # Server admins can define a Python module that implements extra rules for
  1418. # allowing or denying incoming events. In order to work, this module needs to
  1419. # override the methods defined in synapse/events/third_party_rules.py.
  1420. #
  1421. # This feature is designed to be used in closed federations only, where each
  1422. # participating server enforces the same rules.
  1423. #
  1424. #third_party_event_rules:
  1425. #  module: "my_custom_project.SuperRulesSet"
  1426. #  config:
  1427. #    example_option: 'things'
  1428.  
  1429.  
  1430. ## Opentracing ##
  1431.  
  1432. # These settings enable opentracing, which implements distributed tracing.
  1433. # This allows you to observe the causal chains of events across servers
  1434. # including requests, key lookups etc., across any server running
  1435. # synapse or any other other services which supports opentracing
  1436. # (specifically those implemented with Jaeger).
  1437. #
  1438. opentracing:
  1439.    # tracing is disabled by default. Uncomment the following line to enable it.
  1440.     #
  1441.     #enabled: true
  1442.  
  1443.     # The list of homeservers we wish to send and receive span contexts and span baggage.
  1444.     # See docs/opentracing.rst
  1445.     # This is a list of regexes which are matched against the server_name of the
  1446.     # homeserver.
  1447.     #
  1448.     # By defult, it is empty, so no servers are matched.
  1449.     #
  1450.     #homeserver_whitelist:
  1451.     #  - ".*"
  1452.  
  1453.     # Jaeger can be configured to sample traces at different rates.
  1454.     # All configuration options provided by Jaeger can be set here.
  1455.     # Jaeger's configuration mostly related to trace sampling which
  1456.     # is documented here:
  1457.     # https://www.jaegertracing.io/docs/1.13/sampling/.
  1458.     #
  1459.     #jaeger_config:
  1460.     #  sampler:
  1461.     #    type: const
  1462.     #    param: 1
  1463.  
  1464.     #  Logging whether spans were started and reported
  1465.     #
  1466.     #  logging:
  1467.     #    false
Add Comment
Please, Sign In to add comment