Andreas Gustafsson
97f26b88f6
removed more needless attaching and detaching of the blackhole ACL
2001-02-09 00:23:16 +00:00
Andreas Gustafsson
8ed67113ec
there is no need for each dispatch to have a separate reference to
...
the blackhole list; they can use the blackhole list of the dispatch
manager directly. This eliminates some unsafe unlocked accesses to
the reference count of the blackhole list dns_acl_t object
2001-02-08 18:25:09 +00:00
Brian Wellington
e618d503ba
Remove (now unused) code for handling queries.
2001-02-07 05:11:58 +00:00
Brian Wellington
98c80a3456
do_next_response() was unlinking an event from the wrong list
2001-02-07 03:01:19 +00:00
Andreas Gustafsson
fc16063c23
removed dns_qid_t::mctx since it was never used
2001-01-31 22:16:37 +00:00
Andreas Gustafsson
c17c59662f
720. [bug] Server could enter infinite loop in
...
dispatch.c:do_cancel(). [RT #743 ]
2001-01-31 17:21:11 +00:00
Brian Wellington
35f06ab0e6
Clients now listen on sockets instead of accepting queries from dispatchers.
...
When a socket is shared by clients and query-source, the client hands off
responses to the dispatcher.
2001-01-27 02:08:07 +00:00
Andreas Gustafsson
bc85580ff8
mask message id to 16 bits explicitly
2001-01-25 13:52:32 +00:00
Andreas Gustafsson
3530e10080
commented and removed dead code
2001-01-25 13:47:59 +00:00
Brian Wellington
c6c1846361
oops, missed a function declaration
2001-01-25 00:44:29 +00:00
Brian Wellington
038a3e6bfe
use dns_messageid_t instead of isc_uint32_t in a few places. [RT #703 ]
2001-01-25 00:42:31 +00:00
Brian Wellington
f98d6edb19
Multiple outstanding requests don't actually help. Never have more than 1.
2001-01-13 01:33:27 +00:00
Brian Wellington
499b34cea0
copyright update
2001-01-09 22:01:04 +00:00
Andreas Gustafsson
13b53c2971
when code is duplicated (which it shoudn't be), it should
...
at least be duplicated consistently
2001-01-07 22:02:48 +00:00
Brian Wellington
02e3821450
635. [bug] Reloading a server with a configured blackhole list
...
would cause an assertion. [RT #590 ]
2000-12-26 09:48:41 +00:00
Andreas Gustafsson
0bca614506
don't shout
2000-12-20 19:46:37 +00:00
Mark Andrews
6fda157766
ISC_LINK_*UNSAFE -> ISC_LINK_INITAND*
2000-12-07 20:15:58 +00:00
Andreas Gustafsson
97a195d7ff
spacing; incorrect comment
2000-11-10 03:08:57 +00:00
Brian Wellington
ce10da9983
A call to isc_mempool_get() was unchecked, which could lead to a seg fault.
2000-11-03 19:55:15 +00:00
Brian Wellington
e21d199dca
539. [func] Support the blackhole option.
2000-11-03 02:45:55 +00:00
Mark Andrews
5e589b5356
Uninitalised link fixes, batch 1.
2000-10-20 02:21:58 +00:00
Brian Wellington
3a62e221b4
locks weren't being destroyed
2000-09-26 22:09:20 +00:00
Mark Andrews
8affb49a70
Move the UDP buffer pool to the dispatchmgr. UDP parameters are now set
...
by the first call to dns_dispatch_getudp(), subsecquent calls can raise
the maximum number of buffers. dns_dispatchmgr_setudp() could be made
public.
Tidy dispatch_allocate().
entropy and mctx are now gone from dns_qid_t.
2000-09-19 06:59:28 +00:00
Mark Andrews
a7c76f1924
469. [bug] "query-source address * port 53;" now works.
2000-09-18 04:50:05 +00:00
Andreas Gustafsson
00010dc6a4
TCP receives should never be retried
2000-09-08 22:02:21 +00:00
Michael Graff
d2439ad5af
log message about strange socket error at ISC_LOG_ERROR level
2000-09-07 01:53:31 +00:00
Andreas Gustafsson
f38a84ce83
418. [bug] At debug levels >= 10, getting an unexpected
...
socket receive error would crash the server
while trying to log the error message.
2000-09-01 22:41:46 +00:00
Michael Graff
ca0db0cdc8
stop mumbling in dispatch.h by filling out the comments. Fixed a bug, since I was here already.
2000-09-01 07:16:06 +00:00
Brian Wellington
5e387b9ce6
and more calls to DESTROYLOCK
2000-08-26 01:37:00 +00:00
Andreas Gustafsson
ec46482ef3
dispatch log messages had request/response backwards
2000-08-24 16:56:48 +00:00
David Lawrence
40f53fa8d9
Trailing whitespace trimmed. Perhaps running "perl util/spacewhack.pl in your
...
own CVS tree will help minimize CVS conflicts. Maybe not.
Blame Graff for getting me to trim all trailing whitespace.
2000-08-01 01:33:37 +00:00
David Lawrence
15a4474541
word wrap copyright notice at column 70
2000-07-27 09:55:03 +00:00
Brian Wellington
f6579931b3
Added calls to isc_log_wouldlog() in additional logging functions.
2000-07-17 23:25:35 +00:00
Andreas Gustafsson
9317787889
use isc_log_wouldlog()
2000-07-13 01:16:22 +00:00
David Lawrence
24675e8e13
In dns_dispatch_createtcp(), REQUIRE() that attributes not include
...
DNS_DISPATCHATTR_UDP, and document that requirement as well as the
existing requirement for needing DNS_DISPATCHATTR_TCP.
No need to pull up.
2000-07-04 01:48:13 +00:00
David Lawrence
9c3531d72a
add RCS id string
2000-06-22 22:00:42 +00:00
Michael Graff
8e7e1ef75b
let the entropy source seed the pseudorandom source from _very_ bad sources like the time and the pid. Update the dispatcher to always expect success in these cases.
2000-06-21 22:12:23 +00:00
Michael Graff
80617c8faa
Add using an entropy source to generate a random query ID seed value.
2000-06-21 21:34:43 +00:00
Mark Andrews
3c671ac666
264. [func] Dispatch can not take TCP sockets in connecting
...
state. Set DNS_DISPATCHATTR_CONNECTED when calling
dns_dispatch_createtcp() for connected TCP sockets
or call dns_dispatch_starttcp() when the socket is
connected.
2000-06-20 23:52:54 +00:00
Michael Graff
8470db5b12
clean up ; remove unneeded function arguments
2000-06-20 17:24:47 +00:00
Andreas Gustafsson
8ed2c82a73
do not use initial caps in log messages
2000-06-16 15:51:58 +00:00
Michael Graff
ce5bd92088
Store our own version of what type of socket we had, so we can clean up even after the socket is detached.
2000-06-16 00:52:05 +00:00
Andreas Gustafsson
11a91ac55e
call isc_task_setname() on the dispatch tasks
2000-06-01 22:00:09 +00:00
David Lawrence
cf479fdc6b
removed unused static function violate_locking_hierarchy
2000-05-24 02:41:03 +00:00
Michael Graff
46993e1d9d
Merge the mlg-20000518 branch onto the mainline. Change summary:
...
dns_dispatch_create() no longer exists. dns_dispatch_createtcp()
and dns_dispatch_getudp() are the replacements. _createtcp() takes
a bound, connected TCP socket, while _getudp() will search for
a sharable UDP socket, and if found, attach to it and return a
pointer to it. If one is not found, it will create a udp socket,
bind it to a supplied local address, and create a new dispatcher
around it.
dns_dispatch_remove{request,response}() no longer take the dispatch
as an argument.
query-source can now be set per view.
The dispatch manager holds onto three memory pools, one for
allocating dispatchers from, one for events, and one for
requests/replies. The free list on these pools is hard-coded,
but set to 1024. This keeps us from having to dig into the
isc_mem_t the pools draw from as often.
dns_resolver_create() and dns_view_createresolver() require that
valid dispatchers be passed in; dispatchers are no longer created
for the caller.
2000-05-19 21:46:46 +00:00
Andreas Gustafsson
bbf6673828
use isc_sockaddr_format() instead of a static function doing
...
the same thing
2000-05-14 20:52:35 +00:00
David Lawrence
3d181bc9f1
needs string.h for memset() prototype.
2000-05-13 21:57:02 +00:00
Michael Graff
b9c8f4378a
Add address searching to dns_disptach_find().
2000-05-11 07:33:17 +00:00
Michael Graff
ca9739800f
implement dns_dispatchmgr_t, replacing dns_dispatchlist_t. Use it throughout the library/server.
2000-05-10 21:34:50 +00:00
David Lawrence
1a69a1a78c
Megacommit of dozens of files.
...
Cleanup of redundant/useless header file inclusion.
ISC style lint, primarily for function declarations and standalone
comments -- ie, those that appear on a line without any code, which
should be written as follows:
/*
* This is a comment.
*/
2000-05-08 14:38:29 +00:00
Michael Graff
f6407f9a0b
add print.h and string.h to files that need them
2000-05-02 16:36:22 +00:00
Michael Graff
20c266cbc9
add dispatcher logging functions
2000-04-29 00:45:26 +00:00
David Lawrence
32eddfc189
120. [cleanup] <isc/socket.h> does not need <isc/boolean.h>,
...
<isc/bufferlist.h>, <isc/task.h>, <isc/mem.h> or
<isc/net.h>.
2000-04-28 03:53:48 +00:00
David Lawrence
6e49e91bd0
103. [func] libisc buffer API changes for <isc/buffer.h>:
...
Added:
isc_buffer_base(b) (pointer)
isc_buffer_current(b) (pointer)
isc_buffer_active(b) (pointer)
isc_buffer_used(b) (pointer)
isc_buffer_length(b) (int)
isc_buffer_usedlength(b) (int)
isc_buffer_consumedlength(b) (int)
isc_buffer_remaininglength(b) (int)
isc_buffer_activelength(b) (int)
isc_buffer_availablelength(b) (int)
Removed:
ISC_BUFFER_USEDCOUNT(b)
ISC_BUFFER_AVAILABLECOUNT(b)
isc_buffer_type(b)
Changed names:
isc_buffer_used(b, r) ->
isc_buffer_usedregion(b, r)
isc_buffer_available(b, r) ->
isc_buffer_available_region(b, r)
isc_buffer_consumed(b, r) ->
isc_buffer_consumedregion(b, r)
isc_buffer_active(b, r) ->
isc_buffer_activeregion(b, r)
isc_buffer_remaining(b, r) ->
isc_buffer_remainingregion(b, r)
Buffer types were removed, so the ISC_BUFFERTYPE_*
macros are no more, and the type argument to
isc_buffer_init and isc_buffer_allocate were removed.
isc_buffer_putstr is now void (instead of isc_result_t)
and requires that the caller ensure that there
is enough available buffer space for the string.
2000-04-27 00:03:12 +00:00
Michael Graff
e44487bfc2
convert sender, arg, action, etc. to ev_sender, ev_arg, ev_action, etc.
2000-04-17 19:22:44 +00:00
Michael Graff
4195904998
s/DNS_R_/ISC_R_/ change for some codes.
2000-04-06 22:03:35 +00:00
Michael Graff
ae8d0aedd6
implement pktinfo through dispatcher -> named client
2000-03-14 03:30:52 +00:00
Bob Halley
7d32c065c7
update copyright
2000-02-03 23:50:32 +00:00
Bob Halley
6da50be436
add missing exit checks to udp_recv and tcp_recv
2000-02-02 23:29:47 +00:00
Michael Graff
0941f35ad9
Start moving the dispatcher code to allow it to be used for wire format as well as for lightweight resolver daemon stuff.
2000-01-07 01:17:47 +00:00
Michael Graff
04458c8b5d
fix a bug pointed out by Andreas -- don't detach from socket then use it.
2000-01-06 23:01:07 +00:00
Michael Graff
440be4c866
move util.h to <isc/util.h>
1999-12-16 22:24:22 +00:00
Michael Graff
b8ef99c3a7
make the lfsr's real lfsr's, and use two of them to generate random-looking IDs
1999-12-16 00:07:21 +00:00
Michael Graff
607dc8013a
make dispatcher hash sizes be primes, and provide an increment to help
...
resolve hash collisions
1999-12-15 17:14:52 +00:00
Michael Graff
0a9fedafec
Use an LFSR to generate unpredictable IDs.
1999-12-15 03:11:00 +00:00
Michael Graff
6149906644
ipv6 changes
1999-12-04 01:27:44 +00:00
Bob Halley
3cd4668988
In tcp_recv(), free the event before calling destroy(), since the event is
...
a statically allocated part of the tcpmsg.
1999-11-16 21:05:09 +00:00
Michael Graff
233f59d933
put names on memory pools
1999-10-22 05:18:35 +00:00
Bob Halley
6d58c9b95e
unsend
1999-10-07 19:38:39 +00:00
Bob Halley
271d5bfc5c
conforming changes for task API simplification
1999-09-23 21:31:03 +00:00
Michael Graff
11e2a221f1
hack on socket code more, trying to track down a bug
1999-07-28 23:04:33 +00:00
Michael Graff
d524cd03ec
make the isc_socket_recv() partial flag be a byte count instead, which allows
...
us to say "read at least 2 bytes" for things like a DNS packet over TCP.
1999-07-28 21:30:37 +00:00
Michael Graff
6f1422b81e
fix many bugs.
1999-07-22 01:34:31 +00:00
Michael Graff
3446e5e932
Don't allow responses/requests to be attached to dispatchers which are
...
shutting down
1999-07-14 22:16:19 +00:00
Bob Halley
ef4b66d355
update isc_sockettype_t enum names
1999-07-13 01:49:33 +00:00
Michael Graff
2743e0ce08
s/dns_dispatch_destroy()/dns_dispatch_detach()/g
1999-07-13 00:25:21 +00:00
Michael Graff
c6066a8e67
make this (mostly) work with tcp
1999-07-12 23:44:31 +00:00
Bob Halley
9db3eaed95
the event tag is now a void *
1999-07-10 00:55:07 +00:00
Michael Graff
04135883be
cleanup a few return codes
1999-07-10 00:15:41 +00:00
Michael Graff
7f1bd55920
s/printf/XDEBUG()/g
1999-07-09 20:42:55 +00:00
Michael Graff
bd7237e653
add another REQUIRE() where it might help
1999-07-09 20:34:26 +00:00
Michael Graff
c16cc434ef
checkpoint; add dns_dispatch_getsocket() to return the socket being used
1999-07-09 20:32:12 +00:00
Michael Graff
6fe411037d
checkpoint
1999-07-09 02:47:55 +00:00
Michael Graff
58efc48a96
checkpoint
1999-07-09 01:57:55 +00:00
Michael Graff
d1ba6e9180
snapshot
1999-07-09 00:51:08 +00:00
Michael Graff
0b14ebe313
checkpoint
1999-07-08 22:12:37 +00:00
Michael Graff
1ec39fc7a8
checkpoint
1999-07-08 02:50:00 +00:00
Michael Graff
ab0e506608
checkpoint
1999-07-06 19:32:40 +00:00
Michael Graff
8d1943e8ff
add dns_dispatch_attach/detach(), and start on serious dispatcher hacking.
1999-06-30 01:33:11 +00:00
Michael Graff
54a64ec428
checkpoint
1999-06-18 23:54:59 +00:00
Michael Graff
a8dcebd041
checkpoint
1999-06-18 02:01:42 +00:00
Michael Graff
83f8c56f43
checkpoint
1999-06-16 01:32:31 +00:00