bool *self_referralp)
{
TALLOC_CTX *frame = talloc_stackframe();
+ const struct loadparm_substitution *lp_sub =
+ loadparm_s3_global_substitution();
struct conn_struct_tos *c = NULL;
struct connection_struct *conn = NULL;
char *targetpath = NULL;
}
}
- if (!lp_msdfs_root(snum) && (*lp_msdfs_proxy(talloc_tos(), snum) == '\0')) {
+ if (!lp_msdfs_root(snum) && (*lp_msdfs_proxy(talloc_tos(), lp_sub, snum) == '\0')) {
DEBUG(3,("get_referred_path: |%s| in dfs path %s is not "
"a dfs root.\n",
pdp->servicename, dfs_path));
struct referral *ref;
int refcount;
- if (*lp_msdfs_proxy(talloc_tos(), snum) == '\0') {
+ if (*lp_msdfs_proxy(talloc_tos(), lp_sub, snum) == '\0') {
TALLOC_FREE(frame);
return self_ref(ctx,
dfs_path,
*/
tmp = talloc_asprintf(frame, "msdfs:%s",
- lp_msdfs_proxy(frame, snum));
+ lp_msdfs_proxy(frame, lp_sub, snum));
if (tmp == NULL) {
TALLOC_FREE(frame);
return NT_STATUS_NO_MEMORY;
static int count_dfs_links(TALLOC_CTX *ctx, int snum)
{
TALLOC_CTX *frame = talloc_stackframe();
+ const struct loadparm_substitution *lp_sub =
+ loadparm_s3_global_substitution();
size_t cnt = 0;
DIR *dirp = NULL;
const char *dname = NULL;
char *talloced = NULL;
const char *connect_path = lp_path(frame, snum);
- const char *msdfs_proxy = lp_msdfs_proxy(frame, snum);
+ const char *msdfs_proxy = lp_msdfs_proxy(frame, lp_sub, snum);
struct conn_struct_tos *c = NULL;
connection_struct *conn = NULL;
NTSTATUS status;
size_t jn_remain)
{
TALLOC_CTX *frame = talloc_stackframe();
+ const struct loadparm_substitution *lp_sub =
+ loadparm_s3_global_substitution();
size_t cnt = 0;
DIR *dirp = NULL;
const char *dname = NULL;
char *talloced = NULL;
const char *connect_path = lp_path(frame, snum);
char *service_name = lp_servicename(frame, snum);
- const char *msdfs_proxy = lp_msdfs_proxy(frame, snum);
+ const char *msdfs_proxy = lp_msdfs_proxy(frame, lp_sub, snum);
struct conn_struct_tos *c = NULL;
connection_struct *conn = NULL;
struct referral *ref = NULL;
NTSTATUS *status)
{
struct smbd_server_connection *sconn = req->sconn;
+ const struct loadparm_substitution *lp_sub =
+ loadparm_s3_global_substitution();
uid_t euid;
struct user_struct *vuser = NULL;
char *service = NULL;
}
/* Handle non-Dfs clients attempting connections to msdfs proxy */
- if (lp_host_msdfs() && (*lp_msdfs_proxy(talloc_tos(), snum) != '\0')) {
+ if (lp_host_msdfs() && (*lp_msdfs_proxy(talloc_tos(), lp_sub, snum) != '\0')) {
DEBUG(3, ("refusing connection to dfs proxy share '%s' "
"(pointing to %s)\n",
- service, lp_msdfs_proxy(talloc_tos(), snum)));
+ service, lp_msdfs_proxy(talloc_tos(), lp_sub, snum)));
*status = NT_STATUS_BAD_NETWORK_NAME;
return NULL;
}
uint32_t *out_tree_id,
bool *disconnect)
{
+ const struct loadparm_substitution *lp_sub =
+ loadparm_s3_global_substitution();
struct smbXsrv_connection *conn = req->xconn;
const char *share = in_path;
char *service = NULL;
/* Handle non-DFS clients attempting connections to msdfs proxy */
if (lp_host_msdfs()) {
- char *proxy = lp_msdfs_proxy(talloc_tos(), snum);
+ char *proxy = lp_msdfs_proxy(talloc_tos(), lp_sub, snum);
if ((proxy != NULL) && (*proxy != '\0')) {
DBG_NOTICE("refusing connection to dfs proxy share "