1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-01 05:47:28 +03:00

490 Commits

Author SHA1 Message Date
Tim Potter
ce22267ec8 A collection of fixes/cleanups to the security descriptor code by
matt_zinkevicius@hp.com
-
Andrew Bartlett
b30b6202f3 This is my 'Authentication Rewrite' version 1.01, mostly as submitted to
samba-technical a few weeks ago.

The idea here is to standardize the checking of user names and passwords,
thereby ensuring that all authtentications pass the same standards.  The
interface currently implemented in as

nt_status = check_password(user_info, server_info)

where user_info contains (mostly) the authentication data, and server_info
contains things like the user-id they got, and their resolved user name.

The current ugliness with the way the structures are created will be killed
the next revision, when they will be created and malloced by creator functions.

This patch also includes the first implementation of NTLMv2 in HEAD, but which
needs some more testing.  We also add a hack to allow plaintext passwords to be
compared with smbpasswd, not the system password database.

Finally, this patch probably reintroduces the PAM accounts bug we had in
2.2.0, I'll fix that once this hits the tree.  (I've just finished testing
it on a wide variety of platforms, so I want to get this patch in).
-
Tim Potter
c9cbe3237e Fix for smbpasswd set_userinfo24 was in the wrong place! -
Jeremy Allison
c51cfc7f0d Allow smbpasswd to join a W2K hosted AD domain.
Jeremy.
-
Tim Potter
2e33940360 Held a shoot-out between NT_STATUS_NO_PROBLEMO and NT_STATUS_NOPROBLEMO.
According to the incorruptible judges find and grep, the latter won.

Mmm - procrastination.  (-:
-
Andrew Bartlett
bd3c2a0cdd This backs out my last change, which broke some of the finer points of RPC
coding :-).  I'll be more carfull in this area in future.

This does not back out the cli_login change, so domain logons still work, but
only for english.

Andrew Bartlett
-
Andrew Bartlett
cf1d1cd9d6 This fixes security=domain, which has been broke since the big charset
changeover.  For my own sainity I have created a new function to fill out both
the header and buffer for a string in an RPC struct.  This DOES NOT take a
length argument, only the actual string to be placed.

The RPC code is currently littered with code that does init_uni_hdr() followed
immidiatly by init_unistr2(), and often the length argument is wrong.  (It was
for the code I changed, even before the charset stuff).  Another bug where we
made strings AT LEAST MAX_UNICODE_LEN long hid this bug.

This works for loopback connections to Samba, and can't be any more broke than
it was before :-).  (We had double and revese conversions, fun...).

In particular this makes us multibyte complient.

In any case, if there are no objections I will slowly convert other bits of
code to the same system.
-
Jean-François Micouleau
3056357cd8 implement:
LSA_ENUM_PRIVS
	LSA_PRIV_GET_DISPNAME
	LSA_ENUM_ACCOUNTS
	LSA_OPENACCOUNT
	LSA_ENUMPRIVSACCOUNT
	LSA_GETSYSTEMACCOUNT

It's a work in progress. nobody should expect it to work

	J.F.
-
Jean-François Micouleau
3f14dda2a2 add query user info level 20 (for RAS)
add query dominfo level 5
some cleanup, don't free talloced memory.
implement delete domain and local groups.

	J.F.
-
Jean-François Micouleau
a8006e6f3e when converting ascii to unicode, if the ascii string is NULL, don't
convert it, rpcstr_push doesn't like it.
-
Jeremy Allison
5059fbbb76 Added JF's fix for max_entries being 0.
Jeremy.
-
Andrew Tridgell
debb471267 The big character set handling changeover!
This commit gets rid of all our old codepage handling and replaces it with
iconv. All internal strings in Samba are now in "unix" charset, which may
be multi-byte. See internals.doc and my posting to samba-technical for
a more complete explanation.
-
Jeremy Allison
1685e41da0 Missing prs_align() was causing Win9x nexus tools to fail. security_info_sent
was being miss-parsed.
Jeremy.
-
Jeremy Allison
d4872c94c2 Fixed auto-alloc of dispinfo code when unmarshalling.
Jeremy.
-
Jeremy Allison
7079300da6 Added LsaGetConnectedCredentials patch from Manoj Naik <manoj@almaden.ibm.com>.
Jeremy.
-
Jeremy Allison
001e9b7b54 From JF....
hi jeremy,

can you commit the following patch against HEAD. I can't do it right now

Thanks Tim for me. He changed the SAM_DISPINFO_1 array without checking if
he didn't break the server code. And he did.

So on my way I cleaned info_1, 2, .. 5

it may break winbind. I leave to tim the pleasure to fix it ;-)

        jf.

I added some talloc changes and checks for alloc fails.

Jeremy.
-
Tim Potter
008628fb8a Removed another silly static array. -
Herb Lewis
45bf995bf6 SGI compiler fixes.
Jeremy
-
Jeremy Allison
274c0f5028 Ensure we always have a valid pointer on unmarshalling an SD with zero
ace entries.
Jeremy.
-
Tim Potter
89eaaafe7d Fixed bug introduced by changeover of security descriptor code from
malloc() to talloc().  Previously, creating an ACL containing zero ACEs
would return a non-NULL pointer to zero bytes of memory.  The talloc() code
would return a NULL pointer making the ACL a NULL ACL instead of an empty
one.  The difference is a NULL ACL allows all access and an empty ACL
denies all access.

We solve this by calling talloc(ctx, sizeof(SEC_ACE) * num_aces + 1).
Heh.
-
Tim Potter
d936ffedd9 Cosmetic fixups found while playing with the server manager. Added support
for NET_SRV_SET_INFO rpc call which is made when double-clicking on a
computer in the server manager and changing the description.  We always
return NT_STATUS_NOPROBLEMO as NT doesn't seem to decode any error messages
passed back.

Maybe the changed comment string could be stored in a tdb and regurgitated
instead of the "server string" smb.conf parameter?
-
Gerald Carter
3ab50e648d sync this function with 2.2 (single check for NULL parameter) -
Jeremy Allison
54ea00fa87 Removed unused (and potentially crash-causing) free function.
Jeremy.
-
Jeremy Allison
6b4a70cd82 Merging Gerry's spoolss changes.
Jeremy.
-
Jeremy Allison
05a2911403 Fixed W2K SP2 joining a Samba PDC hosted domain.
Jermey.
-
Jeremy Allison
0fe11c329f INFO_24 sometimes has a 2 byte length, sometimes doesn't. Safer to not
depend on it...
Jeremy.
-
Jeremy Allison
5690ec77c8 Modified version of Jim's 0x27 and 0x28 Win9x Secdesc patch.
Jeremy.
-
Jeremy Allison
bc366f3153 Jim McDonough's parse patches for Win9x get SD calls.
Jeremy.
-
Jeremy Allison
a600c96e59 Fixed typo spotted by "Jim McDonough" <jmcd@us.ibm.com>....
Jeremy.
-
Tim Potter
d2eafa7483 Add password length field to SAM_USER_INFO24 structure and fix init
and parse function.
-
Tim Potter
13df2304b3 Added some msdfs client routines. -
Tim Potter
35d2794114 Converted init_samr_q_lookup_names() and samr_io_q_lookup_names()
to use tallocated memory instead of dodgy static arrays.
-
Tim Potter
870e9e4e89 Added *.po to .cvsignore files. -
Tim Potter
8ba30031a4 Added a init function for net_q_logon_ctrl2 so we can make this call
from rpcclient.

Added init and i/o functions for net_{q,r}_logon_ctrl functions so we
can call from rpcclient and respond to this call from smbd.
-
Gerald Carter
09506ac0e6 merge from 2.2 DeletePrinterDriver() server side stud coming
in separate commit after I get it working in 2.2.
-
Tim Potter
5bbd946d59 Reverted samr_io_userinfo_ctr() patch because it broke too much other
stuff.  (-:
-
Tim Potter
fc44cec0de So the samr_io_userinfo_ctr was requiring a SAM_USERINFO_CTR to be passed
in as well as tallocating space for one itself.  I've deleted code so the
passed in container is used to store the SAM user info.  This may have
broken some server side SAM stuff which probably isn't used anyway.  )-:
-
Jean-François Micouleau
62a7a567fd fixes to the group mapping code.
Not ready yet.

	J.F.
-
Tim Potter
a8c49d1e60 Fixed typo in comment. -
Tim Potter
139e767e78 iinit_samr_q_lookup_rids() didn't actually copy the rids into the
parse structure.
-
Tim Potter
d384cae570 Renamed unknown field to access mask in open alias parsing functions. -
Jeremy Allison
9b3dd80176 Added code from "Nigel Williams" <nigel@veritas.com> (yes, the same famous
Nigel Williams who did NIS/GINA !) to implement add/modify/delete shares
for Win2k. Needs testing as I made a few mods to the original code.
Jeremy.
-
Gerald Carter
0feaac00a1 few cleanups to bring in line with 2.2 -
Gerald Carter
0a6ceed279 rpcclient merge from 2.2 (including Jeremy's non-void return fix) -
Jeremy Allison
f4f4aae675 Added Herb's comment fix.
Jeremy.
-
Jeremy Allison
6248fb2292 Fix "proc num out of range" error. Missing rpc call.
Jeremy.
-
Jeremy Allison
fc76681812 Merge of Andrew's changes in 2.2.
Jeremy.
-
Jeremy Allison
04976c32f3 Set SD's for share. Added level 1501. Map GENERIC file bits to specific bits.
Jeremy.
-
Jeremy Allison
94747b4639 Got "medieval on our ass" about adding the -1 to slprintf.
Jeremy.
-
Jeremy Allison
3512ba1f65 Implemented stub function for NET_SHARE_DELETE. Now to implement the real
internals to support server manager.
Jeremy
-