Displaying 1 50 of 171,044 commits (0.016s)

OpenBSD — usr.bin/ssh packet.c clientloop.c

refactor activation of rekeying

This makes automatic rekeying internal to the packet code (previously
the server and client loops needed to assist). In doing to it makes
application of rekey limits more accurate by accounting for packets
about to be sent as well as packets queued during rekeying events
themselves.

Based on a patch from dtucker@ which was in turn based on a patch
Aleksander Adamowski in bz#2521; ok markus@

OpenBSD — lib/libc/locale mbrtowc.3

Align with reality, and with POSIX:  For this particular function,
incomplete characters are not an error, do not throw EILSEQ, and
are not supposed to.
OK millert@
Delta File
+3 -7 lib/libc/locale/mbrtowc.3
+3 -7 1 file

OpenBSD — sys/net80211 ieee80211_input.c ieee80211_node.h

Stop requiring a BlockAck session timeout (again), and just use it if the AP
is asking for it. This timeout should not be required anymore now that krw@'s
hangs are fixed by working around APs which make sequence numbers jump about.

OpenBSD — sys/net80211 ieee80211_input.c ieee80211_node.h

Work around buggy APs which occasionally emit sequence numbers much higher
than the current 11n BlockAck window. The previous code would be fooled into
moving the window forward and then drop packets until their sequence numbers
catch up with the new window, which can take several minutes.
Fixes traffic stalls observed with Broadcom APs.
ok krw@ tb@

OpenBSD — sys/dev/pci if_iwn.c

Fix off-by-one in loop termination condition.

ok stsp@
Delta File
+2 -2 sys/dev/pci/if_iwn.c
+2 -2 1 file

OpenBSD — sys/net80211 ieee80211_input.c

Hide some excessive net80211 debug printfs behind ieee80211_debug >= 2.
Delta File
+3 -3 sys/net80211/ieee80211_input.c
+3 -3 1 file

OpenBSD — usr.sbin/rtadvd log.h rtadvd.c

Mark a few others functions as __dead; ok bluhm@

OpenBSD — etc/rc.d dvmrpd

Remove setproctitle() for the parent process. Because rc.d(8) uses process
titles (including flags) to distinguish between daemons, this makes it
possible to manage multiple copies of a daemon using the normal infrastructure
by symlinking rc.d scripts to a new name. ok jung@ ajacoutot@,
missed in previous commit noticed after re-checking following report in bgpd.
Delta File
+1 -2 etc/rc.d/dvmrpd
+1 -2 1 file

OpenBSD — etc/rc.d bgpd

Remove setproctitle() for the parent process. Because rc.d(8) uses process
titles (including flags) to distinguish between daemons, this makes it
possible to manage multiple copies of a daemon using the normal infrastructure
by symlinking rc.d scripts to a new name. ok jung@ ajacoutot@,
missed in previous commit, problem reported by mxb/alumni/chalmers/se.
Delta File
+1 -3 etc/rc.d/bgpd
+1 -3 1 file

OpenBSD — lib/libc/stdlib strtonum.3

compare pointer to NULL in example code
Delta File
+3 -3 lib/libc/stdlib/strtonum.3
+3 -3 1 file

OpenBSD — sys/dev ipmi.c

Comment.
Delta File
+2 -1 sys/dev/ipmi.c
+2 -1 1 file

OpenBSD — sys/dev ipmi.c

Remove a too strict assertion.
Delta File
+2 -3 sys/dev/ipmi.c
+2 -3 1 file

OpenBSD — usr.sbin/dhcpd memory.c

avoid a use after free when parsing address ranges from a config
ok krw@
Delta File
+2 -1 usr.sbin/dhcpd/memory.c
+2 -1 1 file

OpenBSD — sys/ntfs ntfs_subr.c

Convert to uiomove. While there, use size_t consistently for
variables 'left' and 'tocopy' and adapt printf and DPRINTF format
strings accordingly.

From Martin Natano.
Delta File
+31 -32 sys/ntfs/ntfs_subr.c
+31 -32 1 file

OpenBSD — usr.sbin/dhcrelay dhcpd.h bpf.c

Eliminate #include inside *.h files and include only needed headers in
each *.c file.

Inspired by mention of header silliness by Edgar Pettijohn and mmcc@
on tech@.

OpenBSD — usr.sbin/dhcpd dhcpd.h sync.c

Eliminate #include inside *.h files and include only needed headers in
each *.c file.

Inspired by mention of header silliness by Edgar Pettijohn and mmcc@
on tech@.
Delta File
+1 -32 usr.sbin/dhcpd/dhcpd.h
+13 -18 usr.sbin/dhcpd/sync.c
+25 -5 usr.sbin/dhcpd/dispatch.c
+19 -5 usr.sbin/dhcpd/bpf.c
+20 -3 usr.sbin/dhcpd/dhcpd.c
+17 -2 usr.sbin/dhcpd/icmp.c
+229 -25 17 files not shown
+324 -90 23 files

OpenBSD — sbin/dhclient dhcpd.h dispatch.c

Eliminate #include inside *.h files and include only needed headers in
each *.c file.

Inspired by mention of header silliness by Edgar Pettijohn and mmcc@
on tech@.
Delta File
+1 -34 sbin/dhclient/dhcpd.h
+24 -4 sbin/dhclient/dispatch.c
+24 -4 sbin/dhclient/dhclient.c
+20 -5 sbin/dhclient/kroute.c
+19 -3 sbin/dhclient/conflex.c
+19 -3 sbin/dhclient/bpf.c
+97 -17 7 files not shown
+204 -70 13 files

OpenBSD — sys/tmpfs tmpfs_subr.c tmpfs_vnops.c

Convert to uiomove. From Martin Natano.

OpenBSD — sys/dev/pci/drm/radeon radeon_bios.c

Enable the code that reads the BIOS from the ACPI VFCT table on platforms
with ACPI.

ok jsg@

OpenBSD — usr.bin/write write.1

Explain why we intentionally violate POSIX here, to prevent people from
being sad that they can't use UTF-8 in write(1), and to prevent that
they waste their time trying to fix it.
While here, fix some broken escaping.
OK jmc@ martijn@
Delta File
+6 -5 usr.bin/write/write.1
+6 -5 1 file

OpenBSD — sys/dev/pci if_iwn.c

Fix iwn(4) CCMP replay detection so it does not drop out-of-order A-MPDU
subframes. Helps 11n mode with WPA.
tested by me, tb@, and krw@
Delta File
+4 -2 sys/dev/pci/if_iwn.c
+4 -2 1 file

OpenBSD — sys/net80211 ieee80211_input.c

Count A-MPDU subframes with sequence number below the current BA window as
duplicates rather than input errors. These subframes have either already
been received, or the window was moved by the gap timeout which should only
happen with buggy APs. Neither condition indicates a severe problem.
Perhaps we will introduce a separate counter for this later.
Delta File
+2 -2 sys/net80211/ieee80211_input.c
+2 -2 1 file

OpenBSD — sys/msdosfs msdosfs_vnops.c

Guard against integer overflow when checking whether
writing to a file on msdosfs stays within the max. file size.

ok kettenis@, krw@
Delta File
+3 -2 sys/msdosfs/msdosfs_vnops.c
+3 -2 1 file

OpenBSD — usr.sbin/smtpd smtpd.c

use SMTPD_NAME define

ok gilles
Delta File
+2 -2 usr.sbin/smtpd/smtpd.c
+2 -2 1 file

OpenBSD — sys/net80211 ieee80211_output.c

Define EDCA tables for 11n mode. Per 802.11-2012 they are the same as
the tables for 11a/11g modes.
Add a function to append a Microsoft WME parameter element to a frame,
using EDCA tables to construct the parameter records. Some 11n AP's I have
observed provide this element.

None of this code is used yet, so no functional change. I wrote this while
debugging BlockAck and then realized it was only needed for hostap mode.
Once we support 11n in hostap mode and send A-MPDUs, this code will be needed.
Delta File
+53 -1 sys/net80211/ieee80211_output.c
+53 -1 1 file

OpenBSD — usr.bin/write write.c write.1

Make write explicitly ASCII only by transforming UTF-8 characters and non-ASCII
bytes to a single '?'. This prevents sending of potentially harmful bytes to
terminals who don't support UTF-8.

written with help from schwarze@
text suggestions by jmc@

OK schwarze@ and semarie@
Delta File
+24 -15 usr.bin/write/write.c
+7 -3 usr.bin/write/write.1
+31 -18 2 files

OpenBSD — lib/libc/gen popen.3, lib/libc/stdlib system.3

be more forceful about not using these.
improvements sthen@, jmc@. okay millert@, jca@ jmc@
Delta File
+19 -7 lib/libc/gen/popen.3
+9 -2 lib/libc/stdlib/system.3
+28 -9 2 files

OpenBSD — lib/libpcap optimize.c

Use the correct structure size when allocating the array for nodes.
ok tb@ millert@
Delta File
+2 -2 lib/libpcap/optimize.c
+2 -2 1 file

OpenBSD — distrib/sets/lists/base md.alpha md.amd64, distrib/sets/lists/comp mi

sync

OpenBSD — sys/dev/pci if_iwn.c if_iwnreg.h

In iwn(4), set max A-MPDU length to 64k instead of 4k and tell the firmware
about A-MPDU spacing. Makes BlockAck happy.
tested by me, tb@, krw@, sthen@, and Henrik Friedrichsen
Delta File
+20 -11 sys/dev/pci/if_iwn.c
+5 -3 sys/dev/pci/if_iwnreg.h
+25 -14 2 files

OpenBSD — sys/net80211 ieee80211_output.c ieee80211_proto.c

Store ADDBA request and response parameters in the block ack record of
ieee80211_node. This way, we can keep track of the ACK policy and echo
it back to the AP as required by the standard. And use the correct bit
flag for the policy -- this code was confused between BlockAck and ADDBA,
both of which have a policy bit but in different places.

Fixes apple airport APs.

tested by tb@, krw@, sthen@, abieber@, and Henrik Friedrichsen

OpenBSD — sys/dev/pci/drm drm_linux.h

Implement acpi_get_table_with_size().  Will soon be used to read VFCT
tables in radeondrm(4).
Delta File
+16 -1 sys/dev/pci/drm/drm_linux.h
+16 -1 1 file

OpenBSD — lib/libc/stdlib malloc.3

Fix err(3) calls after allocation failures in examples.
There is long-standing consensus that err(1, NULL) is the best idiom
after failure of malloc(3) and friends.
Quirk in the manual noticed by tb@.
Delta File
+8 -8 lib/libc/stdlib/malloc.3
+8 -8 1 file

OpenBSD — usr.bin/ssh channels.c

Only check errno if read() has returned an error.  EOF is not an error.
This fixes a problem where the mux master would sporadically fail to
notice that the client had exited.
ok mikeb@ djm@
Delta File
+7 -7 usr.bin/ssh/channels.c
+7 -7 1 file

OpenBSD — sys/net bpf.c

return if the bpf_if passed to bpf_tap and _bpf_mtap are NULL.

this works around a toctou bug in a very common idiom in our tree,
in between the two lines below:

        if (ifp->if_bpf)
                bpf_mtap(ifp->if_bpf, m, BPF_DIRECTION_OUT);

figured out by and diff from haesbart
Delta File
+7 -1 sys/net/bpf.c
+7 -1 1 file

OpenBSD — usr.bin/locale locale.c

Sort includes.
Delta File
+3 -3 usr.bin/locale/locale.c
+3 -3 1 file

OpenBSD — usr.bin/locale locale.c

No need for pledge("rpath")
Delta File
+2 -2 usr.bin/locale/locale.c
+2 -2 1 file

OpenBSD — usr.sbin/rtadvd rtadvd.c

select -> poll in log message; ok bluhm@ florian@
Delta File
+2 -2 usr.sbin/rtadvd/rtadvd.c
+2 -2 1 file

OpenBSD — usr.sbin/rtadvd rtadvd.c

Bail out if an unknown option is passed.

There is no reason for rtadvd to be different from other daemons.

Input from and ok bluhm@ florian@
Delta File
+15 -11 usr.sbin/rtadvd/rtadvd.c
+15 -11 1 file

OpenBSD — usr.sbin/rtadvd config.c if.c

rtadvd used a strncpy with a src interface name from the command line
without checking its length.  Replace it with strlcpy, check for
truncation and move the check before using the user-specified
interface name.  While here, replace another strncpy of a interface
name with memset-zero + strlcpy and check for truncation in
if_getmtu() (should not happen as we validated the length before, but
it's better to be safe and generally a better practice).

OK jsg@
Delta File
+6 -2 usr.sbin/rtadvd/config.c
+5 -3 usr.sbin/rtadvd/if.c
+11 -5 2 files

OpenBSD — usr.bin/tmux window-copy.c

Do not wrap cursor at start or end of history, from Michal Mazurek.
Delta File
+10 -7 usr.bin/tmux/window-copy.c
+10 -7 1 file

OpenBSD — usr.bin/talk talk.c

pledge(2) for talk(1):

At the beginning the largest pledge is the following:

rpath: read ~/.terminfo (the reason was changed pointed out by semarie@)
inet/dns: talk may need to connect to a remote host and resolve it
getpw: if getlogin(2) fails then it needs getpwuid(3) as a fallback
tty: this is a typical tty application, so it'll always need this annotation

Then just before the application main loop check if the talk is with local user
so it only needs "stdio tty", if it's remote then it needs "stdio inet tty".
I couldn't test this with a remote host to confirm if it needs inet or not but
as per jca@'s comment "tighter settings - if possible - can happen later"

ok jca@ and also discussed with tb@
Delta File
+14 -1 usr.bin/talk/talk.c
+14 -1 1 file

OpenBSD — libexec/talkd talkd.c

pledge(2) for talkd(8):

rpath: fopen(3) _PATH_UTMP in read mode
wpath/cpath: fopen(3) full_tty in write mode (w), which implies O_CREAT
inet/dns: the intervening hosts in the conversation may be remote, or not, but
since we will never know beforehand then it'll always need inet and dns to
resolve the hostnames

ok jca@ and also discussed with tb@
Delta File
+6 -1 libexec/talkd/talkd.c
+6 -1 1 file

OpenBSD — sys/dev/pci/drm drm_drv.c drm_linux.h

Improve Linux PCI compatibility code.

OpenBSD — sys/dev/pci/drm/radeon radeon_bios.c

Fix a pci vendor/device conversion missed in rev 1.6.

OpenBSD — etc/etc.amd64 MAKEDEV, etc/etc.i386 MAKEDEV

Regen

OpenBSD — etc MAKEDEV.common, etc/etc.amd64 MAKEDEV.md

Add ipmi(4) cdev entry on amd64 and i386

OpenBSD — sys/arch/amd64/amd64 conf.c, sys/arch/i386/i386 conf.c

Implement FreeBSD-compatible IOCTL to access BMC in ipmi(4)

Initial help & testing by jmatthew@
Code review & input by mpi@
Final review & OK by jsg@

OpenBSD — usr.bin/ssh sshconnect2.c

avoid an uninitialised value when NumberOfPasswordPrompts is 0
ok markus@ djm@
Delta File
+2 -2 usr.bin/ssh/sshconnect2.c
+2 -2 1 file

OpenBSD — lib/libc/locale rune.c

avoid an uninitialised value in a return path added in rev 1.5
ok tobias@
Delta File
+4 -2 lib/libc/locale/rune.c
+4 -2 1 file