jirafeau: 4.4.0 -> 4.7.2 (#545876)

This commit is contained in:
Thomas Gerbet
2026-08-02 17:29:24 +00:00
committed by GitHub
3 changed files with 20 additions and 5 deletions
+1 -1
View File
@@ -52,7 +52,7 @@ in
'';
description =
let
documentationLink = "https://gitlab.com/mojo42/Jirafeau/-/blob/${cfg.package.version}/lib/config.original.php";
documentationLink = "https://gitlab.com/jirafeau/Jirafeau/-/blob/${cfg.package.version}/lib/config.original.php";
in
''
Jirefeau configuration. Refer to <${documentationLink}> for supported
+15
View File
@@ -18,5 +18,20 @@
machine.wait_for_unit("nginx.service")
machine.wait_for_open_port(80)
machine.succeed("curl -sSfL http://localhost/ | grep 'Jirafeau'")
machine.succeed("printf '%s' '<svg xmlns=\"http://www.w3.org/2000/svg\"><script>alert(1)</script></svg>' > /tmp/preview.svg")
link = machine.succeed(
"curl --fail --silent --show-error "
"-F time=month -F 'file=@/tmp/preview.svg;type=image' "
"http://localhost/script.php"
).splitlines()[0]
headers = machine.succeed(
f"curl --fail --silent --show-error --dump-header - "
f"--output /tmp/preview-response 'http://localhost/f.php?h={link}&p=1'"
)
header_lines = {line.lower() for line in headers.splitlines()}
assert "x-content-type-options: nosniff" in header_lines
assert "content-type: image" in header_lines
machine.succeed("cmp /tmp/preview.svg /tmp/preview-response")
'';
}
+4 -4
View File
@@ -14,13 +14,13 @@ let
in
stdenv.mkDerivation (finalAttrs: {
pname = "jirafeau";
version = "4.4.0";
version = "4.7.2";
src = fetchFromGitLab {
owner = "mojo42";
owner = "jirafeau";
repo = "Jirafeau";
rev = finalAttrs.version;
hash = "sha256-jJ2r8XTtAzawTVo2A2pDwy7Z6KHeyBkgXXaCPY0w/rg=";
hash = "sha256-zCmSdlHkYQVQXBeVk8AUPoC0UBxz3hWIdM2tGmnLTrw=";
};
installPhase = ''
@@ -34,7 +34,7 @@ stdenv.mkDerivation (finalAttrs: {
meta = {
description = "Website permitting upload of a file in a simple way and giving a unique link to it";
license = lib.licenses.agpl3Plus;
homepage = "https://gitlab.com/mojo42/Jirafeau";
homepage = "https://gitlab.com/jirafeau/Jirafeau";
platforms = lib.platforms.all;
maintainers = [ ];
};