From b338bce94f47780c74b2db3608a767c5b957b61a Mon Sep 17 00:00:00 2001 From: Samba Release Account Date: Sun, 7 Jul 1996 12:36:18 +0000 Subject: tidied up: code shuffling and documentation. created namedb*.c nameservresp.c nameservreply.c and namepacket.c added modules to Makefile, downloading dan's current version first :-) shuffled docs to match source created more docs fixed bug in announce_backup() discovered when going nameannounce.doc: backup list requests to the master browser should be used when samba is not a master browser; backup list requests to the primary domain controller should be used when samba is not a primary domain controller. fixed bug in sync_server: it would never send MasterAnnounce packets. removed the code that ignored special browser names: these should only be ignored (except 0x1b names) when broadcasted name queries are sent, not when directed registration or directed queries are sent samba as a WINS server. (note: exactly what's going on is still uncertain). renamed NAME_QUERY_MST_SRV_CHK to NAME_QUERY_PDC_SRV_CHK (more accurate). renamed NAME_STATUS_MST_SRV_CHK to NAME_STATUS_PDC_SRV_CHK (more accurate). added secured WINS name registration: a new 'state' NAME_REGISTER_CHALLENGE; functions send_name_response(), response_name_query_register(); added sending of WAIT ACKNOWLEDGEMENT packet; added a reply_to_ip field to the response record structure so that after the name query challenge, you know who to inform of the outcome of that challenge. note: these are all currently untested modifications (yikes!) lkcl (This used to be commit b50ff657ddc29b81b4aa02a597e5affab197e4f2) --- source3/namedbresp.doc | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 source3/namedbresp.doc (limited to 'source3/namedbresp.doc') diff --git a/source3/namedbresp.doc b/source3/namedbresp.doc new file mode 100644 index 0000000000..68db43aec2 --- /dev/null +++ b/source3/namedbresp.doc @@ -0,0 +1,48 @@ +module namedbresp deals with the maintenance of the list of expected +responses - creating, finding and removal. + +module nameresp deals with the initial transmission, re-transmission +and time-out of netbios response records. + + +/************************************************************************* + find_response_record() + *************************************************************************/ + +this function is responsible for matching the unique response transaction +id with an expected response record. as a side-effect of this search, +it will find the subnet (or the WINS pseudo-subnet) that samba expected +the response to come from. + + +/************************************************************************* + make_response_queue_record() + *************************************************************************/ + +this function is responsible for creating a response record, which will +be queued awaiting a response. + +the number of retries is set to 4, and the retry period set to 1 second. +if no response is received, then the packet is re-transmitted, which is +why so much information is stored in the response record. + +the number of expected responses queued is kept, so listen_for_packets() +knows it must time-out after 1 second if one or more responses are +expected. + + +/************************************************************************* + remove_response_record() + *************************************************************************/ + +this function is responsible for removing a response record from the +expected response queue. the number of expected responses is decreased. + + +/************************************************************************* + add_response_record() + *************************************************************************/ + +this function is responsible for adding the response record created by +make_response_queue_record() into the appropriate response record queue. + -- cgit