int space_remaining,
bool *got_exact_match,
int *_last_entry_off,
- struct ea_list *name_list);
+ struct ea_list *name_list,
+ struct file_id *file_id);
NTSTATUS smbd_calculate_access_mask(connection_struct *conn,
const struct smb_filename *smb_fname,
const char *smb2_opcode_name(uint16_t opcode);
bool smbd_is_smb2_header(const uint8_t *inbuf, size_t size);
+bool smbd_smb2_is_compound(const struct smbd_smb2_request *req);
NTSTATUS smbd_add_connection(struct smbXsrv_client *client, int sock_fd,
struct smbXsrv_connection **_xconn);
NTSTATUS smbd_smb2_request_verify_sizes(struct smbd_smb2_request *req,
size_t expected_body_size);
+void smb2_request_set_async_internal(struct smbd_smb2_request *req,
+ bool async_internal);
+
enum protocol_types smbd_smb2_protocol_dialect_match(const uint8_t *indyn,
const int dialect_count,
uint16_t *dialect);
NTSTATUS smbXsrv_connection_init_tables(struct smbXsrv_connection *conn,
enum protocol_types protocol);
-NTSTATUS smbXsrv_session_global_init(void);
+NTSTATUS smbXsrv_session_global_init(struct messaging_context *msg_ctx);
NTSTATUS smbXsrv_session_create(struct smbXsrv_connection *conn,
NTTIME now,
struct smbXsrv_session **_session);
struct tevent_timer *async_te;
bool compound_related;
+ /*
+ * Give the implementation of an SMB2 req a way to tell the SMB2 request
+ * processing engine that the internal request is going async, while
+ * preserving synchronous SMB2 behaviour.
+ */
+ bool async_internal;
+
/*
* the encryption key for the whole
* compound chain
struct smbXsrv_session *session;
};
+struct pthreadpool_tevent;
+
struct smbd_server_connection {
const struct tsocket_address *local_address;
const struct tsocket_address *remote_address;
const char *remote_hostname;
struct tevent_context *ev_ctx;
struct messaging_context *msg_ctx;
- struct sys_notify_context *sys_notify_ctx;
struct notify_context *notify_ctx;
bool using_smb2;
+ bool aapl_zero_file_id; /* Apple-specific */
int trans_num;
size_t num_users;
} locks;
} smb2;
- /*
- * Link into libasys for asynchronous operations
- */
- struct asys_context *asys_ctx;
- struct tevent_fd *asys_fde;
+ struct pthreadpool_tevent *pool;
struct smbXsrv_client *client;
};