summaryrefslogtreecommitdiff
path: root/tls-getcerts.go
diff options
context:
space:
mode:
Diffstat (limited to 'tls-getcerts.go')
-rw-r--r--tls-getcerts.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/tls-getcerts.go b/tls-getcerts.go
index dfec7f8..d598d27 100644
--- a/tls-getcerts.go
+++ b/tls-getcerts.go
@@ -14,7 +14,7 @@ import (
)
type xmppStreamsFeatures struct {
- XMLName xml.Name `xml:"http://etherx.jabber.org/streams features"`
+ XMLName xml.Name `xml:"http://etherx.jabber.org/streams features"`
}
type xmppTlsProceed struct {
@@ -62,7 +62,7 @@ func xmppStartTLS(connRaw net.Conn, host string) error {
return nil
}
-func getcert(socket string) (*x509.Certificate, error){
+func getcert(socket string) (*x509.Certificate, error) {
u, err := url.Parse(socket)
if err != nil {
return nil, err
@@ -99,7 +99,7 @@ func getcert(socket string) (*x509.Certificate, error){
cstate := connTLS.ConnectionState()
opts := x509.VerifyOptions{
- DNSName: host,
+ DNSName: host,
Intermediates: x509.NewCertPool(),
}
for _, cert := range cstate.PeerCertificates[1:] {
@@ -122,9 +122,9 @@ func split(socket string) (net, addr string) {
func main() {
for _, socket := range os.Args[1:] {
block := pem.Block{
- Type: "CERTIFICATE",
+ Type: "CERTIFICATE",
Headers: map[string]string{"X-Socket": socket},
- Bytes: nil,
+ Bytes: nil,
}
cert, err := getcert(socket)
if cert != nil {