Merge pull request #120855 from LeSuisse/composer-CVE-2021-29472

phpPackages.composer: 2.0.12 -> 2.0.13, 1.10.15 -> 1.10.22
This commit is contained in:
Elis Hirwing 2021-04-27 17:24:00 +02:00 committed by GitHub
commit c75166fbd8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 4 deletions

View File

@ -1,14 +1,14 @@
{ mkDerivation, fetchurl, makeWrapper, unzip, lib, php }:
let
pname = "composer";
version = "1.10.15";
version = "1.10.22";
in
mkDerivation {
inherit pname version;
src = fetchurl {
url = "https://getcomposer.org/download/${version}/composer.phar";
sha256 = "1shsxsrc2kq74s1jbq3njn9wzidcz7ak66n9vyz8z8d0hqpg37d6";
sha256 = "00073smi1jja00d4bqfs6p4fqs38mki2ziy7b1kwsmiv5lcsw9v1";
};
dontUnpack = true;
@ -16,11 +16,13 @@ mkDerivation {
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
runHook preInstall
mkdir -p $out/bin
install -D $src $out/libexec/composer/composer.phar
makeWrapper ${php}/bin/php $out/bin/composer \
--add-flags "$out/libexec/composer/composer.phar" \
--prefix PATH : ${lib.makeBinPath [ unzip ]}
runHook postInstall
'';
meta = with lib; {

View File

@ -1,14 +1,14 @@
{ mkDerivation, fetchurl, makeWrapper, unzip, lib, php }:
let
pname = "composer";
version = "2.0.12";
version = "2.0.13";
in
mkDerivation {
inherit pname version;
src = fetchurl {
url = "https://getcomposer.org/download/${version}/composer.phar";
sha256 = "sha256-guqMFTfPrOt+VvYATHzN+Z3a/OcjfAc3TZIOY1cwpjE=";
sha256 = "sha256-EW/fB8ySavZGY1pqvJLYiv97AqXcNlOPgcUKfSc2bb8=";
};
dontUnpack = true;
@ -16,11 +16,13 @@ mkDerivation {
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
runHook preInstall
mkdir -p $out/bin
install -D $src $out/libexec/composer/composer.phar
makeWrapper ${php}/bin/php $out/bin/composer \
--add-flags "$out/libexec/composer/composer.phar" \
--prefix PATH : ${lib.makeBinPath [ unzip ]}
runHook postInstall
'';
meta = with lib; {