1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

514 Commits

Author SHA1 Message Date
Jim McDonough
dc1f0804dd r19058: Implement "user cannot change password", and complete "user must change
password at next logon" code.  The "password last set time" of zero now
means "user must change password", because that's how windows seems to
use it.  The "can change" and "must change" times are now calculated
based on the "last set" time and policies.

We use the "can change" field now to indicate that a user cannot change
a password by putting MAX_TIME_T in it (so long as "last set" time isn't
zero).  Based on this, we set the password-can-change bit in the
faked secdesc.
(This used to be commit 21abbeaee9)
2007-10-10 12:15:06 -05:00
Volker Lendecke
2b7d1fc779 r19008: Fix a segfault
(This used to be commit adfc82f0e6)
2007-10-10 12:14:57 -05:00
Volker Lendecke
72e9a5d9e6 r18665: Remove two type-punned warnings
(This used to be commit 157b2c0c26)
2007-10-10 12:00:45 -05:00
Gerald Carter
4646147a39 r18616: fix breakage after DLIST_ADD_END() changes for --with-pam
(This used to be commit 5c00b5497b)
2007-10-10 11:52:00 -05:00
Stefan Metzmacher
258a465e20 r18605: sync dlinklist.h with samba4, that means DLIST_ADD_END()
and DLIST_DEMOTE() now take the type of the tmp pointer
not the tmp pointer itself anymore.

metze
(This used to be commit 2f58645b70)
2007-10-10 11:51:59 -05:00
Gerald Carter
2b27c93a9a r18271: Big change:
* autogenerate lsa ndr code
* rename 'enum SID_NAME_USE' to 'enum lsa_SidType'
* merge a log more security descriptor functions from
  gen_ndr/ndr_security.c in SAMBA_4_0

The most embarassing thing is the "#define strlen_m strlen"
We need a real implementation in SAMBA_3_0 which I'll work on
after this code is in.
(This used to be commit 3da9f80c28)
2007-10-10 11:51:18 -05:00
Volker Lendecke
6655e1e997 r18029: More C++ stuff
(This used to be commit 089b51e28c)
2007-10-10 11:43:23 -05:00
Volker Lendecke
3bc4fd1bb9 r17924: Get rid of warnings now that talloc is merged.
Destructors now take a pointer to the "real" destroyed object as an argument.

Volker
(This used to be commit 70edd716ef)
2007-10-10 11:38:59 -05:00
Jeremy Allison
9ab430ac4b r17875: Fix (rather theoretical, but still...) null deref found by
Stanford checker.
Jeremy.
(This used to be commit 45d77ae122)
2007-10-10 11:38:56 -05:00
Gerald Carter
049fcc8dd5 r17736: Apply the Unix group patch when creating the token for a
username map.
(This used to be commit 0298a3466b)
2007-10-10 11:38:47 -05:00
Gerald Carter
21e35f8e73 r17710: Thanks to Thomas Bork for testing and continued feedback on this.
Comments from the patch:

/* Add the "Unix Group" SID for each gid to catch mapped groups
   and their Unix equivalent.  This is to solve the backwards
   compatibility problem of 'valid users = +ntadmin' where
   ntadmin has been paired with "Domain Admins" in the group
   mapping table.  Otherwise smb.conf would need to be changed
   to 'valid user = "Domain Admins"'.  --jerry */
(This used to be commit 3848199287)
2007-10-10 11:38:46 -05:00
Volker Lendecke
f852fdbe06 r17626: Some C++ Warnings
(This used to be commit 09e7c010f0)
2007-10-10 11:38:44 -05:00
Volker Lendecke
0691ed55ca r17584: Some C++ Warnings
(This used to be commit f6194cf4b2)
2007-10-10 11:38:41 -05:00
Volker Lendecke
097bd537ad r17573: Fix typo
(This used to be commit fd6e3f133b)
2007-10-10 11:38:40 -05:00
Volker Lendecke
b29915d611 r17571: Change the return code of cli_session_setup from BOOL to NTSTATUS
Volker
(This used to be commit 94817a8ef5)
2007-10-10 11:38:39 -05:00
Jeremy Allison
f8aa1c75f4 r17402: Added lookup_name_smbconf() to be called when looking
up names from smb.conf. If the name is unqualified it
causes the lookup to be done in WORKGROUP\name, then
"Unix [users|groups]"\name rather than searching the
domain. Should fix the problems with "force user"
selecting a domain user by preference.
Jeremy.
(This used to be commit 1e1fcb5eb2)
2007-10-10 11:38:31 -05:00
Volker Lendecke
749c8d587c r17399: Some C++ warnings
(This used to be commit d12b08fc61)
2007-10-10 11:38:31 -05:00
Jeremy Allison
4905106778 r17393: Remove Volker's ASSERT that num_groupsids > 0.
For guest connection they may well be zero.
This should fix up the buildfarm (fingers
crossed).
Jeremy.
(This used to be commit 16ebccbc58)
2007-10-10 11:38:31 -05:00
Jeremy Allison
87b2b16cbf r17392: Commit Volker's fix for the valid users problem.
Let's look at the build farm now... :-).
Jeremy.
(This used to be commit 6d822b8567)
2007-10-10 11:38:31 -05:00
Jeremy Allison
74ee62a45b r17391: Revert the second part of the valid users fix - the
netlogon code uses pdb_get_group_sid() which could
return a S-1-1-22 unix sid. Who knew.... :-(.
I'm going to test Volker's fix instead. Once
3.0.23b is out we *have* to rip out the pdb_set_group_sid()
code....
Jeremy.
(This used to be commit 65003e1b25)
2007-10-10 11:38:31 -05:00
Jeremy Allison
ba5f9c4ef9 r17388: Fix the "valid users"/token issue for now. Volker,
please come in and fix it in a less ugly way once
you have some time. Thanks,
Jeremy.
(This used to be commit 79b1e668e2)
2007-10-10 11:38:30 -05:00
Jeremy Allison
dca7d08e61 r17378: Fix the issues people have been having with mapped
users (username map) and failure to connect to a
share. Essentially, even on a standalone system
we were going into the create_token_from_username()
code (I think by mistake) if the username was mapped.
Fixes bug #3991.

Volker & Jerry - please go over this with a very careful eye
and let me know if this isn't correct (I think it is,
but this isn't my code and it's a dangerous area for
me to be playing in :-).

Jeremy
(This used to be commit 0b5b2b53ec)
2007-10-10 11:38:29 -05:00
Volker Lendecke
413ec64f27 r17022: Fix the build farm -- maybe this is the real fix, testing more
(This used to be commit 19d0269000)
2007-10-10 11:19:20 -05:00
Volker Lendecke
f8004328f4 r17016: Different and smaller fix for the valid users = username problem.
If no winbind is around, the best we can do to get the user's token correct is
to ask unix via create_token_from_username. More investigation is needed if
this also fixes the +groupname for unmapped groups problems more cleanly.

Volker
(This used to be commit f6e3ee147f)
2007-10-10 11:19:20 -05:00
Volker Lendecke
de4492b28d r17011: Back out r17010 after talking to Jerry. Another fix pending...
Volker
(This used to be commit 7a629118ee)
2007-10-10 11:19:19 -05:00
Volker Lendecke
a85395e0f5 r17010: If winbind is not around, add S-1-22-1-<uid> to the user's token.
See the comment in the patch for the reason.

Volker
(This used to be commit 5e07ab750a)
2007-10-10 11:19:19 -05:00
Jeremy Allison
fbdcf2663b r16945: Sync trunk -> 3.0 for 3.0.24 code. Still need
to do the upper layer directories but this is what
everyone is waiting for....

Jeremy.
(This used to be commit 9dafb7f48c)
2007-10-10 11:19:14 -05:00
Volker Lendecke
3899f95e1f r16865: This is a proposal to fix bug 3915. Before sending patches around, this is
what svn is for.

The idea is that we fall back to a pure unix user with S-1-22 SIDs in the
token in case anything weird is going on with the 'force user'.

Volker
(This used to be commit 9ec5ccfe85)
2007-10-10 11:19:12 -05:00
Volker Lendecke
fc4abcf028 r16864: Intermediate checkin -- swap the sid_check_is_in_unix_users and
sid_check_is_in_our_domain cases.

Volker
(This used to be commit dc403cec88)
2007-10-10 11:19:12 -05:00
Volker Lendecke
355cbde8df r16766: A warning found by RHEL3. This might actually be 3.0.23 code, maybe there are
vasprintf implementations that don't like a NULL format.

Volker
(This used to be commit 03c665c307)
2007-10-10 11:19:10 -05:00
Gerald Carter
9d0ccba34c r16749: BUG 3905: don't fail in create_local_nt_token() when a
checking for the builtin Administrators group membership.
security = server has no domain info in secrets.tdb
(This used to be commit fa477969fb)
2007-10-10 11:19:09 -05:00
Jeremy Allison
8322d26276 r16632: Fix bug #3882 reported by jason@ncac.gwu.edu.
Jeremy.
(This used to be commit 6b39f53e43)
2007-10-10 11:19:04 -05:00
Gerald Carter
600b0ae2e9 r16471: Bug reported by Vitaly Protsko <villy@sft.ru> in 3.0.23rc1.
Add missing automatic add of the Administrators SID in the absence
of winbindd and precense of Domain Admins SID in the user's token.
(This used to be commit ce7846d6f1)
2007-10-10 11:18:55 -05:00
Jeremy Allison
f9147c4e40 r16241: Fix Klocwork #106 and others like it.
Make 2 important changes. pdb_get_methods()
returning NULL is a *fatal* error. Don't try
and cope with it just call smb_panic. This
removes a *lot* of pointless "if (!pdb)" handling
code. Secondly, ensure that if samu_init()
fails we *always* back out of a function. That
way we are never in a situation where the pdb_XXX()
functions need to start with a "if (sampass)"
test - this was just bad design, not defensive
programming.
Jeremy.
(This used to be commit a0d368197d)
2007-10-10 11:17:27 -05:00
Jeremy Allison
a1e0a0e928 r16230: Fix Klocwork #861 and others. localtime and asctime
can return NULL. Ensure we check all returns correctly.
Jeremy.
(This used to be commit 6c61dc8ed6)
2007-10-10 11:17:26 -05:00
Jeremy Allison
d4a80fdf38 r16209: Klocwork bug #66, ensure no null deref.
Jeremy.
(This used to be commit 79e693798c)
2007-10-10 11:17:25 -05:00
Volker Lendecke
0372e03722 r16204: Fix Klocwork # 14
localtime() can return NULL.

Volker
(This used to be commit 07c5dcb863)
2007-10-10 11:17:25 -05:00
Volker Lendecke
780f121462 r16150: Fix possible NULL dereference found by Klocwork ID # 17
(This used to be commit 3159bd3a4e)
2007-10-10 11:17:22 -05:00
Volker Lendecke
21eeddb80d r16141: Dummy commit to make the build farm re-test against Samba4 16140
(This used to be commit a1fcacf756)
2007-10-10 11:17:22 -05:00
Jeremy Allison
f897e7094f r16076: Fix for machine password timeout overflow from Shlomi Yaakobovich
<Shlomi@exanet.com>.
Jeremy.
(This used to be commit 5cd234a1ff)
2007-10-10 11:17:19 -05:00
Jeremy Allison
905bac92ba r15676: Fix meaningless debug statement from uninitialized variable.
Spotted by "John E. Malmberg" <wb8tyw@qsl.net>.
Jeremy.
(This used to be commit ff3fe39b83)
2007-10-10 11:17:06 -05:00
Volker Lendecke
990c406a89 r15600: Correctly fill in the gid for local users.
Volker
(This used to be commit 6071dd5db0)
2007-10-10 11:17:02 -05:00
Gerald Carter
18d5a26f74 r15549: removing rhosts and 'hosts equiv' authentication features
(This used to be commit d19dad8815)
2007-10-10 11:16:58 -05:00
Volker Lendecke
5ab7e77bc7 r15476: Transfer the was_mapped flag from user_info to server_info also in auth_sam
and auth_domain. Thanks for Simo to point this out.

Volker
(This used to be commit 293b89dfb1)
2007-10-10 11:16:52 -05:00
Volker Lendecke
dc9f30b8b0 r15475: Ugly and disgusting patch to fix the username map problem I created by
changing the token generation. I *hate* this code!

Jerry, you have been looking at this as well, can you double-check that I did
not screw it up?

Thanks,

Volker
(This used to be commit 2765c4ff8d)
2007-10-10 11:16:52 -05:00
Volker Lendecke
83e4ea7e85 r15472: Remove an unused function parameter
(This used to be commit d2f39ae7fe)
2007-10-10 11:16:52 -05:00
Gerald Carter
8719dc2b93 r15393: remove extra call to fallback user creation on member servers; it's handled by the smb_getpwnam() call deeper in
(This used to be commit 7433dba78b)
2007-10-10 11:16:39 -05:00
Paul Green
567e8fa6ca r15368: Remove some dead code. -- paulg
(This used to be commit e1bd357fe8)
2007-10-10 11:16:37 -05:00
Paul Green
0ec947bf1a r15285: Fix the build.
(This used to be commit 2270a5196d)
2007-10-10 11:16:31 -05:00
Paul Green
31693197be r15283: Oh yeah. The build farm doesn't do much with head. OK, here is the patch to SAMBA_3_0 to declare prototypes for the initialization functions. These are the same changes I just made to head. --paulg
(This used to be commit 17774387ad)
2007-10-10 11:16:31 -05:00