SMB_INO_T inode;
} DOS_ATTR_DESC;
+/*
+ * Extension of libsmbclient.h's #defines
+ */
+#define SMB_CTX_FLAG_USE_NT_HASH (1 << 4)
/*
* Internal flags for extended attributes
void
smbc_setOptionUseCCache(SMBCCTX *c, smbc_bool b);
+/** Get indication that the password supplied is the NT hash */
+smbc_bool
+smbc_getOptionUseNTHash(SMBCCTX *c);
+
+/** Set indication that the password supplied is the NT hash */
+void
+smbc_setOptionUseNTHash(SMBCCTX *c, smbc_bool b);
+
/*************************************
flags |= CLI_FULL_CONNECTION_USE_CCACHE;
}
+ if (smbc_getOptionUseNTHash(context)) {
+ flags |= CLI_FULL_CONNECTION_USE_NT_HASH;
+ }
+
if (share == NULL || *share == '\0' || is_ipc) {
/*
* Try 139 first for IPC$
}
}
+/** Get whether to enable use of the winbind ccache */
+smbc_bool
+smbc_getOptionUseNTHash(SMBCCTX *c)
+{
+ return (c->flags & SMB_CTX_FLAG_USE_NT_HASH) != 0;
+}
+
+/** Set indication that the password supplied is the NT hash */
+void
+smbc_setOptionUseNTHash(SMBCCTX *c, smbc_bool b)
+{
+ if (b) {
+ c->flags |= SMB_CTX_FLAG_USE_NT_HASH;
+ } else {
+ c->flags &= ~SMB_CTX_FLAG_USE_NT_HASH;
+ }
+}
+
/** Get the function for obtaining authentication data */
smbc_get_auth_data_fn
smbc_getFunctionAuthData(SMBCCTX *c)