summaryrefslogtreecommitdiff
path: root/source3/utils/net_conf.c
AgeCommit message (Collapse)AuthorFilesLines
2008-04-13libsmbconf: remove the bool verbatim parameter from txt backend init function.Michael Adam1-1/+1
Always be verbatim for now. Backend config options may be added later via some private data pointer. Michael (This used to be commit e8bafcfbf4a7ab1dc1ce4f2acd24b0eb74933256)
2008-04-10net conf: use talloc and talloc_strdup_lower throughout all net conf functions.Michael Adam1-17/+59
Michael (This used to be commit 977cc9898970a0c07c30264e91754740c640e235)
2008-04-10net conf: implement "net conf delincludes".Michael Adam1-0/+40
usage: "net conf delincludes <servicename>" This is equivalent to "net conf setincludes <servicename>" (without further arguments). Michael (This used to be commit a1d09f34ec39b614d738c6f795fe8eafaf634105)
2008-04-10net conf: implement a "net conf setincludes" command.Michael Adam1-0/+50
given zero or more filenames as command line parameters Michael (This used to be commit ab51e4d44c3dcd00697c8ffb2ce628c4072c7a53)
2008-04-10net conf: implement "net conf getincludes".Michael Adam1-0/+47
Michael (This used to be commit 30bc48623cf4f9ee17ff9c3e7a9fd98840a01d92)
2008-04-10net conf: add diagnostic message for failure to load text file.Michael Adam1-0/+2
Michael (This used to be commit 8f2c3efa679d44acc900fb90f03319e830a7dcf4)
2008-04-10net conf: reduce indentation by grouping testmode code together.Michael Adam1-39/+37
Michael (This used to be commit 97f9cb857532328999589062ceb0b229bcaf93a3)
2008-04-10net conf: don't drop config in testmodeMichael Adam1-3/+5
Michael (This used to be commit 74e87b977514df79e49613a0b1c5157469b3cb93)
2008-04-10net conf: fix import to correctly add includes (at the end)Michael Adam1-6/+34
Michael (This used to be commit 3e81db83707e30ad46a565c9a118e7293b6cdf50)
2008-04-10libsmbconf: add a "verbatim" parameter to smbconf_init_txt_simple().Michael Adam1-1/+1
Michael (This used to be commit b9e72b402de412c23702715ead96c20e9b3248cc)
2008-03-27net_conf: fix non-testmode import function.Michael Adam1-1/+11
Michael (This used to be commit cd17cc745a35db8ee158f59a5fff1f0f26cf9c6e)
2008-03-26net_conf: reformat - re-indent one function call.Michael Adam1-2/+5
Michael (This used to be commit 9ef9d4c4e77523d7f3cc5fdac199559896e585bd)
2008-03-26net_conf: add casts to avoid compiler warnings.Michael Adam1-6/+6
Michael (This used to be commit 1c6b9a0ac34c4a7b4e000300db8dffdbb09fe7da)
2008-03-26net_conf: rename "ctx" to "mem_ctx" for clarity.Michael Adam1-22/+22
There are also smbconf contexts arount... Michael (This used to be commit 5171df66eb54c9819b3b40045755f5e9b2cf36c2)
2008-03-26net_conf: use talloc_stackframe() instead of talloc_init().Michael Adam1-5/+5
Michael (This used to be commit ab4fd03705c61114742d8438dece69b9c37c3b38)
2008-03-26net_conf: fix import function by using the new text backend of smbconf.Michael Adam1-195/+59
Originally, lp_load() was used to import files to registry. This had several bugs. Most notably, options explicitly set to default values were silently dropped, and all parametric options were ignored. This new implementation reads config from the text backend and stuffs everything verbatim in to the registry backend. Michael (This used to be commit e41c6650f805eaf8bb009e34468dd2d311e52858)
2008-03-21libsmbconf: add a "path" variable to the conf context.Michael Adam1-1/+1
This is passed to the module init routines. In case of the registry, this is the path of the basekey in registry, that is to be used, defaulting to KEY_SMBCONF (HKLM\software\samba\smbconf), when NULL is given. This is the only case currently used. In order to support other keys, registry initialization for smbconf has to be changed to support different keys. Michael (This used to be commit 96434d9dc7a66773e313cc128af57493dee245a1)
2008-03-21libsmbconf: add backend specific init function.Michael Adam1-1/+1
Hide generic init function taking smbconf_ops argument from public api. Michael (This used to be commit b3f6920ccb9a27fde26e889a7f1f3afaf56b784f)
2008-03-21libsmbconf: rename smbconf_close() to smbconf_shutdown().Michael Adam1-1/+1
Michael (This used to be commit 797b26ad3fad27e085827efb61f6b4d8b37e93f0)
2008-03-21libsmbconf: rename smbconf_open() to smbconf_init().Michael Adam1-1/+1
That's more appropriate. Michael (This used to be commit d7bd9bb8aa2003ec0a9860df26857f67255febe2)
2008-03-21libsmbconf: change the API to always take the smbconf_ctx parameter first.Michael Adam1-4/+4
..for consistency. Exception: the open/init function, where the smbconf_ctx is created from the given talloc context. Michael (This used to be commit 304dba6cb2184437f3edad065a530d03fb704036)
2008-03-17libsmbconf: rename all occurrences of libnet_conf_ to smbconf_ .Michael Adam1-48/+46
Michael (This used to be commit 097af0309d7c3e9342058ba5266667293b23c80d)
2008-01-13Add and modify comments in net_conf.cMichael Adam1-8/+42
Michael (This used to be commit b3afc8391d40745328172ba012f0ffc166d75aa9)
2008-01-13Add explicit creation of shares to net conf import function.Michael Adam1-0/+4
It has been removed from libnet_conf_set_parameter(). Michael (This used to be commit b5c533b06cba9a8ffd28a1fb3bc56ab248340775)
2008-01-13Introduce a libnet_conf context created by libnet_conf_open().Michael Adam1-35/+106
The libnet_conf_ctx stores the information necessary to interoperate with the configuration. It is created by calling libnet_conf_open() and destroyed by calling libnet_conf_close(). The context is passed to all the libnet_conf functions. It currently stores the token to access the registry. Later, it could store more data, e.g. the server to connect to, credentials, and so on. For support of other backends than registry or support of remote configuration, only the open function will have to be changed. In net_conf, the calls to the actual net_conf functions is wrapped into a function that calls libnet_conf_open()/_close(). Thus an individual variant of net_conf_runfunction2() and functable2 is used to cope with functions being called by the wrapper with the additional libnet_conf_ctx argument. Michael (This used to be commit c2a9346faa26e79af5948197a1b322e545f0ed09)
2008-01-04Fix spacing - spaces mixed with tabs.Michael Adam1-8/+8
Michael (This used to be commit a4ef828102417f04af1e9823c89404e77e4fd5c1)
2008-01-04Fix a comment.Michael Adam1-1/+1
Michael (This used to be commit fc9c3f39b5af55026f1e5e964857c203cf6c9316)
2008-01-04Remove the word "registry" from the help output of the "net conf" command.Michael Adam1-7/+6
Michael (This used to be commit 8d9e3e08f3cc6a1f54661d1e54a3902ad50be191)
2008-01-04Update the introductory comment to net_conf.c to mention linbet_conf.Michael Adam1-3/+7
Michael (This used to be commit e166b886375b450534c894676ab1f64571dd46b8)
2008-01-04Remove the final regdb_close() from net_conf.cMichael Adam1-2/+0
This is to hide the registry from net_conf. Right now, it does not harm if "net conf" does not close the registry file explicitly just before exiting. I am working out a proper way of handling open/close operations transparently in the libnet_conf library. Michael (This used to be commit 790ef789444945fbae5637f0b469665859171dcd)
2008-01-04Fix the behaviour of "net conf setparm" to create the share if necessary.Michael Adam1-0/+9
This moves functionality taken away from libnet_conf_set_parameter() to the higher level user frontend function. (Somehow I thought I had done this already ... :-) Michael (This used to be commit fc0fca980f08a0af65d82784ef5a50a7b1ac0927)
2008-01-04Fix build warning.Günther Deschner1-1/+0
Guenther (This used to be commit a43125d9e9052fab8eb561976f45d1db4622482e)
2008-01-03Make libnet_conf handle opening/initialization of the registry.Michael Adam1-5/+0
Open state is currently tracked by a global variable to avoid double initialization. Later, this can possibly be replaced by a conf-context created by an initialization function and passed around to the other api functions. Michael (This used to be commit 77713e776405800ac54c692a77cd4efd153042cb)
2008-01-03Rename libnet_smbconf_delparm() to libnet_conf_delete_parameter().Michael Adam1-1/+1
Michael (This used to be commit 073eeca51e46da6a687175aadbfdbb9e029532d6)
2008-01-03Rename libnet_smbconf_getparm() to libnet_conf_get_parameter().Michael Adam1-1/+1
Michael (This used to be commit d08556dbc7071933feaeec538f01ac8f6a637b1d)
2008-01-03Rename libnet_smbconf_setparm() to libnet_conf_set_parameter().Michael Adam1-8/+8
Michael (This used to be commit e00cb415d30b3e72ccfb7e5c366c95ec0f9c6247)
2008-01-03Rename libnet_smbconf_delshare() to libnet_conf_delete_share().Michael Adam1-2/+2
Michael (This used to be commit 2075baf551ca7fc6bcee6b93f63fd7fbf75f9a50)
2008-01-03Rename libnet_smbconf_getshare() to libnet_conf_get_share().Michael Adam1-2/+2
Michael (This used to be commit 1575612f1936312125e7778a9a4227e444ea36cf)
2008-01-03Rename libnet_smbconf_create_share() to libnet_conf_create_share().Michael Adam1-1/+1
Michael (This used to be commit 6bc4ee210855dbfbee9e86b59e90b08ecb3a9df9)
2008-01-03Rename libnet_smbconf_share_exists() to libnet_conf_share_exists().Michael Adam1-2/+2
Michael (This used to be commit 3258758e5c8dfc2c681e1285cb34aaacae697a55)
2008-01-03Rename libnet_smbconf_get_share_names() to libnet_conf_get_share_names().Michael Adam1-1/+1
Michael (This used to be commit 2e4beee66b3672c3259b312aca3d482598731119)
2008-01-03Rename libnet_smbconf_get_config() to libnet_conf_get_config().Michael Adam1-3/+3
Michael (This used to be commit e8f7c07699b5b93acd81b24bca908769f0b5e8d8)
2008-01-03Rename libnet_smbconf_drop() to libnet_conf_drop().Michael Adam1-1/+1
Michael (This used to be commit 42ae33a96228e916d7d530d844be6937a80d4fea)
2008-01-03Happy new year again.Michael Adam1-1/+1
Michael (This used to be commit e568f42e2146fa6510a86746581409450887ff16)
2008-01-03Add libnet_conf API function libnet_smbconf_create_share().Michael Adam1-1/+12
And make libnet_smbconf_setparm() return error if the share does not already exist. Adapt net_conf_addshare to this new situation. Michael (This used to be commit de349bd26db3341815f6d8f6c18a5ca1fd664dca)
2007-12-31Make grouping in if statement more explicit.Michael Adam1-1/+3
Michael (This used to be commit a1bb47695a7fb21af239aa9d02537d3de2fea325)
2007-12-31Change net_conf_import() to only use libnet_conf API functions.Michael Adam1-9/+3
More precisely, only import_process_service() is changed. This removes all references to registry code from net_conf.c. net_conf_import() is currently -- like net_conf_addshare() -- also considered a high-level add-on, not an API function. Michael (This used to be commit b4dca117c09ddb9c8e7eea25c6cde3fbef8c692b)
2007-12-31Rewrite net_conf_addshare() to only use libnet_conf API functions.Michael Adam1-20/+17
Also exit on error if the share already exists. net_conf_addshare() is considered a high level utility function. It should not be an libnet_conf API function in itself since it is kind of arbitrary. Michael (This used to be commit af5218f1505321236be52df10ebfe8f42b99573d)
2007-12-31Rename libnet_smbconf_key_exists() to libnet_smbconf_share_exists()Michael Adam1-1/+1
and move it to the api section of libnet_conf.c Michael (This used to be commit 9b5d8f4d95ebfd47831906019e11227aecc83aa1)
2007-12-30Remove an unused variable.Michael Adam1-1/+0
Michael (This used to be commit 332be113a775adce8108a8003682019ae7f5bc21)