Explorar el Código

Update httpServer.go

GOKRB5 Service: 2018/09/11 11:27:23 http.go:57: 192.168.139.137:43856 user@REALM - SPNEGO authentication succeeded
2018/09/11 11:27:23 http: panic serving 1.2.3.4:2345: interface conversion: interface {} is *credentials.Credentials, not credentials.Credentials
Hakan Carlsson hace 7 años
padre
commit
2f19bd089c
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      examples/httpServer.go

+ 1 - 1
examples/httpServer.go

@@ -45,7 +45,7 @@ func main() {
 func testAppHandler(w http.ResponseWriter, r *http.Request) {
 	w.WriteHeader(http.StatusOK)
 	ctx := r.Context()
-	creds := ctx.Value(service.CTXKeyCredentials).(credentials.Credentials)
+	creds := ctx.Value(service.CTXKeyCredentials).(*credentials.Credentials)
 	fmt.Fprintf(w,
 		`<html>
 <h1>GOKRB5 Handler</h1>