diff --git a/utils/configobserver.go b/utils/configobserver.go index 54f5a873..e3f4cca6 100644 --- a/utils/configobserver.go +++ b/utils/configobserver.go @@ -1,3 +1,17 @@ +// Copyright 2024 LiveKit, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + package utils import ( diff --git a/utils/configobserver_test.go b/utils/configobserver_test.go index 932411c0..4c2d04af 100644 --- a/utils/configobserver_test.go +++ b/utils/configobserver_test.go @@ -1,3 +1,17 @@ +// Copyright 2024 LiveKit, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + package utils import ( diff --git a/xtls/tls.go b/xtls/tls.go index 654d922d..414b690a 100644 --- a/xtls/tls.go +++ b/xtls/tls.go @@ -12,21 +12,21 @@ type Config struct { Enabled bool `json:"enabled" yaml:"enabled"` // Skip server certificate and domain verification. - Insecure bool `json:"insecure" yaml:"insecure"` + Insecure bool `json:"insecure" yaml:"insecure" config:"allowempty"` // Server name indication for TLS. - ServerName string `json:"serverName" yaml:"server_name"` + ServerName string `json:"serverName" yaml:"server_name" config:"allowempty"` // File containing trusted root certificates for verifying the server. - CACertFile string `json:"caCertFile" yaml:"ca_cert_file"` + CACertFile string `json:"caCertFile" yaml:"ca_cert_file" config:"allowempty"` // File containing client certificate (public key), to present to the // server. Must also provide @ClientKey option. - ClientCertFile string `json:"clientCertFile" yaml:"client_cert_file"` + ClientCertFile string `json:"clientCertFile" yaml:"client_cert_file" config:"allowempty"` // File containing client private key, to present to the server. // Must also provide @ClientCert option. - ClientKeyFile string `json:"clientKeyFile" yaml:"client_key_file"` + ClientKeyFile string `json:"clientKeyFile" yaml:"client_key_file" config:"allowempty"` } var ErrFailedToLoadCACert = errors.New("failed to load CACertificate")