summaryrefslogtreecommitdiff
path: root/backport-fix-possible-NULL-deref-when-built-without-FIDO.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-07-03 02:42:38 +0000
committerCoprDistGit <infra@openeuler.org>2024-07-03 02:42:38 +0000
commit3c362eae690284f325824e38431881825e32ffdd (patch)
treed2d0e11b92bf88d35c270559d268845d391a4703 /backport-fix-possible-NULL-deref-when-built-without-FIDO.patch
parent62f0a34c39a6846b6a86f2bbc7fb8c319bd46d94 (diff)
automatic import of openssh
Diffstat (limited to 'backport-fix-possible-NULL-deref-when-built-without-FIDO.patch')
-rw-r--r--backport-fix-possible-NULL-deref-when-built-without-FIDO.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/backport-fix-possible-NULL-deref-when-built-without-FIDO.patch b/backport-fix-possible-NULL-deref-when-built-without-FIDO.patch
new file mode 100644
index 0000000..125a41b
--- /dev/null
+++ b/backport-fix-possible-NULL-deref-when-built-without-FIDO.patch
@@ -0,0 +1,30 @@
+From 7d25b37fb2a5ff4dadabcbdac6087a97479434f5 Mon Sep 17 00:00:00 2001
+From: Damien Miller <djm@mindrot.org>
+Date: Fri, 24 Jun 2022 13:46:39 +1000
+Subject: [PATCH] fix possible NULL deref when built without FIDO
+
+Analysis/fix from kircher in bz3443; ok dtucker@
+---
+ ssh-sk.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/ssh-sk.c b/ssh-sk.c
+index d254e77..79bc682 100644
+--- a/ssh-sk.c
++++ b/ssh-sk.c
+@@ -118,10 +118,11 @@ sshsk_open(const char *path)
+ ret->sk_enroll = ssh_sk_enroll;
+ ret->sk_sign = ssh_sk_sign;
+ ret->sk_load_resident_keys = ssh_sk_load_resident_keys;
++ return ret;
+ #else
+ error("internal security key support not enabled");
++ goto fail;
+ #endif
+- return ret;
+ }
+ if ((ret->dlhandle = dlopen(path, RTLD_NOW)) == NULL) {
+ error("Provider \"%s\" dlopen failed: %s", path, dlerror());
+--
+1.8.3.1
+