mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-29 12:42:46 +00:00
Allow enforcing X.509 certificate validity (MSC1711) (#1249)
* Configurable X.509 certificate validation * Fix dendritejs * Update go.mod/go.sum for matrix-org/gomatrixserverlib#214 * Update sample config
This commit is contained in:
parent
5dd5a41119
commit
30c2325eaf
12 changed files with 23 additions and 14 deletions
|
@ -107,6 +107,9 @@ type Dendrite struct {
|
|||
// is 2**x seconds, so 1 = 2 seconds, 2 = 4 seconds, 3 = 8 seconds, etc.
|
||||
// The default value is 16 if not specified, which is circa 18 hours.
|
||||
FederationMaxRetries uint32 `yaml:"federation_max_retries"`
|
||||
// FederationDisableTLSValidation disables the validation of X.509 TLS certs
|
||||
// on remote federation endpoints. This is not recommended in production!
|
||||
FederationDisableTLSValidation bool `yaml:"federation_disable_tls_validation"`
|
||||
} `yaml:"matrix"`
|
||||
|
||||
// The configuration specific to the media repostitory.
|
||||
|
|
|
@ -252,6 +252,7 @@ func (b *BaseDendrite) CreateAccountsDB() accounts.Database {
|
|||
func (b *BaseDendrite) CreateFederationClient() *gomatrixserverlib.FederationClient {
|
||||
return gomatrixserverlib.NewFederationClient(
|
||||
b.Cfg.Matrix.ServerName, b.Cfg.Matrix.KeyID, b.Cfg.Matrix.PrivateKey,
|
||||
b.Cfg.Matrix.FederationDisableTLSValidation,
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue