s3:rpc_server: pass everything but AUTH_TYPE_{NONE,NCALRPC_AS_SYSTEM} to gensec
authorStefan Metzmacher <metze@samba.org>
Wed, 23 Apr 2014 11:07:15 +0000 (13:07 +0200)
committerStefan Metzmacher <metze@samba.org>
Thu, 24 Apr 2014 09:21:05 +0000 (11:21 +0200)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
source3/rpc_server/srv_pipe.c

index ebff114b28d5f677ab15a80a7e5530ec23a4d9d8..d85751d84680ee299665dbf8386af08eff212c57 100644 (file)
@@ -731,32 +731,7 @@ static bool api_pipe_bind_req(struct pipes_struct *p,
                }
 
                switch (auth_type) {
-               case DCERPC_AUTH_TYPE_NTLMSSP:
-                       if (!pipe_auth_generic_bind(p, pkt,
-                                                   &auth_info, &auth_resp)) {
-                               goto err_exit;
-                       }
-                       assoc_gid = 0x7a77;
-                       break;
-
-               case DCERPC_AUTH_TYPE_SCHANNEL:
-                       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:
-               case DCERPC_AUTH_TYPE_KRB5:
-                       if (!pipe_auth_generic_bind(p, pkt,
-                                                   &auth_info, &auth_resp)) {
-                               goto err_exit;
-                       }
+               case DCERPC_AUTH_TYPE_NONE:
                        break;
 
                case DCERPC_AUTH_TYPE_NCALRPC_AS_SYSTEM:
@@ -780,12 +755,12 @@ static bool api_pipe_bind_req(struct pipes_struct *p,
                        }
                        break;
 
-               case DCERPC_AUTH_TYPE_NONE:
-                       break;
-
                default:
-                       DEBUG(0, ("Unknown auth type %x requested.\n", auth_type));
-                       goto err_exit;
+                       if (!pipe_auth_generic_bind(p, pkt,
+                                                   &auth_info, &auth_resp)) {
+                               goto err_exit;
+                       }
+                       break;
                }
        }