s3-rpc_srv: use gensec for schannel bind.
authorGünther Deschner <gd@samba.org>
Wed, 18 Sep 2013 16:34:58 +0000 (18:34 +0200)
committerGünther Deschner <gd@samba.org>
Thu, 19 Sep 2013 09:09:40 +0000 (11:09 +0200)
Guenther

Signed-off-by: Günther Deschner <gd@samba.org>
Pair-Programmed-With: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/rpc_server/srv_pipe.c

index 49a27b9b0bc0df8e75166983ade0ae4ca4b76e26..96b3cc5c878f5bb310fe59ecd404aa0ef1db78f0 100644 (file)
@@ -808,10 +808,15 @@ static bool api_pipe_bind_req(struct pipes_struct *p,
                        break;
 
                case DCERPC_AUTH_TYPE_SCHANNEL:
-                       if (!pipe_schannel_auth_bind(p, pkt,
-                                               &auth_info, &auth_resp)) {
+                       if (!pipe_auth_generic_bind(p, pkt,
+                                                   &auth_info, &auth_resp)) {
+                               goto err_exit;
+                       }
+                       if (!session_info_set_session_key(p->session_info, generic_session_key())) {
+                               DEBUG(0, ("session_info_set_session_key failed\n"));
                                goto err_exit;
                        }
+                       p->pipe_bound = true;
                        break;
 
                case DCERPC_AUTH_TYPE_SPNEGO: