struct smbsrv_session *sess = NULL;
int i;
- /* Ensure no vuid gets registered in share level security. */
- if (smb_conn->config.security == SEC_SHARE) return NULL;
-
sess = talloc_zero(mem_ctx, struct smbsrv_session);
if (!sess) return NULL;
sess->smb_conn = smb_conn;
req->smb_conn->negotiate.encrypted_passwords = lpcfg_encrypted_passwords(req->smb_conn->lp_ctx);
- if (lpcfg_security(req->smb_conn->lp_ctx) != SEC_SHARE)
- secword |= NEGOTIATE_SECURITY_USER_LEVEL;
-
if (req->smb_conn->negotiate.encrypted_passwords)
secword |= NEGOTIATE_SECURITY_CHALLENGE_RESPONSE;
req->smb_conn->negotiate.encrypted_passwords = lpcfg_encrypted_passwords(req->smb_conn->lp_ctx);
- if (lpcfg_security(req->smb_conn->lp_ctx) != SEC_SHARE)
- secword |= NEGOTIATE_SECURITY_USER_LEVEL;
-
if (req->smb_conn->negotiate.encrypted_passwords)
secword |= NEGOTIATE_SECURITY_CHALLENGE_RESPONSE;
supports it and we can do encrypted passwords */
if (req->smb_conn->negotiate.encrypted_passwords &&
- (lpcfg_security(req->smb_conn->lp_ctx) != SEC_SHARE) &&
lpcfg_use_spnego(req->smb_conn->lp_ctx) &&
(req->flags2 & FLAGS2_EXTENDED_SECURITY)) {
negotiate_spnego = true;
capabilities |= CAP_DFS;
}
- if (lpcfg_security(req->smb_conn->lp_ctx) != SEC_SHARE) {
- secword |= NEGOTIATE_SECURITY_USER_LEVEL;
- }
+ secword |= NEGOTIATE_SECURITY_USER_LEVEL;
if (req->smb_conn->negotiate.encrypted_passwords) {
secword |= NEGOTIATE_SECURITY_CHALLENGE_RESPONSE;
hasn't already been initialised (to cope with SMB
chaining) */
- /* In share mode security we must ignore the vuid. */
- if (smb_conn->config.security == SEC_SHARE) {
- if (req->tcon) {
- req->session = req->tcon->sec_share.session;
- }
- } else {
- req->session = smbsrv_session_find(req->smb_conn, SVAL(req->in.hdr,HDR_UID), req->request_time);
- }
+ req->session = smbsrv_session_find(req->smb_conn, SVAL(req->in.hdr,HDR_UID), req->request_time);
}
task_id = server_id_str(NULL, &req->smb_conn->connection->server_id);
smb_conn->negotiate.zone_offset = get_time_zone(time(NULL));
- smb_conn->config.security = lpcfg_security(lp_ctx);
smb_conn->config.nt_status_support = lpcfg_nt_status_support(lp_ctx);
status = smbsrv_init_sessions(smb_conn, UINT16_MAX);
smb_conn->negotiate.zone_offset = get_time_zone(time(NULL));
- smb_conn->config.security = SEC_USER;
smb_conn->config.nt_status_support = true;
status = smbsrv_init_sessions(smb_conn, UINT64_MAX);
/* configuration parameters */
struct {
- enum security_types security;
bool nt_status_support;
} config;