Bug 7125 - net sam createbuiltingroup core dumped when used without root
Summary: net sam createbuiltingroup core dumped when used without root
Status: NEW
Alias: None
Product: Samba 3.5
Classification: Unclassified
Component: Client Tools (show other bugs)
Version: unspecified
Hardware: Other Linux
: P3 normal
Target Milestone: ---
Assignee: Volker Lendecke
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-10 03:32 UTC by Matthieu Patou
Modified: 2010-03-04 06:54 UTC (History)
0 users

See Also:


Attachments
Proposed patch against master (13.70 KB, patch)
2010-03-04 06:46 UTC, Karolin Seeger
vl: review-
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Matthieu Patou 2010-02-10 03:32:46 UTC
net sam createbuiltingroup administrators
You are not root, most things won't work
[2010/02/10 12:30:56.478502,  0] passdb/secrets.c:73(secrets_init)
  Failed to open /var/lib/samba/secrets.tdb
[2010/02/10 12:30:56.478675,  0] lib/util.c:1447(smb_panic)
  PANIC (pid 12713): could not open secrets db
[2010/02/10 12:30:56.502651,  0] lib/util.c:1551(log_stack_trace)
  BACKTRACE: 14 stack frames:
   #0 net(log_stack_trace+0x2d) [0x8273b8d]
   #1 net(smb_panic+0x2d) [0x8273c8d]
   #2 net(get_global_sam_sid+0x4eb) [0x817a79b]
   #3 net(sid_check_is_domain+0x17) [0x817a9d7]
   #4 net(lookup_sids+0x115) [0x821c0c5]
   #5 net(lookup_sid+0x80) [0x821cfd0]
   #6 net(pdb_create_builtin_alias+0xfa) [0x823f8ca]
   #7 net [0x8110b37]
   #8 net(net_run_function+0x71) [0x8111ba1]
   #9 net(net_sam+0xa1) [0x810b411]
   #10 net(net_run_function+0x71) [0x8111ba1]
   #11 net(main+0x8ab) [0x80d89fb]
   #12 /lib/i686/nosegneg/libc.so.6(__libc_start_main+0xe5) [0xb7c66455]
   #13 net [0x80d80b1]
[2010/02/10 12:30:56.503454,  0] lib/util.c:1452(smb_panic)
  smb_panic(): calling panic action [/usr/share/samba/panic-action 12713]
[2010/02/10 12:30:56.598011,  0] lib/util.c:1460(smb_panic)
  smb_panic(): action returned status 0
[2010/02/10 12:30:56.598052,  0] lib/fault.c:312(dump_core)
  Can not dump core: corepath not set up
Comment 1 Karolin Seeger 2010-03-03 08:39:52 UTC
3.4.5 is also affected by this one.
Comment 2 Karolin Seeger 2010-03-04 06:46:33 UTC
Created attachment 5457 [details]
Proposed patch against master
Comment 3 Volker Lendecke 2010-03-04 06:54:20 UTC
Comment on attachment 5457 [details]
Proposed patch against master

Please don't re-introduce the getuid() checks. This makes it impossible to test the stuff as non-root.

What might be needed is a separate version of global_sam_sid() that does not panic if it does not work. This might then provide the basis for something like can_access_user_database() or so.

Volker