summaryrefslogtreecommitdiff
path: root/usr.sbin
AgeCommit message (Collapse)Author
2010-06-01Don't interpret garbage on stack; problem seemingly exposed by myJacek Masiulaniec
queue rewrite. Proper fix after gilles wakes up.
2010-06-01Fix one case of not sending smtp session id on error.Jacek Masiulaniec
2010-05-31oopsJacek Masiulaniec
2010-05-31Rewrite entire queue code.Jacek Masiulaniec
Major goals: 1) Fix bad performance caused by the runner process doing full queue read in 1s intervals. My Soekris can now happily accept >50 msg/s while having multi-thousand queue; before, one hundred queue would bring the system to its knees. 2) Introduce Qmail-like scheduler that doesn't write as much to the disk so that it needs less code for servicing error conditions, which in some places can be tricky to get right. 3) Introduce separation between the scheduler and the backend; these two queue aspects shouldn't be too tied too each other. This means that eg. storing queue in SQL requires rewrite of just queue_backend.c. 4) Make on-disk queue format architecture independent, and more easily extensible, to reduce number of flag days in the future. Minor goals: ENOSPC no longer prevents delivery attempts, fixed session limiting for relayed mail, improved batching of "relay via" mails, human-readable mailq output, "show queue raw" command, clearer logging, sending of single bounce about multiple recipients, exact delay= computation, zero delay between deliveries while within session limit (currently 1s delay between re-scheduling is enforced), mta no longer requests content fd, corrected session limit for bounce submissions, tiny <100B queue files instead of multi-KB, detect loops before accepting mail, reduce traffic on imsg channels by killing enormous struct submit_status.
2010-05-31imsg_compose_event() return value was never checked. Make it fatal() if needed.Charles Longeau
ok jacekm@ gilles@
2010-05-31Do not add the swap*.c to the CFILES as a dependency. The rest of theTheo de Raadt
Makefile.* file copes with swap*.c the same as vers.c; it is also much nicer to keep the whole CFILES as far-reaching absolute or relative paths rather than relative to . ok miod
2010-05-31use strtonum() instead of atoi() to parse the device addressTheo de Raadt
(from 1 - USB_MAX_DEVICES, not 0- as submitted) from Gleydson Soares
2010-05-31Remove trailing whitespace and spaces before tabs.Martin Hedenfal
ok gilles@
2010-05-31Add -I${.CURDIR}, fixes building in obj/.Martin Hedenfal
ok deraadt@
2010-05-31Initial import of ldapd, a small LDAP daemon. Work in progress.Martin Hedenfal
ok deraadt@ jacekm@ gilles@ back@ henning@ blambert@
2010-05-28Send the IMSG_NEIGHBOR_UP msg when the neighbor is going into operationalClaudio Jeker
status instead upon creation (when the first HELLO is received). The LDE needs only to know about operational neighbors or it may happen that the LDE is sending messages to neighbors that have no session open resulting in a crash because of unitialized structures. OK michele@
2010-05-27when a rule has two conditions (ie: accept for { domain foo, domain bar } )Gilles Chehade
expand to two rules each having its own condition rather than one rule with a tail queue of conditions. this simplifies code a bit and removes a couple hacks. basic testing by oga and me
2010-05-27struct opt as not used anywhere else, kill it, we can reintroduce it laterGilles Chehade
if we feel a need for it
2010-05-27kill struct opt from struct rule, we don't use it, we don't need itGilles Chehade
2010-05-26No need to include <sys/sysctl.h> here and it pulls in <sys/proc.h>Todd C. Miller
which causes conflicts with the libevent macros. OK deraadt@
2010-05-26libevent has named two of it's new macros by the same name as our kernelTheo de Raadt
macros, which are visible, and get pulled into some source code... Hide the kernel ones inside _KERNEL, and make trpt (the only userland viewer of them) define _KERNEL temporarily. This is really gross. libevent is doing a poor job of choosing function names! ok tedu guenther
2010-05-26Move imsg into libutil and add a man page.Nicholas Marriott
Minor bump for libutil. Previous versions of this diff and man page looked at by various people. "you should just commit" deraadt
2010-05-26Rename some imsg bits to make namespace collisions less likely buf toNicholas Marriott
ibuf, buf_read to ibuf_read, READ_BUF_SIZE to IBUF_READ_SIZE. ok henning gilles claudio jacekm deraadt
2010-05-25Ugh. Remove name2id.c for real now.Claudio Jeker
2010-05-25Remove another leftover from ospfd. ldpd does not have a concept of ext_tagClaudio Jeker
and so there is no need to carry ext_tag and rtlabels around. "Yes! kill kill kill" michele@
2010-05-25Implement the missing label map recv functions and cleanup the other recvClaudio Jeker
functions a bit to make them all look more similar. All but the label req abort message are now parsed and passed to the lde.
2010-05-25Add upcomming IMSG_LABEL_RELEASE, IMSG_LABEL_WITHDRAW and IMSG_LABEL_ABORT.Claudio Jeker
Add missing bits to struct map and restructure/simplify the lde.c imsg code.
2010-05-25Kill a bogus bzero() and introduce an empty lde_check_release().Claudio Jeker
That function will be needed soon.
2010-05-25I removed code in the last commit that is needed. Allocate rbuf now byClaudio Jeker
default or else we bomb on the first read access.
2010-05-24automatically generate the _arch= and _mach= lines at the top of the kernelTheo de Raadt
Makefile, since we already know them. (Later on, we can remove the chunks from the Makefile.* files...) ok kettenis
2010-05-24now that we can handle >9 args, put "-D name=value" on one line: it's a bitJason McIntyre
more readable, and fixes a spacing bug we had in smtpd.8;
2010-05-23When executing external mda, call dup2, closefrom, and chdir beforeJacek Masiulaniec
setresuid because after dropping superuser privileges the process cannot be trusted to call these. Thanks to oga@, kettenis@, and nicm@ for confirming my paranoia.
2010-05-21remove unused functionsCharles Longeau
from tobias@ (loooooong time ago) ok rainer@ henning@ tobias@
2010-05-21Use _exit(2) in mda helper child process.Jacek Masiulaniec
2010-05-20S_ISREG() should be called on st.st_mode not st.st_flagsGilles Chehade
2010-05-19cleanup-only commit, removes unrequired includes, no functionnal changeGilles Chehade
2010-05-19Remove yet another ospf leftover that is not needed here. This timeClaudio Jeker
neighbor self and all the madness surrounding this amazing concept. LDP is not self aware so there is no need for this. OK michele@
2010-05-19When installing MPLS VPN routes set the RTF_MPLS bit since those routesClaudio Jeker
have MPLS information connected to them and the kernel requires the flag now. OK michele@
2010-05-19Set RTF_MPLS in rtm_fmask and rtm_flags because ldpd wants to play withClaudio Jeker
the MPLS part of those routes. OK michele@
2010-05-19Add softreconfig support for peers changing the RIB. Done by first unloadingClaudio Jeker
the old RIB and then via softreconfig in and a special softreconfig out loading the new RIB. Feature requested and testeded by Elisa Jasinska. OK henning@
2010-05-18Spacing.Claudio Jeker
2010-05-18use the right capitalization for "HyperText Transfer Protocol (HTTP)"Igor Sobrado
and "server". fixes for bgplg(8) and relayd.conf(5) suggested by jmc@, good catch! ok jmc@
2010-05-18Be more careful in ktable_update() and ktable_new() and the fib sync flag.Claudio Jeker
Only existing tables should keep their fib sync state, new ones should set the current fib sync flag to the configured one at the end of the config load. Found the hard way by sthen@, OK sthen@
2010-05-17more then -> more than;Jason McIntyre
2010-05-17tweak previous;Jason McIntyre
2010-05-17Implement two new filters, max-as-len and max-as-seq. The first is limitingClaudio Jeker
the length of an AS path (matches if the path is longer then the specified lenght) the second matches when a sequence of the same AS number is longer then the specified length). max-as-len is good to protect crappy comercial bgp boxes from other crappy comercial bgp boxes. max-as-seq was a feature request from SwissIX and maybe EuroIX to find and filter prepends. Additinal testing and OK sthen@
2010-05-17Last bits of MPLS VPN support. Hook kernel routing tables and RIB together.Claudio Jeker
This adds a bit of new config to specify the mapping between an rdomain and the BGP MPLS VPN instance, example: rdomain 1 { descr "CUSTOMER1" rd 65003:1 import-target rt 65003:3 export-target rt 65003:1 depend on mpe0 network 192.168.224/24 } The "depend on mpe0" is a but ugly but for now this is the quickest way to figure out which interface bgp should use to insert the MPLS routes. A big side-effect of this diff is that networks are now internally distributed through kroute.c. This needs some kernel changes that will follow hopefully soon. OK henning@
2010-05-17The host address encoding of FEC was killed in RFC5036 and we're happyClaudio Jeker
about that. OK michele@
2010-05-14Order struct element by size.Claudio Jeker
2010-05-14Do not send notifications directly onto the wire. Decide in the caller howClaudio Jeker
to send the notification. On accept use write() else queue message and try to send the queued messages out via msgbuf_write(). This may still fail but is better then the code beforehands. OK michele@
2010-05-14Use calloc() instead of malloc() to allocate the connection structure. ThisClaudio Jeker
way the memory is zeroed. This is equivalent to the relayd commit by reyk. OK reyk, jsg
2010-05-14allocate all struct event's on the heap, it looks cleaner, feels betterReyk Floeter
and follows a suggestion in event.h. also don't mix signal() and signal_set()/signal_add(). ok jsg@ gilles@
2010-05-14zero out the allocate memory for a new control connection via calloc()Reyk Floeter
ok jsg@ gilles@
2010-05-14When merging interfaces after a config reload, the fsm state for interfacesStuart Henderson
is forced into IF_STA_NEW so that if_init() can be called to setup timers etc. When a loopback interface is added to the config, this means there's no way to get to the correct state. Fix by avoiding changing an existing IF_STA_LOOPBACK and forcing loopback interfaces to be passive (otherwise skipping the if_init on an active interface causes problems). ok claudio@
2010-05-14spacingReyk Floeter