summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-09-29 12:47:00 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:14:55 -0500
commit81014d255e488da3807abe75f067042f976fc50d (patch)
tree14ec3e459622c2fc54709ea242cbd064334fe397 /source3/smbd
parentce11194ce0fc668008fab1084990bdcca1c120b4 (diff)
downloadsamba-81014d255e488da3807abe75f067042f976fc50d.tar.gz
samba-81014d255e488da3807abe75f067042f976fc50d.tar.bz2
samba-81014d255e488da3807abe75f067042f976fc50d.zip
r19000: Merge the max tcon check from 3_0_23. Thanks to James Peach that this was not
done in the 3_0 tree. Volker (This used to be commit b2fbf5ac0ca38577957e8e7ddb176dd3499de213)
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/service.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source3/smbd/service.c b/source3/smbd/service.c
index 9c341f19fd..29f26c0302 100644
--- a/source3/smbd/service.c
+++ b/source3/smbd/service.c
@@ -1043,6 +1043,11 @@ connection_struct *make_connection(const char *service_in, DATA_BLOB password,
smb_panic("make_connection: PANIC ERROR. Called as nonroot\n");
}
+ if (conn_num_open() > 2047) {
+ *status = NT_STATUS_INSUFF_SERVER_RESOURCES;
+ return NULL;
+ }
+
if(lp_security() != SEC_SHARE) {
vuser = get_valid_user_struct(vuid);
if (!vuser) {