summaryrefslogtreecommitdiff
path: root/source3/utils/pdbedit.c
AgeCommit message (Collapse)AuthorFilesLines
2003-05-12Fix compiler warnings.Jeremy Allison1-1/+0
Jeremy. (This used to be commit e12934c67b6aea9e3e449009e159ce6814dcbd11)
2003-05-10Reverse previous patch from Stefan and me after comments by Andrew Bartlett.Jelmer Vernooij1-3/+0
(This used to be commit d31509fe88da8727521586dced1da2c73bfee2bc)
2003-05-10Patch from metze and me that adds dummy smb_register_*() functionsJelmer Vernooij1-0/+3
(This used to be commit 367a5cad1edf6a49783806d5a8b59a62d8856706)
2003-05-01init wellknown in pdbedit tooSimo Sorce1-0/+6
add group mapping mappings to idmap at startup (This used to be commit 62365023db61d5a4fa32845af3db73bce6cb94ea)
2003-05-01*id_to_*id call reshape to return NTSTATUS errorsSimo Sorce1-0/+2
plus internal fixes 1st stage (This used to be commit 6d036761e565bc93964bb3c939d5b7d78d5778a3)
2003-04-29This is a nice rewrite:Simo Sorce1-33/+15
SAM_ACCOUNT does not have anymore uid and gid fields all the code that used them has been fixed to use the proper idmap calls fix to idmap_tdb for first time idmap.tdb initialization. auth_serversupplied_info structure has now an uid and gid field few other fixes to make the system behave correctly with idmap tested only with tdbsam, but smbpasswd and nisplus should be ok have not tested ldap ! (This used to be commit 6a6f6032467e55aa9b76390e035623976477ba42)
2003-04-29Merge 3.0's change to how we add users onto HEAD, including a few other bitsAndrew Bartlett1-12/+4
of sync-up for the rpc_server/srv_samr_nt.c Andrew Bartlett (This used to be commit 3c867aedd9abc29389f5d049dbc94ada6738d1b0)
2003-04-26let's suppose I want to specify exactly which SID a user should have ...Simo Sorce1-5/+74
Simo. (This used to be commit ef1eaa9b7e98b532e8ef98c1036a4b2d5f3d4dc5)
2003-03-30- Point users at the HOWTO Collection instead of 'README' in modules/mysql.cJelmer Vernooij1-2/+0
- Make passdb work with absolute paths (passdb backend = /path/to/smbpasswd.so works now). vfs, rpc and charset will follow (This used to be commit 794d3ed03619a4e41558d9ff65783a1aa1b2be90)
2003-03-24Revoke some of the popt patch from metze I applied earlier today. It addedJelmer Vernooij1-1/+1
some double options and broke some parameters. (This used to be commit d5f9b0275c91512e1926504f22aaeec2d104430d)
2003-03-24Patch from metze to generalise POPT_COMMON_SAMBA, with some minor changesJelmer Vernooij1-3/+1
(This used to be commit 2ddfed298d7f0b6e690275725a39c3ef107077ae)
2003-03-23Implement abartlet's suggestion to add attribs to ldap if theyVolker Lendecke1-6/+0
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-23This does two things:Volker Lendecke1-1/+37
* 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-23Move -V to -C to prevent conflict with -V for versionJelmer Vernooij1-1/+2
(This used to be commit 99de90adc98b8d5354c769dcd25cc1f34d3769e9)
2003-03-15Truncate the machinename manually, so as not to generate level 0 debugs forAndrew Bartlett1-10/+12
an expected situation. Andrew Bartlett (This used to be commit a07fccb7ae169c0b5089e3f7d2c5d6465b2e4686)
2003-02-27- Rename 'modules = ' to 'preload modules = 'Jelmer Vernooij1-2/+1
- Add smb_probe_module() - Add init_modules() - Call these functions (This used to be commit f8f21653225792c0001d183c6efe8b7d89a0785d)
2003-02-07Revert Flag testing upon abartlet's request ;-)Volker Lendecke1-3/+5
Volker (This used to be commit e8f751fe84cbd20934116d5213f9bb1850aa9dfa)
2003-02-06Make account flags editable with pdbedit.Volker Lendecke1-4/+22
Volker (This used to be commit 597c50550955c5bdc0c646d5b751d377b40f3485)
2003-01-07Fix memory leak. Thanks, Herb!Volker Lendecke1-0/+1
Volker (This used to be commit 8915d59a5939b78a177dcd3e075a122e68e8c64a)
2003-01-07Create a machine account correctly if the unix account exists.Volker Lendecke1-4/+14
With this, my test for W2kSP3 join after pdbedit -a -m works fine. Volker (This used to be commit c9d0c5254c7d4ddb343f405652c609a0128e60f9)
2003-01-02BIG patch...Andrew Bartlett1-12/+16
This patch makes Samba compile cleanly with -Wwrite-strings. - That is, all string literals are marked as 'const'. These strings are always read only, this just marks them as such for passing to other functions. What is most supprising is that I didn't need to change more than a few lines of code (all in 'net', which got a small cleanup of net.h and extern variables). The rest is just adding a lot of 'const'. As far as I can tell, I have not added any new warnings - apart from making all of tdbutil.c's function const (so they warn for adding that const string to struct). Andrew Bartlett (This used to be commit 92a777d0eaa4fb3a1c7835816f93c6bdd456816d)
2002-12-28Revert by Simo's request. HEAD and 3.0 should be in sync forJeremy Allison1-10/+2
this except for the modules load. Jeremy. (This used to be commit c7c3afbd0de8bd8797f91d350368a2419fcede0e)
2002-12-28Patch for coredump with missing arg from "Bradley W. Langhorst" ↵Jeremy Allison1-1/+8
<brad@langhorst.com> Jeremy. (This used to be commit 5914c38a54fcfdb007352b152dc2206708d59af6)
2002-11-13Don't crash when there are no arguments specifiedJelmer Vernooij1-1/+4
(This used to be commit 0855e5810aefd71c37031be31abe91229e2de8b3)
2002-11-12Removed global_myworkgroup, global_myname, global_myscope. Added liberalJeremy Allison1-13/+4
dashes of const. This is a rather large check-in, some things may break. It does compile though :-). Jeremy. (This used to be commit 82b8f749a36b42e22186297482aad2abb04fab8a)
2002-10-21I was somewhat annoyed by 'pdbedit -a vl' spitting an error messageVolker Lendecke1-1/+7
at me :-) Volker (This used to be commit c4452ef22cf63c73bfb3574a55a4810af511ff20)
2002-10-12Nice *big* patch from metze.Andrew Bartlett1-15/+15
The actual design change is relitivly small however: It all goes back to jerry's 'BOOL store', added to many of the elements in a SAM_ACCOUNT. This ensured that smb.conf defaults did not get 'fixed' into ldap. This was a great win for admins, and this patch follows in the same way. This patch extends the concept - we don't store values back into LDAP unless they have been changed. So if we read a value, but don't update it, or we read a value, find it's not there and use a default, we will not update ldap with that value. This reduced clutter in our LDAP DB, and makes it easier to change defaults later on. Metze's particular problem was that when we 'write back' an unchanged value, we would clear any muliple values in that feild. Now he can still have his mulitivalued 'uid' feild, without Samba changing it for *every* other operation. This also applies to many other attributes, and helps to eliminate a nasty race condition. (Time between get and set) This patch is big, and needs more testing, but metze has tested usrmgr, and I've fixed some pdbedit bugs, and tested domain joins, so it isn't compleatly flawed ;-). The same system will be introduced into the SAM code shortly, but this fixes bugs that people were coming across in production uses of Samba 3.0/HEAD, hence it's inclusion here. Andrew Bartlett (This used to be commit 7f237bde212eb188df84a5d8adb598a93fba8155)
2002-10-05Add more common options to popt_common - and start usingJelmer Vernooij1-19/+7
the ones for debuglevel and configuration file in pdbedit (This used to be commit cb0d03a393d9009c3e16b9d05d88c171de9a9414)
2002-09-26move all the passdb internal interface to NTSTATUSSimo Sorce1-13/+13
only the interface has been fully moved to NTSTATUS not all the plugins make full use of it, but have been all converted. My testings passed completely, however a bit of more testing is welcome Simo. (This used to be commit 102a26e06591928a03b49cd312a65811ed46314f)
2002-08-21pdbedit needs global_myname to be set in order to display theVolker Lendecke1-1/+12
user SIDs correctly. Volker (This used to be commit 287b7bda11100c42f2cdea36a20a81f6ea397f43)
2002-08-15*** empty log message ***Simo Sorce1-87/+175
(This used to be commit cb72eead70509eddaa051571f3eed3c46304b5f8)
2002-08-04passwords where not checked (you cannot check if the same buffer differs ↵Simo Sorce1-6/+18
from itself). they where alo not clean after use! Simo. (This used to be commit 5a257096e9afdcd1dea863dff43952457a74a9f1)
2002-07-28Add the ability to set account policies too.Andrew Bartlett1-7/+25
Andrew Bartlett (This used to be commit 2bf6edf78b64335bf10c10c893d6e8fa0fac708b)
2002-07-24Make it possible to query account policy values from pdbedit (set to come soon).Andrew Bartlett1-11/+29
Update account_pol.c to use just uint32, rather then uint32 for paramaters, int32 for storage. (The int32 functions didn't have seperate return/status values, uint32 functions use a pointer-paramater). Move the #define -> string from a swtich to a table, so we can look it up both ways. Andrew Bartlett (This used to be commit c5b5e3d653f5c38a283d901a409be6603d5103f7)
2002-07-21Fix up dir drive call.Tim Potter1-1/+1
(This used to be commit fe229cc126a4bfdce12882ac7eaa893e00cd506e)
2002-07-21Another smattering of static and constAndrew Bartlett1-1/+1
(This used to be commit 897cc4a610932e596f8a9807213166e380ef0203)
2002-07-14Show the account flags in the 'verbose' listing of pdbedit.Andrew Bartlett1-0/+2
Andrew Bartlett (This used to be commit b5ec92d7a2e5ba33b641267d2319d101d70a0d9a)
2002-06-14Kill useless castAndrew Bartlett1-2/+2
(This used to be commit e2f9dd8b65063a276569d9c33aaf06606003b85c)
2002-06-14Patch from ctrlsoft to make the pluggable passdb subsystem use an lp_listAndrew Bartlett1-10/+12
rather than a string when configuring mulitple backends. Also adjust some of the users of get_global_sam_sid() to cope with the fact that it just might not exist (uninitialised, can't access secrets.tdb). More places need conversion. Add some const and remove silly casts. Andrew Bartlett (This used to be commit c264bf2ec93037d2a9927c00295fa60c88b7219d)
2002-06-13Latest patch from metze <metze@metzemix.de> to move most of samba acrossAndrew Bartlett1-4/+6
to using SIDs instead of RIDs. The new funciton sid_peek_check_rid() takes an 'expected domain sid' argument. The idea here is to prevent mistakes where the SID is implict, but isn't the same one that we have in the struct. Andrew Bartlett (This used to be commit 04f9a8ff4c7982f6597c0f6748f85d66d4784901)
2002-05-24Some of the updates from ctrlsoft's 'Various' patch:Andrew Bartlett1-12/+12
- convert net to popt - convert status to popt - adapt examples/pdb/ to multiple passdb system - add dynamic debug class example to examples/pdb/ and some reformatting to better match the samba coding style. Andrew Bartlett (This used to be commit 2498bc69d4e5c38ec385f640489daa94c508c726)
2002-05-18so here it is the code to introduce seriously debugggging classes.Simo Sorce1-1/+2
this is a first step only passdb stuff has beein "classized". - so what can you do? set debug level to: 1 poasdb:10 that will make all the code run at debug level 1 except the code in passdb/* files that will run at level 10 TODO: fix the man page - also smbcontrol has this nice feature so smbcontrol smbd debug 3 passdb:5 will set every smbd to have a default log level of 3 while passdb stuff will be at level 5 and so no.. minor cosmetic fix to pdbedit is there too (This used to be commit be5c3b3f5781ddc002ffcc98df04ab024dcef4ca)
2002-05-10Allow -c to specify the location of the config file, and fix up some handlingAndrew Bartlett1-13/+15
of non-existant passdb cases. (This used to be commit e56de32f5ce5cb301137497451b0ccd633f09f54)
2002-04-26fix compile errorHerb Lewis1-1/+6
(This used to be commit c64a57a6106bfd766679ac89837881ed9592409b)
2002-04-15Another patch from jelmer:Andrew Bartlett1-31/+37
Doco for pdbedit and (ugly, but the best we could come up with) fix for compiling pdbedit on some non-gcc compilers. Andrew Bartlett (This used to be commit 80adf1dbb56cf8bdbfbcc2c8c7b670c0a23c97f8)
2002-04-13More updates from ctrlsoft. (Jelmer Vernooij <jelmer@nl.linux.org>)Andrew Bartlett1-8/+32
Andrew Bartlett (This used to be commit 012b3326c40ca0f8f4c7673310d73f695cc4f79b)
2002-04-13This is the 'multiple pdb backends' patch from ctrlsoft, aka Jelmer VernooijAndrew Bartlett1-318/+110
<jelmer@nl.linux.org>. This patch also includes major rework of pdbedit to use popt, and the addition of -i paramter (allowing the user to specify which PDBs is being operated on) and -e to export a pdb - useful for backup and testing etc. Use of -i and -e gets us pdb2pdb functionality for transition between backends, much like the sam2sam in TNG. Andrew Bartlett (This used to be commit c10def37f506d3f2bab442418ac08fdb62659b02)
2002-03-19second step to gain free uid<->rid mappingSimo Sorce1-0/+2
we still need to free gid<->rid mapping and few other stuff (This used to be commit aa4b6f8181f34196a28951264dd8b631a5deef7f)
2002-03-18more verbose checking in talloc and util_pwSimo Sorce1-9/+10
fixed tdbsam memory corruption (and segfault) reducing calls to pdb_uid_to_user_rid and countrary to 0 to move to a non alghoritmic rid allocation with some passdb modules. (This used to be commit 9836af7cd623357feaec07bc49cfb78f0aa01fc3)
2002-01-31Initialise some SAM_ACCOUNT structs to NULL, and add some more error checking.Andrew Bartlett1-6/+14
Andrew Bartlett (This used to be commit f3f375dc6b7175d4dd4ce401815e5dfdd9747083)