{"action":"opened","issue":{"url":"https://api.github.com/repos/mellium/issuetest/issues/6","repository_url":"https://api.github.com/repos/mellium/issuetest","labels_url":"https://api.github.com/repos/mellium/issuetest/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/mellium/issuetest/issues/6/comments","events_url":"https://api.github.com/repos/mellium/issuetest/issues/6/events","html_url":"https://github.com/mellium/issuetest/issues/6","id":301279728,"number":6,"title":"If no TLSConfig exists for STARTTLS, use a default one","user":{"login":"SamWhited","id":512573,"avatar_url":"https://avatars2.githubusercontent.com/u/512573?v=4","gravatar_id":"","url":"https://api.github.com/users/SamWhited","html_url":"https://github.com/SamWhited","followers_url":"https://api.github.com/users/SamWhited/followers","following_url":"https://api.github.com/users/SamWhited/following{/other_user}","gists_url":"https://api.github.com/users/SamWhited/gists{/gist_id}","starred_url":"https://api.github.com/users/SamWhited/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SamWhited/subscriptions","organizations_url":"https://api.github.com/users/SamWhited/orgs","repos_url":"https://api.github.com/users/SamWhited/repos","events_url":"https://api.github.com/users/SamWhited/events{/privacy}","received_events_url":"https://api.github.com/users/SamWhited/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-01T05:11:54Z","updated_at":"2018-03-01T05:11:54Z","closed_at":null,"author_association":"COLLABORATOR","body":"In the StartTLS negotiate function we grab the `conn.Config.TLSConfig` and use that when creating our tls server or client. If it is set to nil or the zero value of `tls.Config` the connection fails.\r\n\r\nInstead, if it's we should create a new `tls.Config` and specify a server name of the domain part of the origin address. For instance, in `starttls.go` around line 57 we might create a config like:\r\n\r\n```go\r\n&tls.Config{ServerName: conn.LocalAddr().(*jid.JID).Domain().String()}\r\n```\r\n\r\nand use that in the calls to `tls.Server` and `tls.Client` that happen later."}}
{"actor":{"display_login":"SamWhited"}}