Martin Mares [Sun, 16 Jan 2000 17:40:26 +0000 (17:40 +0000)]
Converted shutdown to a kind of reconfiguration, it's no more handled
as a exception in protocol state machines. Introduced a `shutdown'
CLI command. Killed few reconfiguration bugs.
Pavel Machek [Sat, 18 Dec 1999 20:41:19 +0000 (20:41 +0000)]
This is first version of documentation. Be sure to take a close look
at it, and it would be very nice if you wrote at least introductions
to your chapters...
Martin Mares [Thu, 16 Dec 1999 13:06:13 +0000 (13:06 +0000)]
Tried to clean up multicast handling. Now we don't try to guess
multicast abilities depending on definedness of symbols and use hard-wired
system-dependent configuration defines instead.
Martin Mares [Thu, 9 Dec 1999 18:54:20 +0000 (18:54 +0000)]
Added universal locking mechanism which will solve problems
with protocols wanting to use the same port on the same interface
during reconfiguration time.
How to use locks: In the if_notify hook, just order locks for the
interfaces you want to work with and do the real socket opening after the
lock hook function gets called. When you stop using the socket, close
it and rfree() the lock.
Please update your protocols to use the new locking mechanism.
Martin Mares [Fri, 3 Dec 1999 11:40:45 +0000 (11:40 +0000)]
Added proto_get_named() to be used in CLI commands to get protocol instance
of a given protocol with optionally given name. See `show static' for an
example.
Martin Mares [Wed, 1 Dec 1999 15:07:56 +0000 (15:07 +0000)]
Reset temporary parser data before parsing, not afterwards. This enables
deferred CLI command handlers to store their temporary data in the CLI
parsing pool.
Martin Mares [Wed, 1 Dec 1999 12:00:15 +0000 (12:00 +0000)]
`show protocols' now shows time of last state change and protocol-dependent
status information (obtained via newly introduced hook protocol->get_status).
Martin Mares [Wed, 1 Dec 1999 10:28:39 +0000 (10:28 +0000)]
Use linux-22 configuration with all 2.2.x and 2.3.x kernels. This means
you need to have your kernel compiled with netlink routing messages enabled.
If it doesn't work for you, use --with-sysconfig=linux-21 and let me know
what's going wrong.
Pavel Machek [Thu, 25 Nov 1999 14:54:08 +0000 (14:54 +0000)]
Bugfixes: select right password for password authentication, do not
try to process authentication blocks as datablocks, make it possible
to add data at end of packet. Password authentication should actually work.
Martin Mares [Thu, 18 Nov 1999 14:41:29 +0000 (14:41 +0000)]
Allow EA type to be set to 'undefined' which overrides all further definitons
of that EA in the same list and causes ea_find() to fail unless you add
EA_ALLOW_UNDEF to the second argument.
ea_sort (resp. ea_do_prune()) removes all undef'd attributes from the list.
Martin Mares [Wed, 17 Nov 1999 12:14:44 +0000 (12:14 +0000)]
Added some temporary examples of how to define CLI commands (search for CF_CLI).
To define a new command, just add a new rule to the gramar:
CF_CLI(COMMAND NAME, arguments, help-args, help-text) {
what-should-the-command-do
} ;
where <arguments> are appended to the RHS of the rule, <help-args> is the
argument list as shown in the help and <help-text> is description of the
command for the help.
<what-should-the-command-do> is a C code snippet to be executed. It should
not take too much time to execute. If you want to print out a lot of
information, you can schedule a routine to be called after the current
buffer is flushed by making cli->cont point to the routine (see the
TEST LONG command definition for an example); if the connection is closed
in the meantime, cli->cleanup gets called.
You can access `struct cli' belonging to the connection you're currently
servicing as this_cli, but only during parse time, not from routines scheduled
for deferred execution.
Functions to call inside command handlers:
cli_printf(cli, code, printf-args) -- print text to CLI connection,
<code> is message code as assigned in doc/reply_codes or a negative
one if it's a continuation line.
cli_msg(code, printf-args) -- the same for this_cli.
Use 'sock -x bird.ctl' for connecting to the CLI until a client is written.
Martin Mares [Wed, 17 Nov 1999 12:04:24 +0000 (12:04 +0000)]
If the main event queue is not empty, call select() with zero timeout, so
that the events are ran again after the FD's are checked. This allows us
to schedule I/O checks between processing of user commands.