1
0
mirror of https://github.com/samba-team/samba.git synced 2025-07-27 07:42:04 +03:00
Commit Graph

20 Commits

Author SHA1 Message Date
ca24ae50ea Clarify comment on set_effective_uid()
Andrew Bartlett
-
556c62f935 After a phonecall with jra finally commit this.
This changes our behaviour when the setresuid call is available. We now not
only change the effective uid but also the real uid when becoming
unprivileged. This is mainly for improved AFS compatibility, as AFS selects
the token to send to the server based on the real uid of the process.

I tested this with a W2k server with two non-root 'runas' sessions. They come
in via a single smbd as two different users using two session setups. Samba on
Linux can still switch between the two uids, proved by two different files
created via those sessions.

Volker
-
1fed55aa78 Add a descriptive comment to our usage of setresuid. lib/afs.c needs
to be changed if we decide to set our real uid. Jeremy?

Volker
-
03ac082dcb updated the 3.0 branch from the head branch - ready for alpha18 -
a5ac2ac4ad Spelling fixes. -
569505b771 reverted tims patch that broke configure
why does anything but smbd care about sec_init() anyway??
-
e7abb79fb3 Whoops, typo. -
1b941e2c63 Do a smb_panic() if sec_initial_[ug]id() or non_root_mode() is called
without before sec_init().  This should avoid the formation of another
magic function club.  (-:
-
6a58c9bd06 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
-
0c8e9339d8 Parionia to ensure people don't install libsmb based programs setuid root.
libsmb has not been written to be setuid, with things like LIBSMB_PROG allowing
all sort of fun and games.

Andrew Bartlett
-
2d0922b0ea Removed 'extern int DEBUGLEVEL' as it is now in the smb.h header. -
bc1385fc5e Restore the profiling data shmem parinoia. This whole area needs to be
fixed - an mmaped file or the like would be a good idea.
-
9449544428 added sec_initial_uid() function so we can ask if a file is owned by
the initial uid
-
9a9da44455 fixed inetd operation as non-root -
72f63f5144 make sure we have BOOL in autoconf usage of util_sec.c -
55109a7525 - make the regresison test mode code build in by default. This should
allow us to have test targets without special configure options
- fixed make proto so that it actually does something
-
7e8e6ae9a8 added the ability to test smbd safely as an ordinary user. The way it works is
that libsmb/ creates a local tcp socket then launches smbd as a subprocess
attached to that socket. smbd thinks it is being launched from inetd.

to use it do the following:

- compile with -DSMB_REGRESSION_TEST
- run like this (also works with smbtorture etc)
    export SMBD_TEST=1
    export LIBSMB_PROG=bin/smbd
    smbclient //server/share -Uuser%pass

obviously you need to setup a smb.conf etc. Using --prefix to configure
is useful.

The aim of all this stuff is to add a decent set of regression tests
to the build farm, so we know if smbd actually runs correctly on all the
platforms, not just builds. We can run smbtorture, masktest, locktest etc,
plus a bunch of smbclient scripts and any new tests we write.

This doesn't help much with nmbd (at least not yet) but its a good start.
-
6553f1d027 Fixed compiler warning. -
ebcdb4afee Moved over lib/util_sec (with added fixes) as the HEAD source
seems to have drifted a little.
Jeremy.
-
955d187139 util_sec.c from 2.0.6 -