LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Blogs > zhjim
User Name
Password

Notices

Rate this Entry

Samba 3.5.6 Debian Wheezy guest account mapping for unknown user

Posted 07-08-2013 at 07:52 AM by zhjim

Nother problem that cost me some life time and hair too I'd say. Fiddeling around with samba on Debian wheezy I created a share that should be public accesible. So we call it public. Yes I am an artist and genius when making up names. Anyways as we want the guest account to be allowed we put guest ok = yes inside the config part of the share. Also to be a bit more restrictive I also added valid users = +smbusers (Nother prove of my genuine artistry). The usaual path and other things found there way into the config as well. Leaving me with
Code:
[public]
        path = /my/way/public
        valid users = +smbusers
        read only = No
        create mask = 0755
        guest ok = Yes
        hide unreadable = Yes
Okay lets mount this
Code:
root@www:~# mount -t cifs //10.10.10.210/public /mnt -o user='asdf'
Password:
mount error(13): Permission denied
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
Error but why. Okay the logs show
Code:
[2013/07/08 14:41:38.537855, 10] auth/auth.c:256(check_ntlm_password)
  check_ntlm_password: guest had nothing to say
[2013/07/08 14:41:38.538136,  3] auth/auth_sam.c:399(check_sam_security)
  check_sam_security: Couldn't find user 'asdf' in passdb.
[2013/07/08 14:41:38.538308,  5] auth/auth.c:268(check_ntlm_password)
  check_ntlm_password: sam authentication for user [asdf] FAILED with error NT_STATUS_NO_SUCH_USER
[2013/07/08 14:41:38.538487,  2] auth/auth.c:314(check_ntlm_password)
  check_ntlm_password:  Authentication for user [asdf] -> [asdf] FAILED with error NT_STATUS_NO_SUCH_USER
[2013/07/08 14:41:38.538656,  5] auth/auth_util.c:2119(free_user_info)
  attempting to free (and zero) a user_info structure
[2013/07/08 14:41:38.538883, 10] auth/auth_util.c:2123(free_user_info)
  structure was created for asdf
[2013/07/08 14:41:38.541608,  0] smbd/service.c:942(make_connection_snum)
  Can't become connected user!
Just become the damn guest user ***.

It took me like 2 hours searching the web and manpage and stuff. map to guest account was set to Bad User so it should become the guest account = nobody user. But nope won't do. To cut short on the story and curses:

If you ever need the guest account for unknown users for a share and have the valid users option as well. Do your self a favour and put the name of the guest account into the valid users.
Code:
[public]
        path = /DATEN_CRYPT/SAMBA/public
        valid users = +smbusers, nobody
        force group = smbusers
        read only = No
        create mask = 0755
        guest ok = Yes
        hide unreadable = Yes
The way I found out was to use a really minimal smb.conf and see if it works. It did. Then I just compared the two configurations and the valid users just pierced me. Should do this right away but yeah you know.
Posted in Uncategorized
Views 683 Comments 0
« Prev     Main     Next »
Total Comments 0

Comments

 

  



All times are GMT -5. The time now is 11:21 AM.

Main Menu
Advertisement

My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration