[Feature] add new config to enforce public link password (#7547)

* add new config to enforce public link password

* add api test
This commit is contained in:
Michael Barz
2023-10-20 17:55:36 +02:00
committed by GitHub
parent 3585445530
commit 3c7bae4071
5 changed files with 52 additions and 2 deletions
@@ -51,5 +51,10 @@ func Validate(cfg *config.Config) error {
cfg.GRPCClientTLS = structs.CopyOrZeroValue(cfg.Commons.GRPCClientTLS)
}
// Set password enforcement on all public links when config is set
if cfg.OCS.PublicShareMustHavePassword {
cfg.OCS.WriteablePublicShareMustHavePassword = true
}
return nil
}