Browse Source

Merge pull request #15744 from neheb/jose

jose: update to 11
lilik-openwrt-22.03
Rosen Penev 4 years ago
committed by GitHub
parent
commit
97c47cd88a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 62 deletions
  1. +10
    -10
      libs/jose/Makefile
  2. +0
    -31
      libs/jose/patches/010-fix_minor_leak_upstream_198f720.patch
  3. +0
    -21
      libs/jose/patches/020-openssl-deprecated.patch

+ 10
- 10
libs/jose/Makefile View File

@ -8,26 +8,27 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=jose
PKG_VERSION:=10
PKG_RELEASE:=2
PKG_VERSION:=11
PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=https://github.com/latchset/$(PKG_NAME)/releases/download/v$(PKG_VERSION)/
PKG_HASH:=5c9cdcfb535c4d9f781393d7530521c72b1dd81caa9934cab6dd752cc7efcd72
PKG_HASH:=e272afe7717e22790c383f3164480627a567c714ccb80c1ee96f62c9929d8225
PKG_INSTALL:=1
PKG_BUILD_PARALLEL:=1
PKG_MAINTAINER:=Tibor Dudlák <tibor.dudlak@gmail.com>
PKG_LICENSE:=Apache-2.0
PKG_LICENSE_FILES:=COPYING
PKG_FIXUP:=autoreconf
PKG_BUILD_DEPENDS:=meson/host
include $(INCLUDE_DIR)/package.mk
include ../../devel/meson/meson.mk
define Package/libjose
SECTION:=libs
TITLE:=Provides a full crypto stack including key generation, signing and encryption.
DEPENDS:=+zlib +jansson +libopenssl +libpthread
URL:=https://github.com/latchset/jose
MAINTAINER:=Tibor Dudlák <tibor.dudlak@gmail.com>
endef
define Package/jose
@ -35,7 +36,6 @@ define Package/jose
TITLE:=Provides a full crypto stack including key generation, signing and encryption.
DEPENDS:=+libjose
URL:=https://github.com/latchset/jose
MAINTAINER:=Tibor Dudlák <tibor.dudlak@gmail.com>
endef
define Package/jose/description
@ -57,7 +57,7 @@ define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib$(PKG_NAME).so* $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/include/$(PKG_NAME)/*.h $(1)/usr/include/$(PKG_NAME)
$(CP) $(PKG_BUILD_DIR)/*.pc $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/*.pc $(1)/usr/lib/pkgconfig
endef
define Package/libjose/install


+ 0
- 31
libs/jose/patches/010-fix_minor_leak_upstream_198f720.patch View File

@ -1,31 +0,0 @@
From 198f7207427ad7f569aa3592ea16e2bb400db040 Mon Sep 17 00:00:00 2001
From: Nathaniel McCallum <npmccallum@redhat.com>
Date: Fri, 29 Sep 2017 14:49:57 -0400
Subject: [PATCH] Fix minor FILE* leak
---
cmd/jwe/pwd.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
--- a/cmd/jwe/pwd.h
+++ b/cmd/jwe/pwd.h
@@ -57,8 +57,10 @@ jwe_getpass(const char *prompt)
nf.c_lflag &= ~ECHO;
nf.c_lflag |= ECHONL;
- if (tcsetattr(fileno(tty), TCSANOW, &nf) != 0)
+ if (tcsetattr(fileno(tty), TCSANOW, &nf) != 0) {
+ fclose(tty);
return NULL;
+ }
fprintf(tty, "%s", prompt);
@@ -72,6 +74,7 @@ jwe_getpass(const char *prompt)
}
tcsetattr(fileno(tty), TCSANOW, &of);
+ fclose(tty);
return pwd;
}
#endif

+ 0
- 21
libs/jose/patches/020-openssl-deprecated.patch View File

@ -1,21 +0,0 @@
--- a/lib/openssl/compat.h
+++ b/lib/openssl/compat.h
@@ -17,6 +17,7 @@
#pragma once
+#include <openssl/bn.h>
#include <openssl/hmac.h>
#include <openssl/ec.h>
#include <openssl/ecdsa.h>
--- a/lib/openssl/misc.c
+++ b/lib/openssl/misc.c
@@ -185,6 +185,8 @@ add_entity(json_t *root, json_t *obj, co
static void __attribute__((constructor))
constructor(void)
{
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
OpenSSL_add_all_algorithms();
+#endif
RAND_poll();
}

Loading…
Cancel
Save