summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-06-23 00:22:14 +0000
committerJeremy Allison <jra@samba.org>2001-06-23 00:22:14 +0000
commit7133aed083612480a94a7b61d6a0a0308c304b6e (patch)
treec79c4ba0b283ae1816f17e7e9f8d5d308943820c /source3
parentfe136fe6232c8f877e04cf302344d80f3cefb476 (diff)
downloadsamba-7133aed083612480a94a7b61d6a0a0308c304b6e.tar.gz
samba-7133aed083612480a94a7b61d6a0a0308c304b6e.tar.bz2
samba-7133aed083612480a94a7b61d6a0a0308c304b6e.zip
Better fix for client name vulnarability.
Jeremy. (This used to be commit 17c3faa367328d186d10f59f08549de0c608b16a)
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/reply.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index cd7b3fe6fe..0c40e5f2b3 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -96,6 +96,7 @@ int reply_special(char *inbuf,char *outbuf)
remote_machine[15] = 0;
trim_string(remote_machine," "," ");
strlower(remote_machine);
+ alpha_strcpy(remote_machine,remote_machine,sizeof(remote_machine)-1);
fstrcpy(local_machine,name1);
len = strlen(local_machine);
@@ -105,6 +106,7 @@ int reply_special(char *inbuf,char *outbuf)
}
trim_string(local_machine," "," ");
strlower(local_machine);
+ alpha_strcpy(local_machine,local_machine,sizeof(local_machine)-1);
if (name_type == 'R') {
/* We are being asked for a pathworks session ---