rpc_server: Use the RPC TCPIP ports of Windows
authorAndreas Schneider <asn@samba.org>
Mon, 16 Jan 2017 10:43:12 +0000 (11:43 +0100)
committerStefan Metzmacher <metze@samba.org>
Fri, 27 Jan 2017 07:09:15 +0000 (08:09 +0100)
Since Windows Server 2008 Microsoft uses a different port range for RPC
services. Before it was 1024-65535 and they changed it to 49152-65535.

We should use the same range as these are the ports the firewall in AD
networks normally allow.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12521

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/rpc_server/rpc_server.c
source4/smbd/service_stream.c

index 5effe66d9bba23fd0669c5f396c6e6950ac644c3..37fe68fc36d352b7d283d5c13068c1ccf1954f75 100644 (file)
@@ -34,8 +34,8 @@
 #include "rpc_server/srv_pipe_hnd.h"
 #include "rpc_server/srv_pipe.h"
 
-#define SERVER_TCP_LOW_PORT  1024
-#define SERVER_TCP_HIGH_PORT 1300
+#define SERVER_TCP_LOW_PORT  49152
+#define SERVER_TCP_HIGH_PORT 65535
 
 /* Creates a pipes_struct and initializes it with the information
  * sent from the client */
index 22c885bbe2b9405a25da671485749cc35f51da3e..8abaaca272c22bf040ac95b3c36b97069cbdaaf1 100644 (file)
@@ -31,8 +31,8 @@
 #include "lib/util/util_net.h"
 
 /* the range of ports to try for dcerpc over tcp endpoints */
-#define SERVER_TCP_LOW_PORT  1024
-#define SERVER_TCP_HIGH_PORT 1300
+#define SERVER_TCP_LOW_PORT  49152
+#define SERVER_TCP_HIGH_PORT 65535
 
 /* size of listen() backlog in smbd */
 #define SERVER_LISTEN_BACKLOG 10