Skip to content

Commit b2af2e5

Browse files
committed
Merge branch '517-remove-host-validation-from-local-certificate' into 'master'
Resolve "Remove host validation from local certificate" Closes #517 See merge request apps/gateway/gateway!486
2 parents ce6c5ba + 8ccb349 commit b2af2e5

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

doc/source/changelog.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
Historique des versions
44
=======================
55

6+
* :bug:`517` Suppression de la validation d'hôte pour les certificats locaux.
7+
Celle-ci pouvait empêcher l'ajout d'un certificat si le serveur local écoute
8+
sur une adresse locale différente de celle renseignée dans le certificat.
69
* :bug:`509` Correction de bug mineurs dans l'interface Web :
710

811
- Le port n'est plus requis pour les clients

pkg/model/local_agent.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ func (*LocalAgent) Appellation() string { return "server" }
3939
func (l *LocalAgent) GetID() int64 { return l.ID }
4040
func (l *LocalAgent) GetNullID() sql.NullInt64 { return utils.NewNullInt64(l.ID) }
4141
func (*LocalAgent) IsServer() bool { return true }
42-
func (l *LocalAgent) Host() string { return l.Address.Host }
42+
func (l *LocalAgent) Host() string { return "" }
4343

4444
func (l *LocalAgent) validateProtoConfig() error {
4545
if err := ConfigChecker.CheckServerConfig(l.Protocol, l.ProtoConfig); err != nil {

pkg/protocols/modules/http/listener.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func (h *httpService) makeTLSConf(*tls.ClientHelloInfo) (*tls.Config, error) {
5555
}
5656

5757
func (h *httpService) listen() error {
58-
addr := conf.GetRealAddress(h.agent.Host(),
58+
addr := conf.GetRealAddress(h.agent.Address.Host,
5959
utils.FormatUint(h.agent.Address.Port))
6060

6161
var (

0 commit comments

Comments
 (0)