1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-22 22:04:08 +03:00

9920 Commits

Author SHA1 Message Date
Jelmer Vernooij
acffe03f93 Simplify modules interface and make it easier to build
complete subsystems as modules (--with-shared-modules=rpc,pdb_xml,pdb_ldap
works now, for example)
(This used to be commit f622bdc691fabed218598fb0546b9e933aed63ed)
2003-03-24 18:25:31 +00:00
Jelmer Vernooij
75b3445d04 Add static to satisfy exotic compilers
(This used to be commit 269c93ca269e5badd5475d9ad53d06f9cb111d2c)
2003-03-24 16:16:13 +00:00
Jelmer Vernooij
a4d819e1e8 Add mapping for Bad Network Path
(This used to be commit 1481cd9ecf1658312424c193d8cd3632766eb058)
2003-03-24 16:15:10 +00:00
Jelmer Vernooij
66c321232a Don't use old usage() function, but the one from popt.
Remove some useless arguments
(This used to be commit 8df30059ef100a4d5e21501d7746427b4d312589)
2003-03-24 14:32:11 +00:00
Jelmer Vernooij
41a09c3c53 Revoke some of the popt patch from metze I applied earlier today. It added
some double options and broke some parameters.
(This used to be commit d5f9b0275c91512e1926504f22aaeec2d104430d)
2003-03-24 14:15:14 +00:00
Jelmer Vernooij
9ae249c6f1 Add modules support to charset
(This used to be commit cf3d31b9801d7ccb30334a92d4dc8a0ced2ecd31)
2003-03-24 12:47:21 +00:00
Jelmer Vernooij
66876060fe Define POPT_TABLEEND if current popt.h doesn't contain it already
(This used to be commit de4bdf42d8f27b54260f58ff37d438c67623f446)
2003-03-24 12:18:56 +00:00
Jelmer Vernooij
f9e66df9c7 Fix init function name and return value
(This used to be commit 27f3fbac724847f2d0926d2231808871508a7dd9)
2003-03-24 11:31:01 +00:00
Jelmer Vernooij
11e9de855c Patch from metze to generalise POPT_COMMON_SAMBA, with some minor changes
(This used to be commit 2ddfed298d7f0b6e690275725a39c3ef107077ae)
2003-03-24 11:25:34 +00:00
Tim Potter
2238286425 Started working on python routines to add and delete domain users.
Unfortunately users get created with the ACB mask set to disabled and
must change password.  The set_user_info2 call required to fix this
doesn't quite work yet...
(This used to be commit 55a341a367a7d1b18ae7ef04678479eb74b68ea3)
2003-03-24 06:31:49 +00:00
Volker Lendecke
b5762d9937 Implement abartlet's suggestion to add attribs to ldap if they
are 'SET' when adding the account.

I really don't like passing flags down to inner routines and
complicated if/else conditions, but this time he might be right. ;-)

Volker
(This used to be commit 80d2578108da14f60133df3a308b867beb27e920)
2003-03-23 14:19:13 +00:00
Jelmer Vernooij
dc0ce6f158 Convert to popt.
(This used to be commit 18d52ce914715d188966be95f9e4466666a04f74)
2003-03-23 13:42:38 +00:00
Andrew Bartlett
8e2c74c6ee Fix compile.
(This used to be commit 6fbee12a8170e0bce4e94806105786b38160ada5)
2003-03-23 13:18:05 +00:00
Jelmer Vernooij
67cf75843e Convert to popt.
(This used to be commit 691c63ad6b522ae7984017ebadffb5c7c13f6992)
2003-03-23 13:12:04 +00:00
Andrew Bartlett
1f5e93e2e7 NTLM Authentication:
- Add a 'privileged' mode to Winbindd.  This is achieved by means of a directory
  under lockdir, that the admin can change the group access for.

- This mode is now required to access with 'CRAP' authentication feature.
- This *will* break the current SQUID helper, so I've fixed up our ntlm_auth
  replacement:
 - Update our NTLMSSP code to cope with 'datagram' mode, where we don't get a
   challenge.
 - Use this to make our ntlm_auth utility suitable for use in current Squid 2.5
   servers.
 - Tested - works for Win2k clients, but not Win9X at present.  NTLMSSP updates
   are needed.
 - Now uses fgets(), not x_fgets() to cope with Squid environment (I think
   somthing to do with non-blocking stdin).

- Add much more robust connection code to wb_common.c - it will not connect to
  a server of a different protocol version, and it will automatically try and
  reconnect to the 'privileged' pipe if possible.
  - This could help with 'privileged' idmap operations etc in future.

- Add a generic HEX encode routine to util_str.c,
- fix a small line of dodgy C in StrnCpy_fn()

- Correctly pull our 'session key' out of the info3 from th the DC.  This is
  used in both the auth code, and in for export over the winbind pipe to
  ntlm_auth.

- Given the user's challenge/response and access to the privileged pipe,
  allow external access to the 'session key'.  To be used for MSCHAPv2
  integration.

Andrew Bartlett
(This used to be commit dcdc75ebd89f504a0f6e3a3bc5b43298858d276b)
2003-03-23 13:03:25 +00:00
Jelmer Vernooij
b6520a4d48 Convert to popt.
(This used to be commit 83c7f1e1661da14ee46d4ca7a698728fb1beb23b)
2003-03-23 13:02:15 +00:00
Jelmer Vernooij
be47eb5032 Use popt_common for -s, -d and -V
(This used to be commit a1576694a6f23e1c70d7d81ac4feedd4f29c5400)
2003-03-23 12:40:48 +00:00
Jelmer Vernooij
477e1a8cee Don't duplicate the default group mapping functions - use the ones
from passdb
(This used to be commit 78e135cdb17dcf70d8a1259897fd44ecd7a4b3c6)
2003-03-23 12:29:19 +00:00
Volker Lendecke
cf4f074b94 This does two things:
* pdbedit -i -e sets all SAM_ACCOUNT elements
  to CHANGED to satisfy the new pdb_ldap.c handling

* pdbedit -g transfers group mappings. I made this
  separate from the user database, as current installations
  have to live with a split backend.

  So, if you are running 3_0 alphas with LDAP as a backend
  and upgrade to the next 3_0 alpha, you should call

  pdbedit -i tdbsam -e ldapsam -g

  to transfer your group mapping database to LDAP.

  You certainly have to have all your groups as posixGroup
  objects in LDAP and adapt the LDAP schema before this
  call.

Volker
(This used to be commit 6d3faeaef6c77e389d39b6d4660ffea13e7f25f2)
2003-03-23 11:49:24 +00:00
Volker Lendecke
da7c72736a The group mapping functions are not called
directly anymore, but instead through the passdb
interface. So we can make them static.

Volker
(This used to be commit a91af4bea8e761a812f5c70fdc7c7cd15366b412)
2003-03-23 11:44:14 +00:00
Volker Lendecke
933b4d0d1b This adds 'ldap delete dn' as the recommended parameter
for the 'ldap del only sam attr' functionality. So
we are compatiple to the current SuSE patches as well
as to TNG... ;-)

Volker
(This used to be commit 353309e2a3bc27e918bd0a6cf22833d57895fbc8)
2003-03-23 09:04:25 +00:00
Volker Lendecke
8a55edea4d Metzes change:
> Hi Volker,
>
> if 'displayName' is not available we should fallback to 'cn' for map->nt_name
> 'cn' is used as unix group name by nss_ldap.
>
> and if nt_name is not available we should fail (so does this patch)

Volker
(This used to be commit 3a7d1e72e208b9609da4ff65d9fff9179799ecac)
2003-03-23 08:40:28 +00:00
Andrew Bartlett
a8394385e6 Patch from waider to update our samsync (net rpc vampire) code:
- Decode all the database names, even if we don't decode their contents
 - Update the 'set' code to match rpc_server/srv_samr_nt.c in only recording
   the difference between the old and new.

Andrew Bartlett
(This used to be commit 6509397f91a4c218552a48a96df06e595b630898)
2003-03-23 01:33:13 +00:00
Jelmer Vernooij
dc1c29d29c Don't declare variables after instructions
(This used to be commit 818bc35da7b66aa8c4156406b7ab3304d4c94a72)
2003-03-23 01:09:43 +00:00
Jelmer Vernooij
46a6e7f62b We don't need optarg when we have popt
(This used to be commit b46581ef153296a0a04f773115cb2ddad4d44686)
2003-03-23 00:47:35 +00:00
Jelmer Vernooij
8c7753e87f Convert to popt.
(This used to be commit 5f12b246b03aef93165059f632012b6fc4706c70)
2003-03-23 00:44:56 +00:00
Jelmer Vernooij
a76d82616a Use True, not TRUE
(This used to be commit eeeeb37fc6de60928f7efdeb05bb2c6516f24441)
2003-03-23 00:30:17 +00:00
Jelmer Vernooij
73a7abf77d Fix typo in comment
(This used to be commit e7ed8bfc24d94b0b6e70a03eaae927fe1daa7d56)
2003-03-23 00:26:41 +00:00
Jelmer Vernooij
6ab85f1997 Convert to popt.
(This used to be commit 633b3eb7812dc0a58785536a1e7d28329d488b43)
2003-03-23 00:18:44 +00:00
Jelmer Vernooij
42879b0bf3 Move -V to -C to prevent conflict with -V for version
(This used to be commit 99de90adc98b8d5354c769dcd25cc1f34d3769e9)
2003-03-23 00:12:54 +00:00
Jelmer Vernooij
52cee834d0 Don't crash when initialising tdb fails
(This used to be commit b18d02891be1ea3728239eee15a4aed3c3be2fea)
2003-03-23 00:10:35 +00:00
Jelmer Vernooij
7c7054b45e Convert to popt.
(This used to be commit 10c2fe08b6fdc2a9985a154b93555197bf5815fa)
2003-03-22 23:55:33 +00:00
Jelmer Vernooij
6bfe8b7c16 Convert to popt
(This used to be commit 8f285878b30bad7388f69075538c628a7e18ac8a)
2003-03-22 23:51:46 +00:00
Jelmer Vernooij
89cd467415 Add nicer --help headers
(This used to be commit e56ab71f1237a71c6ad4f321ce1db4e9397efd73)
2003-03-22 23:50:11 +00:00
Jelmer Vernooij
94837e2125 Add -U, -N, -i, -A, -W to popt.
(This used to be commit 5a88d78f67fd7853d6f7d5042807afa56091d52c)
2003-03-22 23:48:02 +00:00
Jelmer Vernooij
22e62916d8 - Use FUNCTION_MACRO, not __FUNCTION__.
- Add some const
(This used to be commit e149e70717f38e082ce35d55f9b4d84ba8419af7)
2003-03-22 23:25:44 +00:00
Andrew Bartlett
1ce67b7672 Valgrind found a few memory leaks!
Andrew Bartlett
(This used to be commit fb680f610ceb9a0f350c99456cf7ab1a507543fe)
2003-03-22 23:25:09 +00:00
Jelmer Vernooij
dea7597767 Don't use EDQUOT on systems where it's not available
(This used to be commit 2e1e5719f188a933e6b691fbd48037a0d29497e4)
2003-03-22 22:04:58 +00:00
Jelmer Vernooij
c8864235ba Detect missing -lroken properly on systems without krb5-config
(This used to be commit 9c3b8533fc6d2a68e013668d0927d479f4ab58dd)
2003-03-22 22:00:19 +00:00
Jelmer Vernooij
ee529672e2 Return value in non-void function
(This used to be commit 0efa773bac4b9fe2f79265413c32fecce55cc369)
2003-03-22 21:59:17 +00:00
Jelmer Vernooij
4985533fd3 Use FUNCTION_MACRO, not __FUNCTION__
(This used to be commit 6df38e250af1a8e7213ad66342c71c52ce118a12)
2003-03-22 20:49:55 +00:00
Volker Lendecke
ba47af4ec2 Never touch complicated if/else/elsif structures :-)
This repairs domain join with fully existing wks-account which I broke
with my last patch...

Volker
(This used to be commit 582a34efbe3c1570b852c93318ff6002954ddf6a)
2003-03-22 20:48:47 +00:00
Jelmer Vernooij
38794e945e Don't use errno's when they're not available
(This used to be commit b757a4374832d76500a889e4785622320881018d)
2003-03-22 19:39:31 +00:00
Volker Lendecke
a9aa2cb025 This changes the way we do LDAP updates. We don't use LDAP_MOD_MODIFY
anymore, but instead look at what is currently stored in the
database. Then we explicitly delete the existing attribute and add the
new value if it is not NULL or "". This way we can handle appearing
and disappearing attributes quite nicely.

This currently breaks pdbedit -o, as this does not set the CHANGED
flag on the SAM_ACCOUNT.

Jelmer suggested that we set all the fields on CHANGED in
context_add_sam_account. This sounds not too unreasonable.

Volker
(This used to be commit f7149cf500d2b10ee72163c018a39fdd192d7632)
2003-03-22 19:15:50 +00:00
Andrew Bartlett
5050e8ee1a Revert bogus part of previous patch.
(This used to be commit 3cddfe211da812a533611eecba5d5da55fd3cf2d)
2003-03-22 13:41:16 +00:00
Andrew Bartlett
a38e5e6850 Small clenaup patches:
- safe_string.h - don't assume that __FUNCTION__ is available
 - process.c - use new workaround from safe_string.h for the same
 - util.c - Show how many bytes we smb_panic()ed trying to smb_xmalloc()
 - gencache.c - Keep valgrind quiet by always null terminating.
 - clistr.c - Add copyright
 - srvstr.h - move srvstr_push into a .c file again, as a real function.
 - srvstr.c - revive, with 'safe' checked srvstr_push
 - loadparm.c - set a default for the display charset.

Andrew Bartlett
(This used to be commit a7eba37aadeb0b04cb1bd89deddb58be8aba825c)
2003-03-22 13:06:52 +00:00
Andrew Bartlett
b508fdfc23 Fix compile on IA64 by noting that this should be the integer, not a pointer
to the integer for SIVAL().
(This used to be commit e8b4b136669e7e415557956d698c66c254b28ec1)
2003-03-22 10:54:03 +00:00
Andrew Bartlett
bde949c721 It seems that this causes some problems on some linux platforms - it's a
pity becouse otherwise you need to link a program with it to get the
fstring/pstring bugs.

Andrew Bartlett
(This used to be commit b1b4370955d50fd4997c7171a99fe03f97190aca)
2003-03-22 10:44:07 +00:00
Andrew Bartlett
87cbd9ab68 Patch from Jianliang Lu <j.lu@tiesse.com> to set the 'minimum password age'
when setting the password.

Andrew Bartlett
(This used to be commit 552198b9e149c41f8cb2f976421ef030eac6fba6)
2003-03-22 08:07:53 +00:00
Jelmer Vernooij
58cd54aeb8 FALSE -> False (reported by Paul Green)
(This used to be commit 1002b0bbff295548b74580dbb0dc0c76474af23b)
2003-03-22 00:27:18 +00:00