--- /dev/null
+/*
+ * Unix SMB/CIFS implementation.
+ * Utility functions for reparse points.
+ *
+ * Copyright (C) Jeremy Allison 2018
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "includes.h"
+#include "util_reparse.h"
+
+NTSTATUS fsctl_get_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ char **out_data,
+ uint32_t max_out_len,
+ uint32_t *out_len)
+{
+ DBG_DEBUG("Called on %s\n", fsp_fnum_dbg(fsp));
+ return NT_STATUS_NOT_A_REPARSE_POINT;
+}
+
+NTSTATUS fsctl_set_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ const uint8_t *in_data,
+ uint32_t in_len)
+{
+ DBG_DEBUG("Called on %s\n", fsp_fnum_dbg(fsp));
+ return NT_STATUS_NOT_A_REPARSE_POINT;
+}
+
+NTSTATUS fsctl_del_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ const uint8_t *in_data,
+ uint32_t in_len)
+{
+ DBG_DEBUG("Called on %s\n", fsp_fnum_dbg(fsp));
+ return NT_STATUS_NOT_A_REPARSE_POINT;
+}
--- /dev/null
+/*
+ * Unix SMB/CIFS implementation.
+ * Utility functions for reparse points.
+ *
+ * Copyright (C) Jeremy Allison 2018
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef __UTIL_REPARSE_H__
+#define __UTIL_REPARSE_H__
+
+NTSTATUS fsctl_get_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ char **out_data,
+ uint32_t max_out_len,
+ uint32_t *out_len);
+
+NTSTATUS fsctl_set_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ const uint8_t *in_data,
+ uint32_t in_len);
+
+NTSTATUS fsctl_del_reparse_point(struct files_struct *fsp,
+ TALLOC_CTX *ctx,
+ const uint8_t *in_data,
+ uint32_t in_len);
+
+#endif /* __UTIL_REPARSE_H__ */
#include "lib/pthreadpool/pthreadpool_tevent.h"
#include "librpc/gen_ndr/ndr_ioctl.h"
#include "offload_token.h"
+#include "util_reparse.h"
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_VFS
case FSCTL_GET_REPARSE_POINT:
{
- /* Fail it with STATUS_NOT_A_REPARSE_POINT */
- DEBUG(10, ("FSCTL_GET_REPARSE_POINT: called on %s. "
- "Status: NOT_IMPLEMENTED\n", fsp_fnum_dbg(fsp)));
- return NT_STATUS_NOT_A_REPARSE_POINT;
+ status = fsctl_get_reparse_point(
+ fsp, ctx, out_data, max_out_len, out_len);
+ return status;
}
case FSCTL_SET_REPARSE_POINT:
{
- /* Fail it with STATUS_NOT_A_REPARSE_POINT */
- DEBUG(10, ("FSCTL_SET_REPARSE_POINT: called on %s. "
- "Status: NOT_IMPLEMENTED\n", fsp_fnum_dbg(fsp)));
- return NT_STATUS_NOT_A_REPARSE_POINT;
+ status = fsctl_set_reparse_point(fsp, ctx, _in_data, in_len);
+ return status;
+ }
+
+ case FSCTL_DELETE_REPARSE_POINT:
+ {
+ status = fsctl_del_reparse_point(fsp, ctx, _in_data, in_len);
+ return status;
}
case FSCTL_GET_SHADOW_COPY_DATA:
source='offload_token.c',
deps='samba-util')
+bld.SAMBA3_SUBSYSTEM('UTIL_REPARSE',
+ source='util_reparse.c',
+ deps='samba-util')
+
bld.SAMBA3_SUBSYSTEM('HASH_INODE',
source='hash_inode.c',
deps='gnutls')
bld.SAMBA3_MODULE('vfs_default',
subsystem='vfs',
source='vfs_default.c',
- deps='samba-util NDR_DFSBLOBS OFFLOAD_TOKEN',
+ deps='samba-util NDR_DFSBLOBS OFFLOAD_TOKEN UTIL_REPARSE',
init_function='',
internal_module=bld.SAMBA3_IS_STATIC_MODULE('vfs_default'),
enabled=bld.SAMBA3_IS_ENABLED_MODULE('vfs_default'))