summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2021-02-04 22:02:54 +0100
committerGünther Deschner <gd@samba.org>2021-07-14 16:49:30 +0000
commit8bf2a3f9c0b7798466b90aaa497082f794986584 (patch)
tree7192db32903649f6aa3f72bf1bb3f35a02dd6397 /source3
parent3f71d1fa1c011d04636897852768c209793df4d9 (diff)
downloadsamba-8bf2a3f9c0b7798466b90aaa497082f794986584.tar.gz
s3-libnetapi: add NetProvisionComputerAccount to api.
Guenther Signed-off-by: Guenther Deschner <gd@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/lib/netapi/netapi.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/source3/lib/netapi/netapi.h b/source3/lib/netapi/netapi.h
index 6c0358ef51d..96b136f7bdb 100644
--- a/source3/lib/netapi/netapi.h
+++ b/source3/lib/netapi/netapi.h
@@ -98,6 +98,13 @@ struct DOMAIN_CONTROLLER_INFO {
#define NETSETUP_INSTALL_INVOCATION ( 0x00040000 )
#define NETSETUP_IGNORE_UNSUPPORTED_FLAGS ( 0x10000000 )
+/* bitmap NetProvisionFlags */
+#define NETSETUP_PROVISION_DOWNLEVEL_PRIV_SUPPORT ( 0x00000001 )
+#define NETSETUP_PROVISION_REUSE_ACCOUNT ( 0x00000002 )
+#define NETSETUP_PROVISION_USE_DEFAULT_PASSWORD ( 0x00000004 )
+#define NETSETUP_PROVISION_SKIP_ACCOUNT_SEARCH ( 0x00000008 )
+#define NETSETUP_PROVISION_ROOT_CA_CERTS ( 0x00000010 )
+
#define FILTER_TEMP_DUPLICATE_ACCOUNT ( 0x0001 )
#define FILTER_NORMAL_ACCOUNT ( 0x0002 )
#define FILTER_INTERDOMAIN_TRUST_ACCOUNT ( 0x0008 )
@@ -1615,6 +1622,35 @@ NET_API_STATUS NetRenameMachineInDomain(const char * server_name /* [in] */,
/************************************************************//**
*
+ * NetProvisionComputerAccount
+ *
+ * @brief Provision a machine for offline join
+ *
+ * @param[in] domain The domain to provision for
+ * @param[in] machine_name The machine account name
+ * @param[in] machine_account_ou The machine account ou to create the account in
+ * @param[in] dcname A specific domain controller to use for account creation
+ * @param[in] options The options used for account creation
+ * @param[in,out] provision_bin_data The generated binary buffer
+ * @param[in,out] provision_bin_data_size The generated binary buffer size
+ * @param[in,out] provision_text_data The generated text data blob
+ * @return NET_API_STATUS
+ *
+ * example join/provision_computer_account.c
+ *
+ ***************************************************************/
+
+NET_API_STATUS NetProvisionComputerAccount(const char * domain /* [in] [ref] */,
+ const char * machine_name /* [in] [ref] */,
+ const char * machine_account_ou /* [in] [unique] */,
+ const char * dcname /* [in] [unique] */,
+ uint32_t options /* [in] */,
+ uint8_t **provision_bin_data /* [in,out] [unique] */,
+ uint32_t *provision_bin_data_size /* [in,out] [unique] */,
+ const char * *provision_text_data /* [in,out] [unique] */);
+
+/************************************************************//**
+ *
* NetServerGetInfo
*
* @brief Get Information on a server