netapi: Add dummy implementation of NetGroupSetInfo().
authorGünther Deschner <gd@samba.org>
Mon, 2 Jun 2008 10:54:17 +0000 (12:54 +0200)
committerGünther Deschner <gd@samba.org>
Mon, 2 Jun 2008 23:27:42 +0000 (01:27 +0200)
Guenther
(This used to be commit 7e47bdc0829d7ac856028a99389310f721a265ce)

source3/lib/netapi/group.c
source3/lib/netapi/libnetapi.c
source3/lib/netapi/libnetapi.h
source3/lib/netapi/netapi.h

index b47e099ce6e3c9f35351431fdce3dbe35fc433e4..7eb6d7c840f0be1723bc992b72259e59a378171f 100644 (file)
@@ -494,3 +494,21 @@ WERROR NetGroupDel_l(struct libnetapi_ctx *ctx,
 {
        return NetGroupDel_r(ctx, r);
 }
+
+/****************************************************************
+****************************************************************/
+
+WERROR NetGroupSetInfo_r(struct libnetapi_ctx *ctx,
+                        struct NetGroupSetInfo *r)
+{
+       return WERR_NOT_SUPPORTED;
+}
+
+/****************************************************************
+****************************************************************/
+
+WERROR NetGroupSetInfo_l(struct libnetapi_ctx *ctx,
+                        struct NetGroupSetInfo *r)
+{
+       return WERR_NOT_SUPPORTED;
+}
index 75087e8b294974224e24d7608e291ad82c4583ff..0e1d1b30a587f1f0e5fb85e963c40b2111dd3448 100644 (file)
@@ -725,3 +725,51 @@ NET_API_STATUS NetGroupDel(const char * server_name /* [in] */,
        return r.out.result;
 }
 
+/****************************************************************
+ NetGroupSetInfo
+****************************************************************/
+
+NET_API_STATUS NetGroupSetInfo(const char * server_name /* [in] */,
+                              const char * group_name /* [in] */,
+                              uint32_t level /* [in] */,
+                              uint8_t *buf /* [in] [ref] */,
+                              uint32_t *parm_err /* [out] [ref] */)
+{
+       struct NetGroupSetInfo r;
+       struct libnetapi_ctx *ctx = NULL;
+       NET_API_STATUS status;
+       WERROR werr;
+
+       status = libnetapi_getctx(&ctx);
+       if (status != 0) {
+               return status;
+       }
+
+       /* In parameters */
+       r.in.server_name = server_name;
+       r.in.group_name = group_name;
+       r.in.level = level;
+       r.in.buf = buf;
+
+       /* Out parameters */
+       r.out.parm_err = parm_err;
+
+       if (DEBUGLEVEL >= 10) {
+               NDR_PRINT_IN_DEBUG(NetGroupSetInfo, &r);
+       }
+
+       if (LIBNETAPI_LOCAL_SERVER(server_name)) {
+               werr = NetGroupSetInfo_l(ctx, &r);
+       } else {
+               werr = NetGroupSetInfo_r(ctx, &r);
+       }
+
+       r.out.result = W_ERROR_V(werr);
+
+       if (DEBUGLEVEL >= 10) {
+               NDR_PRINT_OUT_DEBUG(NetGroupSetInfo, &r);
+       }
+
+       return r.out.result;
+}
+
index 93029ab4f32f6d8c8d0316b8db87df49049460ae..9a7bbd19537b97cd673486ba4e6313899927a5bb 100644 (file)
@@ -125,4 +125,13 @@ WERROR NetGroupDel_r(struct libnetapi_ctx *ctx,
                     struct NetGroupDel *r);
 WERROR NetGroupDel_l(struct libnetapi_ctx *ctx,
                     struct NetGroupDel *r);
+NET_API_STATUS NetGroupSetInfo(const char * server_name /* [in] */,
+                              const char * group_name /* [in] */,
+                              uint32_t level /* [in] */,
+                              uint8_t *buf /* [in] [ref] */,
+                              uint32_t *parm_err /* [out] [ref] */);
+WERROR NetGroupSetInfo_r(struct libnetapi_ctx *ctx,
+                        struct NetGroupSetInfo *r);
+WERROR NetGroupSetInfo_l(struct libnetapi_ctx *ctx,
+                        struct NetGroupSetInfo *r);
 #endif /* __LIBNETAPI_LIBNETAPI__ */
index abfd53e0c9034f5debf255212f6f751a1dea51ff..bd4dc090798eea9b7f683679cc345101547a019a 100644 (file)
@@ -136,6 +136,14 @@ struct GROUP_INFO_3 {
        uint32_t grpi3_attributes;
 };
 
+struct GROUP_INFO_1002 {
+       const char * grpi1002_comment;
+};
+
+struct GROUP_INFO_1005 {
+       uint32_t grpi1005_attributes;
+};
+
 #endif /* _HEADER_libnetapi */
 
 /****************************************************************
@@ -526,8 +534,28 @@ NET_API_STATUS NetGroupAdd(const char * server_name /* [in] */,
  * example group/group_del.c
  ***************************************************************/
 
-
 NET_API_STATUS NetGroupDel(const char * server_name /* [in] */,
                           const char * group_name /* [in] */);
 
+/************************************************************//**
+ *
+ * NetGroupSetInfo
+ *
+ * @brief Set Domain Group Information
+ *
+ * @param[in] server_name The server name to connect to
+ * @param[in] group_name The name of the group that is going to be modified
+ * @param[in] level The level defining the structure type in buf
+ * @param[in] buf The buffer containing a GROUP_INFO_X structure
+ * @param[out] parm_err The returned parameter error number if any
+ * @return NET_API_STATUS
+ *
+ * example group/group_setinfo.c
+ ***************************************************************/
+
+NET_API_STATUS NetGroupSetInfo(const char * server_name /* [in] */,
+                              const char * group_name /* [in] */,
+                              uint32_t level /* [in] */,
+                              uint8_t *buf /* [in] [ref] */,
+                              uint32_t *parm_err /* [out] [ref] */);
 #endif