Opening the socket is the only privileged operation route requires.
Make a couple of static buffers bigger, and use strncpy() and snprintf() where
there's a chance of overflow.
Fixes PR bin/1903
Partially Submitted by: Ollivier Robert <roberto@keltia.freenix.fr>
Don't look up the network number if we're being asked to add a host route.
Fixes PR bin/1900
Submitted by: Bruce A. Mah <bmah@cs.berkeley.edu> (pr bin/1900)
Do not exit with status 0 if mkdep(1) cannot create output,
e.g. if .depend is not writable or the FS is readonly mounted.
Store arguments as comments for debugging purpose.
From NetBSD via OpenBSD to fix NetBSD PR #506
More descriptive message for printer status
(OpenBSD: 1.2)
Various warnings cleaned up (OpenBSD: 1.4)
lpc/lpc.c:
Various warnings cleaned up (OpenBSD: 1.3)
lpd/lpd.c:
Remove trailing blank lines (OpenBSD: 1.2)
Potential umask problem with creating /dev/printer
(OpenBSD: 1.4 and 1.5)
Ftp bounce attack (untested on FreeBSD)
(OpenBSD: 1.6, 1.8, 1.9)
Fencepost in strncpy
(OpenBSD: 1.6)
lpd/printjob.c:
Fix from freebsd for waiting for an exiting filter, that
appears not in the FreeBSD CVS tree.
(OpenBSD: 1.6)
lpd/recvjob.c:
Buffer overflow protection: use strncpy rather than strcpy.
(OpenBSD: 1.3)
lpr/lpr.c:
NetBSD change of return type for main()
(OpenBSD: 1.2)
Restrict time running as root
(OpenBSD: 1.7)
Use getcwd rather than getwd (from NetBSD)
Use snprintf rather than sprintf
(OpenBSD: 1.8)
Minor tweak to end of loop and buffer overflow sanity. card()
overflow already in FreeBSD
(OpenBSD: 1.9)
lptest/lptest.c:
void -> int return type of main, from NetBSD via OpenBSD
(OpenBSD: 1.2)
pac/pac.c:
void -> int return type of main, from NetBSD via OpenBSD
(OpenBSD: 1.3)
Obtained from: OpenBSD
TIMER_FREQ.
Fixed missing splx() in scrn_timer(). The bug was harmless because of the
undocumented behaviour that the ipl is automatically restored for timeout
functions (see softclock()). Perhaps we should depend on this behaviour.
Fixed the ddb fix in rev.1.176. The in_debugger flag was no use because
it only works when the debugger is entered via the keyboard hotkey. The
debugger may be entered for breakpoints and traps, and the console putc
routine has no way of knowing when it was, so the console putc routine
must (almost?) always remove the cursor image.
Not fixed: console switching in ddb doesn't work (ISTR it working), and
console 0 shouldn't be switched to for the debugger hotkey unless console
0 is /dev/console.
Fixed side effects from calling add_keyboard_randomness() in the console
getc routine by not calling it. add_keyboard_randomness() currently
always reenables interrupts on 386's and 486's. This is very bad if the
console getc routine is called from the debugger and the debugger was
entered with interrupts disabled.
Fixed preservation of initial screen and now-bogus comment about it. It
was broken by setting the initial scr_buf to `buffer' instead of Crtat.
`buffer' was full of nulls and the first scroll cleared everything above
the things written through syscons.
Submitted by: bruce (bde@freebsd.org)
Without this, compiled programs die with FP errors.
This is originally credited to: jlemon@netcom.com (Jonathan Lemon), and
has been forwarded to me by quite a few of people.
buffer which could be made to lead to a root shell. This patch is
OpenBSD's solution to the problem, and will silently truncate the
output rather than overflow the buffer.
Obtained from: OpenBSD
and YP_SECURE flags so that it can properly add them to newly created
maps when needed. This applies only when using the 'standard' method
for map transfers. When using rpc.ypxfrd, the whole map is copied
verbatim, along with any special entries that may be encoded in it.
Also made -Wall a little quieter for ypxfrd_getmap.c.
Fixed some style bugs for cua* and tty*.
Removed superfluous chmod for consolectl.
FIxed a tiny security bug for perfmon and changed the style for
perfmon to match the style of the non-std devices.
so that simple regresssion tests based on `cmp' work. mkdep still
doesn't work right for these tools. They should probably be in
separate directories.
Sorted dependencies.
I decided to do this for every hardclock() call instead of lazily
in microtime(). The lazy method is simpler but has more overhead
if microtime() is called a lot.
CPU_THISTICKLEN() is now a no-op and should probably go away.
Previously it did nothing directly but had the side effect of
setting i586_last_tick for CPU_CLOCKUPDATE() and i586_avg_tick for
debugging. CPU_CLOCKUPDATE() now uses a better method and
i586_avg_tick is too much trouble to maintain.
Reduced nesting of #includes in the usual case.
Increased nesting of #includes when CLOCK_HAIR is defined. This
is a kludge to get typedefs for inline functions only when the
inline functions are used. Normally only kern_clock.c defines
this. kern_clock.c can't include the i386 headers directly.
Removed unused LOCORE support.
break when I remove LOCORE support from clock.h.
I586_CTR_MULTIPLIER_SHIFT = 32 from clock.h is actually still used, but
32 is so magic that it doesn't get used explicitly.
- Add support for memory mapped I/O.
- Use DMA to get SCBs down to the adapters.
- Remove old paging code.
- Be much smarter about how we allocate SCB space. The old, simple method
wasted almost half a page per SCB. Ooops.
- Make command complete interrupt processing more efficient.
- Break the monolithic ahc_intr into sub-routines. The sub-routines handle
rare, special case events so the function call is not a penalty and the
removal of the code from the main routine most likely improves performance
instruction prefech will work better and less code is pushed into the cache.
- Never, ever allow tagged queueing if a device has disconnection disabled.
- Clean up and simplify timeout code. Many of the changes are to handle the
new DMA scheme.
SCB paging is now handled almost entirely by the sequencer and also uses
DMA. This should make SCB paging at least an order of magnitude more
efficient and vastly simplifies the implementation.
Add a few space optimizations so this code still fits on aic7770 chips.
Update comments.
any maps that may have them. If the YP_SECURE key is present, ypserv
will only allow access to the map from clients on reserved ports.
If the YP_INTERDOMAIN key is present, the server will do DNS lookups
for hostnames that it can't find in hosts.byname or hosts.byaddr.
This is the same as the -d flag (which is retained for backwards
compatibility) but it can be set on a per-map/per-domain basis.
Also modified /var/yp/Makefile to add YP_INTERDOMAIN to the hosts.*
maps and YP_SECURE to master.passwd.* maps by default.
the main program, report them directly from the dynamic linker and die
there, rather than returning an error message to crt0.o. This enables
the printing of error messages even for old executables, whose version
of crt0.o is not able to print them.
This fix closes PR bin/1869.
The code in crt0.o for printing error messages from the dynamic linker
is no longer used, because of this change. But it must remain, for
backward compatibility with older dynamic linkers.