#ifdef'd out suggestion for tim on making the winbindd protocol more
authorMartin Pool <mbp@samba.org>
Wed, 14 Nov 2001 05:33:55 +0000 (05:33 +0000)
committerMartin Pool <mbp@samba.org>
Wed, 14 Nov 2001 05:33:55 +0000 (05:33 +0000)
 robust.
(This used to be commit 8952f8763e16339e58bc65943387a00fc89dc200)

source3/nsswitch/winbindd.c

index 6013a53eb6d49eff1b6de0ab2fb02f40ac50f8ef..5231c840ba56b76a8bf4fe893a888bfaced28f76 100644 (file)
@@ -4,7 +4,7 @@
 
    Winbind daemon for ntdom nss module
 
-   Copyright (C) Tim Potter 2000
+   Copyright (C) by Tim Potter 2000, 2001
    
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -610,6 +610,18 @@ static void process_loop(int accept_sock)
                                        /* Read data */
                     
                                        client_read(state);
+
+#if 0
+                                       /* If we have the start of a
+                                        * packet, then check the
+                                        * length field to make sure
+                                        * the client's not talking
+                                        * Mock Swedish. */
+                                       if (state->read_buf_len >= sizeof(int)
+                                           && *(int *) state->buf != sizeof(state->request)) {
+                                               BORK_BORK_BORK();
+                                       }
+#endif
                     
                                        /* A request packet might be 
                                           complete */