commit 288fa94ac7cfdf7457b5098c33fc840bed3d5410 Author: Michael Adam AuthorDate: Thu Dec 18 18:01:55 2008 +0100 Commit: Karolin Seeger CommitDate: Fri Dec 19 08:30:23 2008 +0100 smbd: prevent access to root filesystem when connecting with empty service name This only applies to a setup with "registry shares = yes" Michael --- source/smbd/service.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/source/smbd/service.c b/source/smbd/service.c index 491a67a..cb51f35 100644 --- a/source/smbd/service.c +++ b/source/smbd/service.c @@ -235,6 +235,10 @@ static int load_registry_service(const char *servicename) return -1; } + if ((servicename == NULL) || (*servicename == '\0')) { + return -1; + } + if (strequal(servicename, GLOBAL_NAME)) { return -2; }