Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
73024dd5d7 | ||
|
|
4815c5d19a | ||
|
|
9855f9178b | ||
|
|
8fdca57039 | ||
|
|
9ab0f5af2c | ||
|
|
22caea4db2 | ||
|
|
9795c4016a | ||
|
|
bde3635f3c | ||
|
|
f673f2f3e5 | ||
|
|
d7790cdce7 | ||
|
|
b23fe83f06 |
@@ -43,7 +43,7 @@ jobs:
|
||||
- { target: ubuntu-20.04, config: gcc-11-Werror }
|
||||
- { target: ubuntu-20.04, config: pam }
|
||||
- { target: ubuntu-20.04, config: kitchensink }
|
||||
- { target: ubuntu-20.04, config: hardenedmalloc }
|
||||
- { target: ubuntu-22.04, config: hardenedmalloc }
|
||||
- { target: ubuntu-20.04, config: tcmalloc }
|
||||
- { target: ubuntu-20.04, config: musl }
|
||||
- { target: ubuntu-latest, config: libressl-master }
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
See https://www.openssh.com/releasenotes.html#9.3p1 for the release
|
||||
See https://www.openssh.com/releasenotes.html#9.3p2 for the release
|
||||
notes.
|
||||
|
||||
Please read https://www.openssh.com/report.html for bug reporting
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
%global ver 9.3p1
|
||||
%global ver 9.3p2
|
||||
%global rel 1%{?dist}
|
||||
|
||||
# OpenSSH privilege separation requires a user & group ID
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
Summary: OpenSSH, a free Secure Shell (SSH) protocol implementation
|
||||
Name: openssh
|
||||
Version: 9.3p1
|
||||
Version: 9.3p2
|
||||
URL: https://www.openssh.com/
|
||||
Release: 1
|
||||
Source0: openssh-%{version}.tar.gz
|
||||
|
||||
@@ -113,6 +113,8 @@ static const struct kexalg kexalgs[] = {
|
||||
{ KEX_CURVE25519_SHA256, KEX_C25519_SHA256, 0, SSH_DIGEST_SHA256 },
|
||||
{ KEX_CURVE25519_SHA256_OLD, KEX_C25519_SHA256, 0, SSH_DIGEST_SHA256 },
|
||||
#ifdef USE_SNTRUP761X25519
|
||||
{ KEX_SNTRUP761X25519_SHA512_IANA, KEX_KEM_SNTRUP761X25519_SHA512, 0,
|
||||
SSH_DIGEST_SHA512 },
|
||||
{ KEX_SNTRUP761X25519_SHA512, KEX_KEM_SNTRUP761X25519_SHA512, 0,
|
||||
SSH_DIGEST_SHA512 },
|
||||
#endif
|
||||
|
||||
@@ -63,6 +63,7 @@
|
||||
#define KEX_CURVE25519_SHA256 "curve25519-sha256"
|
||||
#define KEX_CURVE25519_SHA256_OLD "[email protected]"
|
||||
#define KEX_SNTRUP761X25519_SHA512 "[email protected]"
|
||||
#define KEX_SNTRUP761X25519_SHA512_IANA "sntrup761x25519-sha512"
|
||||
|
||||
#define COMP_NONE 0
|
||||
/* pre-auth compression (COMP_ZLIB) is only supported in the client */
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
*/
|
||||
|
||||
#define KEX_SERVER_KEX \
|
||||
"sntrup761x25519-sha512," \
|
||||
"[email protected]," \
|
||||
"curve25519-sha256," \
|
||||
"[email protected]," \
|
||||
|
||||
@@ -55,7 +55,7 @@ EOF
|
||||
if [ $r -ne 0 ]; then
|
||||
fail "gdb failed: exit code $r"
|
||||
fi
|
||||
egrep 'ptrace: Operation not permitted.|procfs:.*Permission denied.|ttrace.*Permission denied.|procfs:.*: Invalid argument.|Unable to access task ' >/dev/null ${OBJ}/gdb.out
|
||||
egrep 'Operation not permitted.|Permission denied.|Invalid argument.|Unable to access task|Inappropriate ioctl for device.' >/dev/null ${OBJ}/gdb.out
|
||||
r=$?
|
||||
rm -f ${OBJ}/gdb.out
|
||||
if [ $r -ne 0 ]; then
|
||||
|
||||
@@ -24,22 +24,13 @@
|
||||
#include <stdio.h>
|
||||
#include <stddef.h>
|
||||
#include <stdarg.h>
|
||||
#ifdef HAVE_SHA2_H
|
||||
#include <sha2.h>
|
||||
#endif
|
||||
|
||||
#include "crypto_api.h"
|
||||
#include "sk-api.h"
|
||||
|
||||
#if defined(WITH_OPENSSL) && !defined(OPENSSL_HAS_ECC)
|
||||
# undef WITH_OPENSSL
|
||||
#endif
|
||||
|
||||
#ifdef WITH_OPENSSL
|
||||
/* We don't use sha2 from OpenSSL and they can conflict with system sha2.h */
|
||||
#define OPENSSL_NO_SHA
|
||||
#define USE_LIBC_SHA2 /* NetBSD 9 */
|
||||
#include <openssl/opensslv.h>
|
||||
#include <openssl/sha.h>
|
||||
#include <openssl/crypto.h>
|
||||
#include <openssl/evp.h>
|
||||
#include <openssl/bn.h>
|
||||
@@ -55,6 +46,15 @@
|
||||
(*ps) = sig->s; \
|
||||
} while (0)
|
||||
#endif
|
||||
|
||||
/* Use OpenSSL SHA256 instead of libc */
|
||||
#define SHA256Init(x) SHA256_Init(x)
|
||||
#define SHA256Update(x, y, z) SHA256_Update(x, y, z)
|
||||
#define SHA256Final(x, y) SHA256_Final(x, y)
|
||||
#define SHA2_CTX SHA256_CTX
|
||||
|
||||
#elif defined(HAVE_SHA2_H)
|
||||
#include <sha2.h>
|
||||
#endif /* WITH_OPENSSL */
|
||||
|
||||
/* #define SK_DEBUG 1 */
|
||||
|
||||
+20
-2
@@ -107,9 +107,27 @@ environment variable).
|
||||
.It Fl O Ar option
|
||||
Specify an option when starting
|
||||
.Nm .
|
||||
Currently only one option is supported:
|
||||
Currently two options are supported:
|
||||
.Cm allow-remote-pkcs11
|
||||
and
|
||||
.Cm no-restrict-websafe .
|
||||
This instructs
|
||||
.Pp
|
||||
The
|
||||
.Cm allow-remote-pkcs11
|
||||
option allows clients of a forwarded
|
||||
.Nm
|
||||
to load PKCS#11 or FIDO provider libraries.
|
||||
By default only local clients may perform this operation.
|
||||
Note that signalling that a
|
||||
.Nm
|
||||
client remote is performed by
|
||||
.Xr ssh 1 ,
|
||||
and use of other tools to forward access to the agent socket may circumvent
|
||||
this restriction.
|
||||
.Pp
|
||||
The
|
||||
.Cm no-restrict-websafe ,
|
||||
instructs
|
||||
.Nm
|
||||
to permit signatures using FIDO keys that might be web authentication
|
||||
requests.
|
||||
|
||||
+20
-1
@@ -169,6 +169,12 @@ char socket_dir[PATH_MAX];
|
||||
/* Pattern-list of allowed PKCS#11/Security key paths */
|
||||
static char *allowed_providers;
|
||||
|
||||
/*
|
||||
* Allows PKCS11 providers or SK keys that use non-internal providers to
|
||||
* be added over a remote connection (identified by session-bind@openssh.com).
|
||||
*/
|
||||
static int remote_add_provider;
|
||||
|
||||
/* locking */
|
||||
#define LOCK_SIZE 32
|
||||
#define LOCK_SALT_SIZE 16
|
||||
@@ -1228,6 +1234,12 @@ process_add_identity(SocketEntry *e)
|
||||
if (strcasecmp(sk_provider, "internal") == 0) {
|
||||
debug_f("internal provider");
|
||||
} else {
|
||||
if (e->nsession_ids != 0 && !remote_add_provider) {
|
||||
verbose("failed add of SK provider \"%.100s\": "
|
||||
"remote addition of providers is disabled",
|
||||
sk_provider);
|
||||
goto out;
|
||||
}
|
||||
if (realpath(sk_provider, canonical_provider) == NULL) {
|
||||
verbose("failed provider \"%.100s\": "
|
||||
"realpath: %s", sk_provider,
|
||||
@@ -1391,6 +1403,11 @@ process_add_smartcard_key(SocketEntry *e)
|
||||
error_f("failed to parse constraints");
|
||||
goto send;
|
||||
}
|
||||
if (e->nsession_ids != 0 && !remote_add_provider) {
|
||||
verbose("failed PKCS#11 add of \"%.100s\": remote addition of "
|
||||
"providers is disabled", provider);
|
||||
goto send;
|
||||
}
|
||||
if (realpath(provider, canonical_provider) == NULL) {
|
||||
verbose("failed PKCS#11 add of \"%.100s\": realpath: %s",
|
||||
provider, strerror(errno));
|
||||
@@ -2050,7 +2067,9 @@ main(int ac, char **av)
|
||||
break;
|
||||
case 'O':
|
||||
if (strcmp(optarg, "no-restrict-websafe") == 0)
|
||||
restrict_websafe = 0;
|
||||
restrict_websafe = 0;
|
||||
else if (strcmp(optarg, "allow-remote-pkcs11") == 0)
|
||||
remote_add_provider = 1;
|
||||
else
|
||||
fatal("Unknown -O option");
|
||||
break;
|
||||
|
||||
+2
-4
@@ -1537,10 +1537,8 @@ pkcs11_register_provider(char *provider_id, char *pin,
|
||||
error("dlopen %s failed: %s", provider_id, dlerror());
|
||||
goto fail;
|
||||
}
|
||||
if ((getfunctionlist = dlsym(handle, "C_GetFunctionList")) == NULL) {
|
||||
error("dlsym(C_GetFunctionList) failed: %s", dlerror());
|
||||
goto fail;
|
||||
}
|
||||
if ((getfunctionlist = dlsym(handle, "C_GetFunctionList")) == NULL)
|
||||
fatal("dlsym(C_GetFunctionList) failed: %s", dlerror());
|
||||
p = xcalloc(1, sizeof(*p));
|
||||
p->name = xstrdup(provider_id);
|
||||
p->handle = handle;
|
||||
|
||||
@@ -1175,6 +1175,7 @@ character, then the specified algorithms will be placed at the head of the
|
||||
default set.
|
||||
The default is:
|
||||
.Bd -literal -offset indent
|
||||
sntrup761x25519-sha512,
|
||||
[email protected],
|
||||
curve25519-sha256,[email protected],
|
||||
ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,
|
||||
|
||||
@@ -1037,11 +1037,14 @@ ecdh-sha2-nistp384
|
||||
.It
|
||||
ecdh-sha2-nistp521
|
||||
.It
|
||||
sntrup761x25519-sha512
|
||||
.It
|
||||
[email protected]
|
||||
.El
|
||||
.Pp
|
||||
The default is:
|
||||
.Bd -literal -offset indent
|
||||
sntrup761x25519-sha512,
|
||||
[email protected],
|
||||
curve25519-sha256,[email protected],
|
||||
ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,
|
||||
|
||||
Reference in New Issue
Block a user