1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-15 23:24:37 +03:00

125 Commits

Author SHA1 Message Date
Jeremy Allison
44ed8abb2a Fix for yp_get_default_domain from Neil Hoggarth <neil.hoggarth@physiol.ox.ac.uk>
Jeremy.
-
Tim Potter
2003c11c3e Re-ran autoconf -
Jeremy Allison
711f15ac23 Fixes for IRIX kernel oplocks and systems that don't have nss.h
Jeremy.
-
Andrew Tridgell
fabe1f350e added support for kernel level share modes. These are a (small) hack,
I suspect we will either get rid of them or do them properly at some
stage.
-
Andrew Tridgell
92d0382c9e fixed autoconf test for kernel change notify support -
Andrew Tridgell
44766c39e0 totally rewrote the async signal, notification and oplock notification
handling in Samba. This was needed due to several limitations and
races in the previous code - as a side effect the new code is much
cleaner :)

in summary:

- changed sys_select() to avoid a signal/select race condition. It is a
  rare race but once we have signals doing notification and oplocks it
  is important.

- changed our main processing loop to take advantage of the new
  sys_select semantics

- split the notify code into implementaion dependent and general
  parts. Added the following structure that defines an implementation:

struct cnotify_fns {
	void * (*register_notify)(connection_struct *conn, char *path, uint32 flags);
	BOOL (*check_notify)(connection_struct *conn, uint16 vuid, char *path, uint32 flags, void *data, time_t t);
	void (*remove_notify)(void *data);
};


then I wrote two implementations, one using hash/poll (like our old
code) and the other using the new Linux kernel change notify. It
should be easy to add other change notify implementations by creating
a sructure of the above type.

- fixed a bug in change notify where we were returning the wrong error
  code.

- rewrote the core change notify code to be much simpler

- moved to real-time signals for leases and change notify

Amazingly, it all seems to work. I was very surprised!
-
Andrew Tridgell
fbeb980434 continued the split of the kernel level oplocks code into a more
modular form. In this pass I added oplock_irix.c and added a "struct
kernel_oplocks" that describes a kernel oplock implementation.

I also removed the maintainence mode from the Makefile. It was causing
too much trouble. If someone really likes it they can keep a patch
around to enable it themselves.
-
Andrew Tridgell
0368f68529 - changed HAVE_KERNEL_OPLOCKS to HAVE_KERNEL_OPLOCKS_IRIX
- added autoconf test for HAVE_KERNEL_OPLOCKS_LINUX
-
Shirish Kalele
e0965a80bd Changed MS_DFS to WITH_MSDFS throughout.
Fixed trans2 calls on IPC$ to let dfs referral calls through.
-
Andrew Tridgell
e23f43e7d3 we don't need fnmatch.c any more -
Andrew Tridgell
f137648504 got rid of some more old configure tests and includes -
Andrew Tridgell
e8905a557a removed some obsolete configure tests (sysv ipc etc) -
Andrew Tridgell
0b68660159 The following series of commits are for the new tdb based printing
backend. This completely replaces our old printing backend.

Major changes include:

- all print ops are now done in printing/*.c rather than scattered all
  over the place
- system job ids are decoupled from SMB job ids
- the lpq parsers don't need to be nearly so smart, they only need to
  parse the filename, the status and system job id
- we can store lots more info about a job, including the full job name
- the queue cache control is much better

I also added a new utility routine file_lines_load() that loads a text
file and parses it into lines. This is used in out lpq parsing and I
also want to use it to replace all of our fgets() based code in other
places.
-
Andrew Tridgell
0ec1072e01 split out the lpq parsing code into a separate file
printing/lpq_parse.c

getting ready for the new printing backend
-
Herb Lewis
351b25727e fixes for broken IRIX header file merged from 2.0 branch -
Jeremy Allison
3a39acd353 IRIX include fixes.
Jeremy.
-
Jeremy Allison
567713a07c Added check for LL suffix to long long ints needed by AIX 4.3.x compiler
to allow successful build.
Jeremy.
-
Jeremy Allison
f02999dbf7 acconfig.h configure configure.in: Added check for UT_SYSLEN for utmp code.
include/byteorder.h: Added alignment macros.
include/nameserv.h: Added defines for msg_type field options - from rfc1002.
lib/time.c: Typo fix.
lib/util_unistr.c: Updates from UNICODE branch.
printing/nt_printing.c: bzero -> memset.
smbd/connection.c: Added check for UT_SYSLEN for utmp code.

Other fixes : Rollback of unapproved commit from Luke.
Please *ask* next time before doing large changes to HEAD.

Jeremy.
-
Tim Potter
b183c24220 Adding libtool support to HEAD branch. We're going to need this for
various things yet to be merged from TNG.  The smbwrapper stuff should
probably be ported across too.
-
Shirish Kalele
4684b4a188 dded Microsoft Dfs services.
* added a new msdfs/ directory under source/
* added msdfs sources under this directory.
* modified configure setup to add a --with-msdfs configure time option

 Modified Files:
 	Makefile.in acconfig.h configure configure.in
 	include/config.h.in include/includes.h include/proto.h
 	include/smb.h include/smb_macros.h param/loadparm.c
 	smbd/negprot.c smbd/nttrans.c smbd/process.c smbd/reply.c
 	smbd/server.c smbd/trans2.c
 Added Files:
 	include/msdfs.h msdfs/README msdfs/msdfs.c msdfs/msdfs_tdb.c
 	msdfs/parse_dfs_map.c
 ----------------------------------------------------------------------
-
Jeremy Allison
b52e92b09d Added replacement functions sys_popen and sys_pclose. These are based
on the glibc source code and are safer than the traditional popen as
they don't use a shell to exec the requested command. Now we have
these functions they can be tightened up (environment etc.) as required
to make a safe popen. It should now be safe to add the environement
variable loading code to loadparm.c
Jeremy.
-
Jeremy Allison
773d6e504b Added check for SGI IRIX brokenness with semaphores when using gcc.
Code from Don Badrak <dbadrak@census.gov>
Jeremy.
-
Tim Potter
8b26be1e82 Backed out -rdynamic linker option. It seems to be GNU ld specific.
Need a platform independant way of exporting symbols for dlopen().
Perhaps this is only needed for certain platforms anyway...
-
Tim Potter
4c14a343d1 Add -rdynamic to LDFLAGS if libdl found. -
Jeremy Allison
94c075faee Wrapped popen calls in HAVE_POPEN - needed if we are to add the
env patch.
Jeremy.
-
Jeremy Allison
95d37a1d25 Added utmp fix from David Lee <T.D.Lee@durham.ac.uk>.
Jeremy.
-
Jeremy Allison
210d61db08 Moved check_plaintext_password() into smbd/chgpasswd.c from smbd/ipc.c.
configure configure.in include/config.h.in: Added <sys/un.h> autoconf
code for Luke's UNIX domain sockets code.
Jeremy.
-
Jeremy Allison
1ba42aca21 Converted most of the functions in lib/util_str.c to smb_ucs2_t equivalents.
Jeremy.
-
Andrew Tridgell
453a822a76 first pass at updating head branch to be to be the same as the SAMBA_2_0 branch -
Luke Leighton
b2ea37a8f1 moved sys/un.h to after sys/socket.h. done a gnu autoconf around sys/un.h -
Tim Potter
26d66071fb Put back in GNU readline support for smbclient accidentally trashed by
tridge in the clientgen.c to clientutil.c conversion.
-
Andrew Tridgell
ef3d61a80a Ken McDonell from SGI was interested in adding some profiling
capabilities to Samba so that Samba could talk to the SGI PCP
(Performance Co-Pilot) apps.

This change adds a profiling shared memory area and uses it to count
two fairly trivial things, the number of uid switches and the number
of SMB packets processes. To add more just edit include/profile.h and
then increment it at the right place.

I've also added a -P switch to smbstatus to dump the profile area.
-
Luke Leighton
511ef8a58c added <mysql.h> autoconf test. -
Richard Sharpe
3598d90a32 More changes to get SSL working with 2.x.x
Now, we have most of the configure support done, next
have to fix Makefile.in and other things ...
-
Richard Sharpe
524c4d2978 Fixing up configure to properly support ssl -
Andrew Tridgell
ccf6443887 and in head branch:
make sure we include sys/mman.h if available
-
Luke Leighton
d11859041d updated for Matt Chapman's ldap code -
Jeremy Allison
6acb4b68f6 Makefile.in: Added maintainer mode fixes.
aclocal.m4: Added AC_LIBTESTFUNC.
configure.in: Fixed -lsecurity -lsec problems.
client.c: dos_ fixes.
groupdb/aliasunix.c: Dead code removal.
include/includes.h: Added default PRINTCAP_NAME.
lib/genrand.c: dos_ fixes.
lib/replace.c: Added strtoul.
lib/system.c: dos_ fixes.
lib/util.c: dos_ fixes.
lib/util_sid.c: Signed/unsigned fixes.
lib/util_str.c: removed bad const.
locking/locking_slow.c: dos_ fixes.
printing/printing.c: dos_ fixes.
rpc_server/srv_samr.c: Dead code removal.
rpc_server/srv_sid.c: global_myworkgroup defined with wrong size AGAIN !
smbd/dir.c: dos_ fixes.
smbd/open.c: dos_ fixes.
smbd/oplock.c: dos_ fixes.
smbd/reply.c smbd/server.c smbd/service.c smbd/uid.c: dos_ fixes.

Jeremy.
-
Luke Leighton
c89642ff3f yp_prot.h and ypclnt.h correct: ypprot.h and yp_clnt.h wrong... -
Luke Leighton
d502388234 re-added ypprot.h and yp_clnt.h -
Luke Leighton
e76f593b35 unix instance of group database API -
Jeremy Allison
34d8f4b1c4 acconfig.h configure configure.in include/config.h.in: Added -lsec and -lsecurity checks
in a more sane way.
rpc_client/cli_netlogon.c: Removed correct bits check to see if this works with an NT3.51 PDC.
rpc_parse/parse_samr.c: Fixed compile warnings.
Jeremy.
-
Jeremy Allison
b02d21a73d Fixed stupid blunder where I renamed getpwanam to getpwnam.
Jeremy.
-
Jeremy Allison
2d62dc26f4 Makefile.in: Added passing of CPPFLAGS into Makefile.
configure
configure.in
include/config.h.in: Fixes for AIX4.x. AIX *will not*
                     enable large file support of *any* description unless
                     either -D_LARGE_FILES or -D_LARGE_FILES_API are defined.
                     I chose "-D_LARGE_FILES" as this leads to cleaner code...

Also fixed bug where getpwnam was listed as getpw(a)nam in configure.in.
Jeremy.
-
Jeremy Allison
1ef6d3bd63 Sync up with 2.0 code.
Added HPUX autoconf changes.
Added "gross hack" printer code.
Jeremy.
-
Jeremy Allison
5ad77769be Changes to make the default prefix /usr/local/samba - as it was in 1.9.18p10.
acconfig.h configure configure.in include/config.h.in: Fixes to DEC OSF1.
libsmb/nmblib.c: Fixes to nmbd jumps in scope names.
Jeremy.
-
Jeremy Allison
30af39ae1e Added OSF1 changes to HEAD (-lsecurity etc.)
groupdb/groupdb.c: Fixed compile error caught by IRIX compiler.
utils/smbpasswd.c: Fixed SunOS optind, optarg problem.
Jeremy.
-
Jeremy Allison
7a6f25ac4a Fixed problem with HAVE_NETGROUP being used on platforms
that cannot support it.
Jeremy.
-
Jeremy Allison
18ff93a9ab Added the same open()/fopen()/creat()/mmap() -> sys_XXX calls.
Tidied up some of the mess (no other word for it). Still doesn't
compile cleanly. There are calls with incorrect parameters that
don't seem to be doing the right thing.

This code still needs surgery :-(.

Jeremy.
-
Luke Leighton
0d21e1e609 - group database API. oops and oh dear, the threat has been carried out:
the pre-alpha "domain group" etc parameters have disappeared.

- interactive debug detection

- re-added mem_man (andrew's memory management, detects memory corruption)

- american spellings of "initialise" replaced with english spelling of
  "initialise".

- started on "lookup_name()" and "lookup_sid()" functions.  proper ones.

- moved lots of functions around.  created some modules of commonly used
  code.  e.g the password file locking code, which is used in groupfile.c
  and aliasfile.c and smbpass.c

- moved RID_TYPE_MASK up another bit.  this is really unfortunate, but
  there is no other "fast" way to identify users from groups from aliases.
  i do not believe that this code saves us anything (the multipliers)
  and puts us at a disadvantage (reduces the useable rid space).
  the designers of NT aren't silly: if they can get away with a user-
  interface-speed LsaLookupNames / LsaLookupSids, then so can we.  i
  spoke with isaac at the cifs conference, the only time for example that
  they do a security context check is on file create.  certainly not on
  individual file reads / writes, which would drastically hit their
  performance and ours, too.

- renamed myworkgroup to global_sam_name, amongst other things, when used
  in the rpc code.  there is also a global_member_name, as we are always
  responsible for a SAM database, the scope of which is limited by the role
  of the machine (e.g if a member of a workgroup, your SAM is for _local_
  logins only, and its name is the name of your server.  you even still
  have a SID.  see LsaQueryInfoPolicy, levels 3 and 5).

- updated functionality of groupname.c to be able to cope with names
  like DOMAIN\group and SERVER\alias.  used this code to be able to
  do aliases as well as groups.  this code may actually be better
  off being used in username mapping, too.

- created a connect to serverlist function in clientgen.c and used it
  in password.c

- initialisation in server.c depends on the role of the server.  well,
  it does now.

- rpctorture.  smbtorture.  EXERCISE EXTREME CAUTION.
-