1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

597 Commits

Author SHA1 Message Date
Andrew Bartlett
367c567c5f lib/util: Remove sys_poll as it is no longer needed
sys_poll() is only needed if the signal pipe is set up and used, but as
no signal handler ever writes to the pipe, this can all be removed.

signal based events are now handled via tevent.

Andrew Bartlett

Signed-off-by: Jeremy Allison <jra@samba.org>
2012-02-16 15:49:21 -08:00
Volker Lendecke
fed2fba0a9 s3: Move basic SMB checking to a much earlier point 2012-01-05 13:09:35 +01:00
Volker Lendecke
f7439f81be s3: Add a suicide mode to smbd
To test our cleanup code paths properly, we need a way to make smbd exit hard
without cleaning up
2012-01-05 13:09:35 +01:00
Volker Lendecke
69a67a1b73 s3: Check for the packet size before accessing it
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Jan  4 15:16:20 CET 2012 on sn-devel-104
2012-01-04 15:16:20 +01:00
Stefan Metzmacher
03455519e7 s3:smbd: pass smbd_server_connection and a snumused function pointer to reload_services()
metze
2011-12-15 11:11:24 +01:00
Stefan Metzmacher
e412b8bfcc s3:smbd: split smb_conf_updated into parent and child versions
metze
2011-12-15 11:03:00 +01:00
Stefan Metzmacher
715933a3d3 s3:smbd: split ID_CACHE_* message handling into parent and child parts
metze
2011-12-15 08:16:31 +01:00
Stefan Metzmacher
290ce331b6 s3:smbd: pass smbd_server_connection to smbd_setup_sig_hup_handler()
metze
2011-12-13 20:31:09 +01:00
Stefan Metzmacher
8a83464216 s3:smbd: pass smbd_server_connection to smbd_setup_sig_term_handler()
metze
2011-12-13 20:31:09 +01:00
Stefan Metzmacher
21de673575 s3:smbd/oplock: pass smbd_server_connection to init_oplocks()
metze
2011-12-13 20:31:09 +01:00
Stefan Metzmacher
e09c675596 s3:smbd/open: pass smbd_server_connection as private_data to msg_file_was_renamed()
metze
2011-12-13 12:36:35 +01:00
Stefan Metzmacher
173ea71686 s3:smbd: register MSG_SMB_FILE_RENAME after the fork
The parent smbd doesn't need to handle this, as it doesn't
have any file handles open.

metze
2011-12-13 12:36:35 +01:00
Stefan Metzmacher
d492a437be s3:smbd/conn_msg: pass smbd_server_connection as private_data to msg_force_tdis()
metze
2011-12-13 12:36:35 +01:00
Volker Lendecke
0f9d14820e s3: Remove a bunch of calls to procid_self()
All callers to messaging_[re]init only used procid_self()
2011-12-12 21:50:25 +01:00
Stefan Metzmacher
4d44f879e1 s3:smbd/clode: pass smbd_server_connection as private_data to msg_close_file()
metze
2011-12-12 20:14:41 +01:00
Stefan Metzmacher
bf8cce18c6 s3:smbd/process: avoid using server_event_context() for the forked echo handler
metze
2011-12-12 14:35:43 +01:00
Stefan Metzmacher
16cfc7243b s3:smbd/process: avoid using server_event_context() for smbd_deferred_open_timer events
metze
2011-12-12 14:35:43 +01:00
Stefan Metzmacher
0b8eeb1edc s3:smbd: pass down smbd_server_connection via smbd_echo_state
metze
2011-12-12 14:35:42 +01:00
Stefan Metzmacher
bf35606bbf s3:smbd: remove references to the global smbd_server_conn
metze
2011-12-12 14:35:42 +01:00
Stefan Metzmacher
6d84b24d76 s3:smbd: make struct pending_message_list private
metze
2011-12-12 14:35:42 +01:00
Stefan Metzmacher
8b2b7d1c87 s3:smbd: remember the smbd_server_connection on pending_message_list
metze
2011-12-12 14:35:42 +01:00
Stefan Metzmacher
3d7521c8ab s3:smbd: call sub_set_socket_ids() in smbd_process() again
This got lost in commit b2511a280a.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Mon Dec 12 10:23:44 CET 2011 on sn-devel-104
2011-12-12 10:23:43 +01:00
Volker Lendecke
5e0258fc93 s3: Avoid a race with the async echo handler
We can not read from the echo handler socket when we have the main socket
locked. This leads to the echo responder to lock up sitting in the fcntl lock
while the parent wants to read the remainder of a large packet.
2011-11-10 17:18:53 +01:00
Christian Ambach
b99becd4fa s3:smbd increase a debug level
logging disconnected clients with level 1 swamps the logs
2011-11-04 17:39:43 +01:00
Stefan Metzmacher
f205e4cada s3:smbd: echo FLAGS2_SMB_SECURITY_SIGNATURES* and the signature field in the reply
This matches what windows is doing.

metze
2011-09-14 08:09:15 +02:00
Volker Lendecke
d911bd5c69 s3: Remove a reference to smbd_server_conn 2011-09-13 11:00:13 +02:00
Volker Lendecke
7e70f85350 s3: Pass smbd_server_connection to srv_encrypt_buffer 2011-08-25 21:36:19 +02:00
Volker Lendecke
d4c4705e55 s3: Pass smbd_server_connection to srv_decrypt_buffer 2011-08-25 21:36:19 +02:00
Volker Lendecke
08262fe964 s3: Pass smbd_server_connection to srv_free_enc_buffer 2011-08-25 21:36:19 +02:00
Volker Lendecke
f9ef138ec7 s3: Pass smbd_server_connection to is_encrypted_packet 2011-08-25 21:36:19 +02:00
Volker Lendecke
b4b9918cc8 s3: Pass sconn to valid_smb_header 2011-08-25 21:36:19 +02:00
Volker Lendecke
1022c28e15 s3: Fix bug 8360
OS/2 sends an unexpected write&x/read&x chain

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sun Aug 14 08:48:58 CEST 2011 on sn-devel-104
2011-08-14 08:48:58 +02:00
Simo Sorce
0de09289ae s3-printing: Force pcap reload when all ready
This way we are sure the cache is primed properly and messages can be sent to
processes if necessary as all messaging has been set up.

Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-10 18:14:05 +02:00
Simo Sorce
05455b459a lib-util: Make useful function a common utility.
Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-10 18:14:02 +02:00
Andreas Schneider
dd3a927959 s3-smbd: Pass tevent context to smbd_server_connection_loop_once().
Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-09 10:41:47 +02:00
Volker Lendecke
d20e968cff s3: Move deferred_open_queue to smbd_server_connection 2011-08-02 19:18:09 +02:00
Volker Lendecke
cb69d105f5 s3: Pass sconn explicitly to get_deferred_open_message_smb 2011-08-02 19:18:08 +02:00
Volker Lendecke
f9d183f931 s3: Pass sconn explicitly to open_was_deferred 2011-08-02 19:18:08 +02:00
Volker Lendecke
502fdae7f1 s3: Pass sconn explicitly to schedule_deferred_open_message_smb 2011-08-02 19:18:08 +02:00
Volker Lendecke
04253dfd9f s3: Explicitly pass sconn to remove_deferred_open_message_smb 2011-08-02 19:18:08 +02:00
Simo Sorce
2e8a85ec72 s3:smbd - Move printing queue stuff
This way we can properly deal with pcap updates in the background queue process
if it is enabled (on by default) and not perform these actions in the main
smbd process.

Signed-off-by: Günther Deschner <gd@samba.org>
2011-08-02 15:28:03 +02:00
Volker Lendecke
5812645f49 s3: Priorize the async echo responder over the client
Without this, an active client connection can starve the echo responder. This
leads to apparently "lost" SMBs.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Thu Jul 28 18:53:38 CEST 2011 on sn-devel-104
2011-07-28 18:53:38 +02:00
Volker Lendecke
4dd0a3b5e2 s3: Remove unused smbd_echo_reader() 2011-07-28 17:42:23 +02:00
Volker Lendecke
710e5d9256 s3: Use smbd_echo_read_send in the async echo handler 2011-07-28 17:42:23 +02:00
Volker Lendecke
27afb8910f s3: Add smbd_echo_read_send/recv
Read a SMB packet in the echo responder, giving the parent one second to step
in
2011-07-28 17:42:23 +02:00
Andrew Bartlett
128ae06a61 s3-auth use auth_user_info not netr_SamInfo3 in auth3_session_info
This makes auth3_session_info identical to auth_session_info

The logic to convert the info3 to a struct auth_user_info is
essentially moved up the stack from the named pipe proxy in
source3/rpc_server to create_local_token().

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20 09:17:13 +10:00
Andrew Bartlett
9289537993 s3-auth Use struct auth_user_info_unix for unix_name and sanitized_username
This is closer to the layout of struct auth_session_info in auth.idl

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20 09:17:11 +10:00
Stefan Metzmacher
0633c0f600 s3:smbd: s/SMBkeepalive/NBSSkeepalive
metze
2011-07-12 09:44:04 +02:00
Stefan Metzmacher
aca920b27c s3:smbd: use PROTOCOL_SMB2_02 instead PROTOCOL_SMB2
metze
2011-07-12 08:18:00 +02:00
Jeremy Allison
8dc7029561 Fix bug #8293 - SMB2 doesn't rotate the log files often enough.
Move the num_requests field out of the smb1 struct into the generic
struct smbd_server_connection struct. Use it to count SMB2 requests
as well as SMB1 and ensure that check_log_size() is called every 50
SMB2 requests.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Jul  8 01:14:53 CEST 2011 on sn-devel-104
2011-07-08 01:14:53 +02:00