CVS: cvs.openbsd.org: src

2021-06-11 Thread Kenneth R Westerback
CVSROOT:/cvs
Module name:src
Changes by: k...@cvs.openbsd.org2021/06/11 18:47:30

Modified files:
sbin/fdisk : gpt.c 

Log message:
Use a new variable 'gpbytes' rather than 'sizeof(gp)' to control
the number of bytes of partition entries to write to disk.

Set gpbytes to 'sizeof(gp)' so no functional change for now.



CVS: cvs.openbsd.org: src

2021-06-11 Thread Kenneth R Westerback
CVSROOT:/cvs
Module name:src
Changes by: k...@cvs.openbsd.org2021/06/11 17:49:49

Modified files:
sbin/fdisk : gpt.c 

Log message:
Oops. Restore error message when no free space found.



CVS: cvs.openbsd.org: src

2021-06-11 Thread Dave Voutila
CVSROOT:/cvs
Module name:src
Changes by: d...@cvs.openbsd.org2021/06/11 15:46:00

Modified files:
usr.sbin/vmd   : virtio.c 

Log message:
vmd(8): deduplicate vioblk command logic

No need for each case in the switch block to have the same logic
for updating the used ring and writing the state back to the guest.
Move it outside the switch. No functional change.

ok mlarkin@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Kenneth R Westerback
CVSROOT:/cvs
Module name:src
Changes by: k...@cvs.openbsd.org2021/06/11 14:28:12

Modified files:
sbin/fdisk : gpt.c 

Log message:
Add local function lba_free() to find the bounds of the largest
chunk of free space in a GPT. Steal logic from
GPT_get_lba_start().

No intentional functional change.



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jason McIntyre
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 13:45:21

Modified files:
lib/libcrypto/man: X509_VERIFY_PARAM_set_flags.3 

Log message:
space between RFC and number;



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jason McIntyre
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 13:41:39

Modified files:
lib/libssl/man : SSL_CTX_set_options.3 
 SSL_CTX_set_tlsext_ticket_key_cb.3 
 SSL_CTX_set_tlsext_use_srtp.3 SSL_clear.3 
 SSL_free.3 SSL_set_shutdown.3 

Log message:
space between RFC and number;



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jason McIntyre
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 13:36:00

Modified files:
gnu/lib/libexecinfo: backtrace.3 

Log message:
remove netbsd specific LIBRARY section; ok jca



CVS: cvs.openbsd.org: www

2021-06-11 Thread Landry Breuil
CVSROOT:/cvs
Module name:www
Changes by: lan...@cvs.openbsd.org  2021/06/11 12:33:39

Modified files:
faq: faq17.html 

Log message:
faq17.html: use lo1 instead of vether0 in iked.conf examples

suggested by deraadt@, ok tobhe@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Joel Sing
CVSROOT:/cvs
Module name:src
Changes by: js...@cvs.openbsd.org   2021/06/11 11:29:49

Modified files:
lib/libssl : d1_both.c ssl_stat.c ssl_tlsext.c 

Log message:
Only use SSL_AD_* internally.

Due to hysterical raisins there are three different types of defines for
alerts. SSL3_AD_* are from SSLv3, TLS1_AD_* are from TLSv1.0 onwards and
SSL_AD_* currently map to either an SSL3_AD_* or TLS1_AD_* define.

Currently, all three of these are used in various places - switch to using
just SSL_AD_* values internally, as a first step in cleaning this up.

ok tb@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Scott Soule Cheloha
CVSROOT:/cvs
Module name:src
Changes by: chel...@cvs.openbsd.org 2021/06/11 10:36:34

Modified files:
sys/kern   : kern_time.c 
sys/sys: time.h 

Log message:
setitimer(2): don't round up it_value

We can reduce latency for the first expiration of a timer if we don't
round it_value up to the minimum interval (1 tick).

While we're at it, we may as well consolidate all input validation and
adjustment into a single itimerfix() call.  There are no other callers
in the kernel (nor should there be), so remove the prototype from
sys/time.h.

Discussion: https://marc.info/?l=openbsd-tech=162084338005502=2

Tested by weerd@ and claudio@.

probably ok claudio@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Kenneth R Westerback
CVSROOT:/cvs
Module name:src
Changes by: k...@cvs.openbsd.org2021/06/11 10:22:46

Modified files:
sbin/fdisk : cmd.c 

Log message:
Add local functions edit() and setpid().

Reduce Xedit()/Xsetpid() to parsing the partition number and
invoking [g]edit()/[g]setpid() appropriately.

No intentional functional change.



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jonathan Gray
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 09:50:43

Modified files:
sys/dev/pci: azalia_codec.c 

Log message:
recognise ALC897



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jonathan Gray
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 09:46:09

Modified files:
sys/dev/pci: azalia.c 

Log message:
enable snooping on Z590 HDA

from Ashton Fagg



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jonathan Gray
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 09:43:22

Modified files:
sys/dev/pci: pcidevs.h pcidevs_data.h 

Log message:
regen



CVS: cvs.openbsd.org: src

2021-06-11 Thread Jonathan Gray
CVSROOT:/cvs
Module name:src
Changes by: j...@cvs.openbsd.org2021/06/11 09:42:36

Modified files:
sys/dev/pci: pcidevs 

Log message:
add a HDA device found in a Z590 machine

from Ashton Fagg



CVS: cvs.openbsd.org: src

2021-06-11 Thread Landry Breuil
CVSROOT:/cvs
Module name:src
Changes by: lan...@cvs.openbsd.org  2021/06/11 09:28:14

Modified files:
lib/libssl : d1_srtp.c srtp.h 
lib/libssl/man : SSL_CTX_set_tlsext_use_srtp.3 

Log message:
add AES-GCM constants from RFC 7714 for SRTP

SRTP_AEAD_AES_128_GCM/SRTP_AEAD_AES_256_GCM can be used as DTLS-SRTP
protection profiles - seen with an update of telephony/baresip i'm
working on.

adapted from openssl commit 43e5faa2539ae8aae6ef55be2239b9b1a77fea45

ok tb@ jsing@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Kenneth R Westerback
CVSROOT:/cvs
Module name:src
Changes by: k...@cvs.openbsd.org2021/06/11 08:02:22

Modified files:
sbin/fdisk : cmd.c 

Log message:
Take a bit more obvious care in gedit() to restore original
partition information when one of the modification steps (e.g.
setting the partition type via gsetpid()) fails.



CVS: cvs.openbsd.org: src

2021-06-11 Thread Tobias Heider
CVSROOT:/cvs
Module name:src
Changes by: to...@cvs.openbsd.org   2021/06/11 07:11:20

Modified files:
sbin/iked  : ikev2.c 

Log message:
Revert previous change in ikev2_cp_fixaddr().
Fixes a regression found by landry@.

ok patrick@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Patrick Wildt
CVSROOT:/cvs
Module name:src
Changes by: patr...@cvs.openbsd.org 2021/06/11 06:47:15

Modified files:
sys/dev/pv : if_hvn.c 

Log message:
Drop received packets unless IFF_RUNNING is set.  When hvn(4) attaches
it sends commands and waits for replies to come back in.  The receive
pipe seems to contain both command completions and data packets.  When
waiting for command completion during hvn(4) attach, it's possible for
packets to show up as well.  We shouldn't call if_input() if hvn(4) is
not set up, so drop them when we're not running.

ok mikeb@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Mark Kettenis
CVSROOT:/cvs
Module name:src
Changes by: kette...@cvs.openbsd.org2021/06/11 06:23:52

Modified files:
sys/arch/arm64/dev: aplpcie.c 
sys/arch/arm64/include: pci_machdep.h 

Log message:
Store the device tree node in the pcitag_t like we do on powerpc64 andi
sparc64.  For now, do this only for aplpcie(4) as we only need this
functionality for Apple Silicon systems.

ok patrick@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Stuart Henderson
CVSROOT:/cvs
Module name:src
Changes by: st...@cvs.openbsd.org   2021/06/11 05:40:35

Modified files:
lib/libcrypto  : cert.pem 

Log message:
sync cert.pem with Mozilla's CA list generated from certdata.txt
(certificates with the "server auth" trust purpose permitted).
ok tb@

-AC Camerfirma S.A.
-  /C=EU/L=Madrid (see current address at 
www.camerfirma.com/address)/serialNumber=A82743287/O=AC Camerfirma 
S.A./CN=Chambers of Commerce Root - 2008
-  /C=EU/L=Madrid (see current address at 
www.camerfirma.com/address)/serialNumber=A82743287/O=AC Camerfirma 
S.A./CN=Global Chambersign Root - 2008
-

FNMT-RCM
/C=ES/O=FNMT-RCM/OU=AC RAIZ FNMT-RCM
+  /C=ES/O=FNMT-RCM/OU=Ceres/2.5.4.97=VATES-Q2826004J/CN=AC RAIZ FNMT-RCM 
SERVIDORES SEGUROS

-GeoTrust Inc.
-  /C=US/O=GeoTrust Inc./CN=GeoTrust Global CA
-  /C=US/O=GeoTrust Inc./OU=(c) 2007 GeoTrust Inc. - For authorized use 
only/CN=GeoTrust Primary Certification Authority - G2
-

GlobalSign nv-sa
+  /C=BE/O=GlobalSign nv-sa/CN=GlobalSign Root E46
+  /C=BE/O=GlobalSign nv-sa/CN=GlobalSign Root R46
/C=BE/O=GlobalSign nv-sa/OU=Root CA/CN=GlobalSign Root CA

Staat der Nederlanden
/C=NL/O=Staat der Nederlanden/CN=Staat der Nederlanden EV Root CA
-  /C=NL/O=Staat der Nederlanden/CN=Staat der Nederlanden Root CA - G3

Unizeto Technologies S.A.
/C=PL/O=Unizeto Technologies S.A./OU=Certum Certification Authority/CN=Certum 
Trusted Network CA
+  /C=PL/O=Unizeto Technologies S.A./OU=Certum Certification 
Authority/CN=Certum Trusted Network CA 2
-
-VeriSign, Inc.
-  /C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=(c) 2008 VeriSign, Inc. 
- For authorized use only/CN=VeriSign Universal Root Certification Authority

(Note, "Staat der Nederlanden Root CA - G3" was changed to email trust only,
so is removed from this due to it only listing "server auth" purposes).



CVS: cvs.openbsd.org: src

2021-06-11 Thread Joel Sing
CVSROOT:/cvs
Module name:src
Changes by: js...@cvs.openbsd.org   2021/06/11 05:29:44

Modified files:
lib/libssl : d1_both.c 

Log message:
SSL3_AD_ILLEGAL_PARAMETER is not a valid SSLerror() reason code.

Use SSL_R_SSLV3_ALERT_ILLEGAL_PARAMETER instead.

ok tb@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Joel Sing
CVSROOT:/cvs
Module name:src
Changes by: js...@cvs.openbsd.org   2021/06/11 05:13:53

Modified files:
lib/libssl : bio_ssl.c d1_both.c d1_pkt.c ssl_both.c 
 ssl_cert.c ssl_lib.c ssl_rsa.c ssl_txt.c 
 t1_enc.c t1_lib.c tls13_server.c 

Log message:
Indent all labels with a single space.

This ensures that diff reports the correct function prototype.

Prompted by tb@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Mark Kettenis
CVSROOT:/cvs
Module name:src
Changes by: kette...@cvs.openbsd.org2021/06/11 04:30:36

Modified files:
regress/sys/kern/futex: futex.c 

Log message:
Adjust futex regress test since futex(2) now returns -1 on error and sets
errno like any normal syscall.

ok mpi@, bluhm@



CVS: cvs.openbsd.org: src

2021-06-11 Thread Mark Kettenis
CVSROOT:/cvs
Module name:src
Changes by: kette...@cvs.openbsd.org2021/06/11 04:29:33

Modified files:
lib/libc/sys   : Makefile.inc 

Log message:
Since futex(2) can fail, it needs a full syscall stub.  This should fixes
issues on powerpc64 and sparc64.

Note that this makes the lib/libpthread/errno test fail since that test
detects that we are touching errno now.  This will be addressed in a
future diff as it is not entirely clear whether the test is correct.

ok mpi@, bluhm@