From nobody Wed Sep 18 16:02:50 2024 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4X83MZ3kL8z5WhCf; Wed, 18 Sep 2024 16:02:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4X83MZ39zfz4PNW; Wed, 18 Sep 2024 16:02:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1726675370; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5ToHinzrm90ubtiuN3yqEx0xHzVIxK3UWpfnwBDNfC4=; b=YPBoKHfcfdzKEeVWPo+s4GHlLZgkfpI4souKdHGGc/2nu1WvMDaZCunbMMmNy2+P1iIV9J 0ZjPoM9fOIOLlDz2voaZ2lnz32AIAnABPdVArUhYpX70UOclhOa/3Thu668L+Ked6vByp5 OSRadHOhuYbHyUpvD0YIszXaW/tyiN6YzDGV+qu84AcSSIlcHQSE7nvtIaUb1IbISYeyTF y6ZskNIcxHwDkKNCZiSLxcWbFZ0jocLRgyugfQ6ThkDj7SQwtzPit3gdXnOc/IL6avtMO4 QpJXukn2/+2E/br0JpF0+DLK7rqwidzxn9fbIN5IZ2euVJ9jd8YiIIPLOkMEBQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1726675370; a=rsa-sha256; cv=none; b=t5QG7Lvx5Wa6zcYrASO9nmGren4kvOaNX4VhUk4FZLI3T4UmYxadIiCfifVlcbz+j5qOvY hMy1v1nqeGa5zhncvUO0KKRclIj8MWcdL9hq5PunlFhmJXsRvjD+4zVfV9Z0BBbsP6be1k PEI6v+tTm3Hmlo0zTHZ1aFCSxN8pym6/SK457fzoh4yiiE5By0RDDB1skF6j3un6TaDdQP 71aX/0/ajoCdKGGexb6imKRkNFIW0sYaY0O+PeR8H7fdHIbCinu9HPL/7BqmfeR7sqTdUM eV+skAn5dII9iQ9mKX3x/M3AcM1w5exvS1DBLxeCCJ67+yoHGAgDRLtA6Cy0Tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1726675370; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=5ToHinzrm90ubtiuN3yqEx0xHzVIxK3UWpfnwBDNfC4=; b=uYXCCEg2el/8iKZYm0TZfc7z+z66BQt3qmzcRt7zSHWgx28vLM0x5YXF7SCX9NCcwz68/q XfMRTrdOKwNADZVt2oR24BTYA1WXUUf8z816AdnsV+PLkjXDsIWXtdNG5u03yNdqUbHewm 7IL9yfGKAUaQ5Sh4g63vmBLVHBRPj1tvAzRZyJM59spPkErvMa/hk87RDvOB2bcC7EvBBj URTqrsslKNFzDiK+gafjkMA7pxkGC+lNG3I39F+SQieSe61Osv/8F0mjr+4arZxOIr+5yn PB7phWOq4Ecb6ZpocdehixLlqBPpzHmcCABNbJ8ZAFuVCydYTcmMmEtNxWFbeQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4X83MZ2nVTzT2R; Wed, 18 Sep 2024 16:02:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 48IG2oWi056556; Wed, 18 Sep 2024 16:02:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 48IG2oT2056553; Wed, 18 Sep 2024 16:02:50 GMT (envelope-from git) Date: Wed, 18 Sep 2024 16:02:50 GMT Message-Id: <202409181602.48IG2oT2056553@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Alexander Leidinger Subject: git: dfd76d00018c - main - www/lua-resty-session3: port sticking to version 3 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: netchild X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: dfd76d00018cdfd270368acba037c9811ebd8b51 Auto-Submitted: auto-generated The branch main has been updated by netchild: URL: https://cgit.FreeBSD.org/ports/commit/?id=dfd76d00018cdfd270368acba037c9811ebd8b51 commit dfd76d00018cdfd270368acba037c9811ebd8b51 Author: Baptiste Grenier AuthorDate: 2024-08-30 20:12:38 +0000 Commit: Alexander Leidinger CommitDate: 2024-09-18 16:02:45 +0000 www/lua-resty-session3: port sticking to version 3 This is based upon www/lua-resty-session (v4), but is needed for lua-resty-openidc. The version 3.x is pinned in the lua-resty-openidc dependencies: https://github.com/zmartzone/lua-resty-openidc/blob/9f3a4fcade930f6f38ee0cb43cabf50cebffbcc9/lua-resty-openidc-1.7.6-3.rockspec#L27 There is apparently currently no clear plan on when/if lua-resty-openidc will be updated to include changes for lua-resty-session 4.X, see discussions on https://github.com/zmartzone/lua-resty-openidc/issues/480 Additionally to what the author submitted some changes by me: - add conflicts with www/lua-resty-session - give up maintainership of www/lua-resty-session PR: 281142 --- www/Makefile | 1 + www/lua-resty-session/Makefile | 5 +++- www/lua-resty-session3/Makefile | 60 ++++++++++++++++++++++++++++++++++++++++ www/lua-resty-session3/distinfo | 3 ++ www/lua-resty-session3/pkg-descr | 8 ++++++ 5 files changed, 76 insertions(+), 1 deletion(-) diff --git a/www/Makefile b/www/Makefile index 4c6716d695e9..55b17bc10a45 100644 --- a/www/Makefile +++ b/www/Makefile @@ -336,6 +336,7 @@ SUBDIR += lua-resty-http SUBDIR += lua-resty-lrucache SUBDIR += lua-resty-session + SUBDIR += lua-resty-session3 SUBDIR += luakit SUBDIR += luakit-devel SUBDIR += lux diff --git a/www/lua-resty-session/Makefile b/www/lua-resty-session/Makefile index 79467f829c00..805670eb2db7 100644 --- a/www/lua-resty-session/Makefile +++ b/www/lua-resty-session/Makefile @@ -1,9 +1,10 @@ PORTNAME= lua-resty-session +PORTREVISION= 1 DISTVERSIONPREFIX=v DISTVERSION= 4.0.5 CATEGORIES= www -MAINTAINER= netchild@FreeBSD.org +MAINTAINER= ports@FreeBSD.org COMMENT= Lua session library for OpenResty / ngx_lua WWW= https://github.com/bungle/lua-resty-session @@ -13,6 +14,8 @@ LICENSE_FILE= ${WRKSRC}/LICENSE RUN_DEPENDS= luajit-openresty>=2.1:lang/luajit-openresty # XXX: deps for filesystem, postgres, redis backends missing +CONFLICTS_INSTALL= lua-resty-session-3* + USE_GITHUB= yes GH_ACCOUNT= bungle diff --git a/www/lua-resty-session3/Makefile b/www/lua-resty-session3/Makefile new file mode 100644 index 000000000000..0d058fb59bac --- /dev/null +++ b/www/lua-resty-session3/Makefile @@ -0,0 +1,60 @@ +PORTNAME= lua-resty-session +DISTVERSIONPREFIX=v +DISTVERSION= 3.10 +CATEGORIES= www + +MAINTAINER= baptiste@bapt.name +COMMENT= Lua session library for OpenResty / ngx_lua Version 3.x +WWW= https://github.com/bungle/lua-resty-session + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +RUN_DEPENDS= luajit-openresty>=2.1:lang/luajit-openresty +# XXX: deps for filesystem, postgres, redis backends missing + +CONFLICTS_INSTALL= lua-resty-session-4* + +USE_GITHUB= yes +GH_ACCOUNT= bungle + +NO_ARCH= yes +NO_BUILD= yes + +LUA_MODSHAREDIR=${LOCALBASE}/share/lua/5.1 + +PLIST_FILES+= ${LUA_MODSHAREDIR}/resty/session.lua \ + ${LUA_MODSHAREDIR}/resty/session/ciphers/aes.lua \ + ${LUA_MODSHAREDIR}/resty/session/ciphers/none.lua \ + ${LUA_MODSHAREDIR}/resty/session/compressors/none.lua \ + ${LUA_MODSHAREDIR}/resty/session/compressors/zlib.lua \ + ${LUA_MODSHAREDIR}/resty/session/encoders/base16.lua \ + ${LUA_MODSHAREDIR}/resty/session/encoders/base64.lua \ + ${LUA_MODSHAREDIR}/resty/session/encoders/hex.lua \ + ${LUA_MODSHAREDIR}/resty/session/hmac/sha1.lua \ + ${LUA_MODSHAREDIR}/resty/session/identifiers/random.lua \ + ${LUA_MODSHAREDIR}/resty/session/serializers/json.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/cookie.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/dshm.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/memcache.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/memcached.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/redis.lua \ + ${LUA_MODSHAREDIR}/resty/session/storage/shm.lua \ + ${LUA_MODSHAREDIR}/resty/session/strategies/default.lua \ + ${LUA_MODSHAREDIR}/resty/session/strategies/regenerate.lua + +PORTDOCS= README.md + +DOCSDIR= ${PREFIX}/share/doc/lua${LUA_VER_STR}/${PORTNAME} + +OPTIONS_DEFINE= DOCS + +do-install: + @${MKDIR} ${STAGEDIR}${LUA_MODSHAREDIR} + @(cd ${WRKSRC}/lib && ${COPYTREE_SHARE} . ${STAGEDIR}${LUA_MODSHAREDIR} "-name *\.lua") + +do-install-DOCS-on: + @${MKDIR} ${STAGEDIR}${DOCSDIR} + @${INSTALL_DATA} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR} + +.include diff --git a/www/lua-resty-session3/distinfo b/www/lua-resty-session3/distinfo new file mode 100644 index 000000000000..78c09b6dfda3 --- /dev/null +++ b/www/lua-resty-session3/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1725035042 +SHA256 (bungle-lua-resty-session-v3.10_GH0.tar.gz) = 89ac564760d6a870b12f694dd23f123f8e2d5425c297bc10a8f1738528ec9bce +SIZE (bungle-lua-resty-session-v3.10_GH0.tar.gz) = 32125 diff --git a/www/lua-resty-session3/pkg-descr b/www/lua-resty-session3/pkg-descr new file mode 100644 index 000000000000..2bb13b386f5f --- /dev/null +++ b/www/lua-resty-session3/pkg-descr @@ -0,0 +1,8 @@ +Lua session library for OpenResty / ngx_lua + +Features: + - Sessions are immutable (each save generates a new session), and lockless. + - Session data is AES-256-GCM encrypted with a key derived using HKDF-SHA256. + - Session has a fixed size header that is protected with HMAC-SHA256 MAC with a key derived using HKDF-SHA256. + - Session data can be stored in a stateless cookie or in various backend storages. + - A single session cookie can maintain multiple sessions across different audiences.