]> git.p6c8.net - jirafeau/jirafeau.git/commitdiff
Merge branch 'next-release' into 'next-release'
authorPatrick Canterino <patrick@patrick-canterino.de>
Wed, 12 Aug 2026 11:25:44 +0000 (13:25 +0200)
committerPatrick Canterino <patrick@patrick-canterino.de>
Wed, 12 Aug 2026 11:25:44 +0000 (13:25 +0200)
Promoting MR 35 to Next-Rrelease Except the Password Hashing that is Already Implemented

See merge request jirafeau/Jirafeau!37

19 files changed:
.gitlab-ci.yml
AUTHORS.md
CHANGELOG.md
docker/docker_config.php
f.php
index.php
lib/config.original.php
lib/functions.js.php
lib/functions.php
lib/settings.php
media/courgette/style.css.php
media/dark-courgette/style.css.php
media/elegantish/elegantish.css
media/elegantish/style.css.php
media/industrial/style.css.php
media/jyraphe/style.css.php
media/modern/favicon.ico [new file with mode: 0644]
media/modern/style.css.php
script.php

index 627ed17edeafe41783446928a7827acd4a27ba9b..613ab9b6e3d819a399ed152c4000ba77d8bc8c47 100644 (file)
@@ -3,10 +3,12 @@ cache:
   paths:
     - vendor/
 
-# Run tests for php:8.2
-job_lint_app_82:
-  image: php:8.2
-  before_script: &before_linter_script
+# Aliases and Anchors for reuse
+
+.linter_script: &linter_script
+    - ./vendor/bin/parallel-lint --gitlab --exclude vendor .
+    - ./vendor/bin/php-cs-fixer -vvv check . --using-cache=no --rules=@PSR12,-single_space_around_construct
+.before_script: &before_linter_script
     # Install git, the docker php image doesn't have it installed by default
     - apt-get update -yqq
     - apt-get install git -yqq
@@ -17,24 +19,63 @@ job_lint_app_82:
     - curl -sS https://getcomposer.org/installer | php
     # Create composer.json file manually, since this is a project without any non-dev dependencies yet
     - php composer.phar require --dev php-parallel-lint/php-parallel-lint
-    - php composer.phar require --dev friendsofphp/php-cs-fixer:3.64.0
+    - php composer.phar require --dev friendsofphp/php-cs-fixer:3.93.1
     # Install all project dependencies
     - php composer.phar install
-  script: &linter_script
-    - ./vendor/bin/parallel-lint --exclude vendor .
-    - ./vendor/bin/php-cs-fixer -vvv check . --using-cache=no --rules=@PSR12,-single_space_around_construct
+
+.enableWarningOnFailure: &linter_warning
+  allow_failure:
+      exit_codes:
+        - 1
+
+
+# Run tests for php:8.5
+job_lint_app_85:
+  image: php:8.5
+  before_script: *before_linter_script
+  script: *linter_script
+
+# Run tests for php:8.4
+job_lint_app_84:
+  image: php:8.4
+  before_script: *before_linter_script
+  script: *linter_script
+
+job_lint_app_83:
+  image: php:8.3
+  before_script: *before_linter_script
+  script: *linter_script
+
+# Run tests for php:8.2
+job_lint_app_82:
+  image: php:8.2
+  before_script: *before_linter_script
+  script: *linter_script
+
+
+# =================
+# Deprecated ones START
+# =================
 
 # Run tests for php:8.1
 job_lint_app_81:
   image: php:8.1
   before_script: *before_linter_script
   script: *linter_script
+  <<: *linter_warning
+  
+
 
 # Run tests for php:7.4
 job_lint_app_74:
   image: php:7.4
   before_script: *before_linter_script
   script: *linter_script
+  <<: *linter_warning
+
+# =================
+# Deprecated ones END
+# =================
 
 publish:
   image: docker:latest
index 98e175b70d0aee4da41464c71954ef9e4732faa2..9eaa5e5b785c2775ff4e28599435715058eae969 100644 (file)
@@ -104,6 +104,7 @@ This is a list of people who contributed to Jirafeau over the years. The list wa
 - Sven Dickert
 - Sylke Vicious
 - Szylu
+- TehPeGaSuS
 - Thomas LEBEAU
 - Thomas Sontheimer
 - Tymofij Lytvynenko
index c687514260f7a45c49182f7d5326c9737ddc1163..a85065ce8f489c14f4124d11e0c996334d286a4d 100644 (file)
 5. Follow the installation wizard, it should propose you the same data folder or even update automatically
 6. Check your `/lib/config.local.php` and compare it with the `/lib/config.original.php` to see if new configuration items are available. If a new item is missing in your `config.local.php`, this may trigger some errors as Jirafeau may expect to have them.
 
+## Version 4.7.x (not yet released)
+
+- ...
+
+## Version 4.7.2
+
+- Added a button for showing the download password before uploading the file
+- Favicon was missing in the `modern` theme
+- Download passwords are now stored as SHA256 hashes
+- Downloading encrypted files uploaded using "classic upload" (using just plain HTTP POST without the HTML5 file API) could not be downloaded. This was caused by not correctly marking the files as encrypted.
+- Few more little fixes
+- Upgrade from 4.7.1: in-place upgrade
+
 ## Version 4.7.1
 
-- Fixed another possibility to bypass the checks for [CVE-2022-30110](https://www.cve.org/CVERecord?id=CVE-2022-30110), [CVE-2024-12326](https://www.cve.org/CVERecord?id=CVE-2024-12326) and [CVE-2025-7066](https://www.cve.org/CVERecord?id=CVE-2025-7066) (prevent preview of SVG images and other critical files) by sending a manipulated HTTP request with a MIME type like "image". When doing the preview, the browser tries to automatically detect the MIME type resulting in detecting SVG and possibly executing JavaScript code. To prevent this, MIME sniffing is disabled.
+- Fixed another possibility to bypass the checks for [CVE-2022-30110](https://www.cve.org/CVERecord?id=CVE-2022-30110), [CVE-2024-12326](https://www.cve.org/CVERecord?id=CVE-2024-12326) and [CVE-2025-7066](https://www.cve.org/CVERecord?id=CVE-2025-7066) (prevent preview of SVG images and other critical files) by sending a manipulated HTTP request with a MIME type like "image". When doing the preview, the browser tries to automatically detect the MIME type resulting in detecting SVG and possibly executing JavaScript code. To prevent this, MIME sniffing is disabled. This issue has subsequently been reported as [CVE-2026-1466](https://www.cve.org/CVERecord?id=CVE-2026-1466).
 - The default value of `max_upload_chunk_size_bytes` was set to `5000000`. Higher values could trigger a bug Chromium-based browsers on servers with HTTP/3 enabled, causing asynchronous uploads to fail.
 - Docker image: Updated PHP to 8.3 and removed `mime-types.conf` from `lighttpd.conf`
 - Upgrade from 4.7.0: in-place upgrade, you also should set `max_upload_chunk_size_bytes` to `5000000` in your `config.local.php`!
index 6037ec6434c17337d19c033b205d69f904e191c2..d814a8e678303c029f31bb1adf7d72dfcc6184b7 100644 (file)
@@ -194,6 +194,7 @@ function run_setup(&$cfg)
     env_2_cfg_bool($cfg, 'one_time_download_preselected');
     env_2_cfg_bool($cfg, 'enable_crypt');
     env_2_cfg_bool($cfg, 'debug');
+    env_2_cfg_bool($cfg, 'debug_enforce_classic_upload');
     env_2_cfg_int($cfg, 'maximal_upload_size');
     env_2_cfg_string_array($cfg, 'upload_password');
     env_2_cfg_string_array($cfg, 'upload_ip');
diff --git a/f.php b/f.php
index b13e03b8144679e4b0e6e041268379b46c1ed94a..352359668f61c4cf7b4b1a06f1d019df7ca77ed5 100644 (file)
--- a/f.php
+++ b/f.php
@@ -171,7 +171,9 @@ if (!empty($link['key'])) {
         require(JIRAFEAU_ROOT.'lib/template/footer.php');
         exit;
     } else {
-        if (hash_equals($link['key'], md5($_POST['key']))) {
+        if (strpos($link['key'], '[SHA256]') == 0 && hash_equals(substr($link['key'], 8), hash('sha256', $_POST['key']))) {
+            $password_challenged = true;
+        } elseif (hash_equals($link['key'], md5($_POST['key']))) {
             $password_challenged = true;
         } else {
             sleep(2);
index 74c68a059aeb79e83cb90076b7c13062475f37c2..d60cb1809dfebb56b6e8f8295ca6b054d6e43269 100644 (file)
--- a/index.php
+++ b/index.php
@@ -156,14 +156,16 @@ if ($cfg['download_password_requirement'] === 'generated') {
     echo '<input type="hidden" name="key" id="input_key" value="' . $download_pass .'"/>';
 } else {
     echo '<tr><td><label for="input_key">' . t('PSW') . ':' . '</label></td>';
-    echo '<td><input type="password" name="key" id="input_key" autocomplete = "new-password"';
+    echo '<td class="passwordcolumn"><input type="password" name="key" id="input_key" autocomplete = "new-password"';
     if ($cfg['download_password_policy'] === 'regex') {
         echo ' pattern="' . jirafeau_escape(substr($cfg['download_password_policy_regex'], 1, strlen($cfg['download_password_policy_regex']) - 2)) . '"'; //remove php delimiters
     }
     if ($cfg['download_password_requirement'] === 'required') {
         echo ' required';
     }
-    echo '/></td></tr>';
+    echo ' /> <button data-toggle="false" type="button" id="show_password">
+    </button>';
+    echo '</td></tr>';
 }?>
         <tr>
         <td><label for="select_time"><?php echo t('TIME_LIM') . ':'; ?></label></td>
@@ -206,6 +208,20 @@ if ($cfg['maximal_upload_size'] >= 1024) {
 
 <script type="text/javascript" lang="Javascript">
 // @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-v3-or-Later
+    // ICONS in SVG
+    const EYE_OPEN = `<svg width="20" height="20" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" aria-hidden="true" version="1.1" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
+ <path d="m1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" stroke-width="1.7604"/>
+ <circle cx="12" cy="12" r="3"/>
+ <path d="m2.9757 2.7901 18.56 18.546" display="none" fill="none" stroke="#000" stroke-width="1.7604"/>
+</svg>`;
+    const EYE_CLOSE = `<svg width="20" height="20" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" aria-hidden="true" version="1.1" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
+ <path d="m1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" stroke-width="1.7604"/>
+ <circle cx="12" cy="12" r="3"/>
+ <path d="m2.9757 2.7901 18.56 18.546" fill="none" stroke="#000" stroke-width="1.7604"/>
+</svg>`;
+
+
+
     document.getElementById('error_pop').style.display = 'none';
     document.getElementById('uploading').style.display = 'none';
     document.getElementById('upload_finished').style.display = 'none';
@@ -225,5 +241,22 @@ if ($max_size > 0) {
     addCopyListener('delete_link_button', 'delete_link');
     addTextCopyListener('password_copy_button', 'output_key');
 // @license-end
+// show password toggle
+    document.getElementById('show_password').innerHTML = EYE_OPEN;
+    document.getElementById('show_password')?.addEventListener('click', function() {
+        const pwd = document.getElementById('input_key');
+        const show_password = pwd.type === 'text';
+        const next_show_password_toggle_value  = !show_password;
+        if (next_show_password_toggle_value) {
+            pwd.type = 'text';
+            document.getElementById('show_password').setAttribute('data-show-enabled', true);
+            // symbol eye strikethrough
+            document.getElementById('show_password').innerHTML = EYE_CLOSE;
+        } else {
+            pwd.type = 'password';
+            // symbol eye 
+            document.getElementById('show_password').innerHTML = EYE_OPEN;
+        }
+    });
 </script>
 <?php require(JIRAFEAU_ROOT . 'lib/template/footer.php'); ?>
index 6b7c342e51cf7a1402774266016c0862f14a770c..37c87ebc573d6d6db4637d2c815c658980291c5c 100644 (file)
@@ -235,6 +235,10 @@ $cfg['installation_done'] = false;
  */
 $cfg['debug'] = false;
 
+/* Enable this debug flag to enforce the classic (synchronous) file upload mechanism.
+ */
+$cfg['debug_enforce_classic_upload'] = false;
+
 /* Set Jirafeau's maximal upload chunk
  * When Jirafeau upload a large file, Jirafeau sends several data chunks to fit server's capabilities.
  * Jirafeau tries to upload each data chunk with the maximal size allowed by PHP (post_max_size and upload_max_filesize).
index 29d50c198edfbc321a0d1855eadd8624f4baa15b..cafecafcdc0f6fcd19ade0b89944ec80c86daad8 100644 (file)
@@ -430,9 +430,9 @@ function classic_upload (file, time, password, one_time)
     req.upload.addEventListener ("progress", upload_progress, false);
     req.addEventListener ("error", XHRErrorHandler, false);
     req.addEventListener ("abort", XHRErrorHandler, false);
-    req.onreadystatechange = function ()
+    req.onload = function ()
     {
-        if (req.readyState == 4 && req.status == 200)
+        if (req.status === 200)
         {
             var res = req.responseText;
 
@@ -479,6 +479,13 @@ function classic_upload (file, time, password, one_time)
 
 function check_html5_file_api ()
 {
+<?php
+    if (isset($cfg['debug_enforce_classic_upload']) && $cfg['debug_enforce_classic_upload']) { ?>
+    // Enforce classic upload is enabled through config!
+    return false;
+<?php
+    }
+?>
     return window.File && window.FileReader && window.FileList && window.Blob;
 }
 
index 84bcea8ebaff44c805ac6a33d4b03c8abcd39c32..6c8d56db6b839b9d7cf6fc786be1d00540587eca 100644 (file)
@@ -464,9 +464,9 @@ function jirafeau_handle_add_file_encryption($crypt_module_enabled, $file_path)
         error_log("PHP extension sodium not loaded, won't encrypt in Jirafeau");
     }
     if ($crypt_module_enabled == true && extension_loaded('sodium') == true) {
-        $crypt_key = jirafeau_encrypt_file($file_path, $file_path.'crypt');
+        $crypt_key = jirafeau_encrypt_file($file_path, $file_path.'.crypt');
         if (strlen($crypt_key) > 0) {
-            if (rename($file_path.'crypt', $file_path) === true) {
+            if (rename($file_path.'.crypt', $file_path) === true) {
                 $crypted = true;
             }
         }
@@ -544,7 +544,7 @@ function jirafeau_add_file($file, $one_time_download, $key, $time, $ip, $crypt,
     /* hash password or empty. */
     $password = '';
     if (!empty($key)) {
-        $password = md5($key);
+        $password = '[SHA256]' . hash('sha256', $key);
     }
 
     /* create link file */
@@ -554,7 +554,7 @@ function jirafeau_add_file($file, $one_time_download, $key, $time, $ip, $crypt,
         $handle,
         $name . NL. $mime_type . NL. $size . NL. $password . NL. $time .
             NL . $hash. NL . ($one_time_download ? 'O' : 'R') . NL . time() .
-            NL . $ip . NL. $delete_link_code . NL . ($crypted ? 'C' : 'O')
+            NL . $ip . NL. $delete_link_code . NL . ($crypted ? 'C2' : 'O')
     );
     fclose($handle);
     $hash_link = substr(base_16_to_64(md5_file($link_tmp_name)), 0, $link_name_length);
@@ -947,6 +947,7 @@ function jirafeau_admin_bug_report($cfg)
     $out .= "- version: " . JIRAFEAU_VERSION . "<br/>";
     $jirafeau_options = [
         'debug',
+        'debug_enforce_classic_upload',
         'file_hash',
         'litespeed_workaround',
         'store_uploader_ip',
@@ -1088,10 +1089,10 @@ function jirafeau_async_init($filename, $type, $one_time, $key, $time, $ip)
     $w_path = $p . $ref . '_data';
     touch($w_path);
 
-    /* md5 password or empty */
+    /* sha256 password or empty */
     $password = '';
     if (!empty($key)) {
-        $password = md5($key);
+        $password = '[SHA256]' . hash('sha256', $key);
     }
 
     /* Store information. */
@@ -1642,7 +1643,7 @@ function jirafeau_escape($string)
 function jirafeau_admin_session_start()
 {
     $_SESSION['admin_auth'] = true;
-    $_SESSION['admin_csrf'] = md5(uniqid(mt_rand(), true));
+    $_SESSION['admin_csrf'] = hash('sha256', uniqid(mt_rand(), true));
 }
 
 function jirafeau_session_end()
index 5a8d3a7948dfdd27f0a05713470237e654757af0..e015067bd45e9345de460ff77f6536e77478d0ac 100644 (file)
@@ -43,7 +43,7 @@ if ($cfg['debug'] === true) {
 
 /* Jirafeau package */
 define('JIRAFEAU_PACKAGE', 'Jirafeau');
-define('JIRAFEAU_VERSION', '4.7.1');
+define('JIRAFEAU_VERSION', '4.7.x-dev');
 
 define('JIRAFEAU_WEBSITE', 'https://gitlab.com/jirafeau/Jirafeau');
 
index 4b75988ead60e3cbaedf804feef29d20c1b3a79a..7623cd5d5c1d258d4d4c17174cc64284ea9e7db0 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
- *  Jyraphe, your web file repository
- *  Copyright (C) 2013
- *  Jerome Jutteau <jerome@jutteau.fr>
- *  Jimmy Beauvois <jimmy.beauvois@gmail.com>
+ *  Jirafeau, your web file repository
+ *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
@@ -20,7 +20,7 @@
  */
 
 /*
- * This stylesheet is the default stylesheet for Jyraphe.
+ * This stylesheet is the default stylesheet for Jirafeau.
  * The content is dynamically generated for easier handling.
  */
 
@@ -286,6 +286,26 @@ input[type="submit"]:focus {
   background: url(email.png) no-repeat;
 }
 
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
+
 /* ==========================================================================
    5 = Terms of service
    ========================================================================== */
index 3657b87080f1b95b860d0f964290e5fc2382760a..7a577c91015a02f53b17161d6aa9fa980ae938dc 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
- *  Jyraphe, your web file repository
- *  Copyright (C) 2013
- *  Jerome Jutteau <jerome@jutteau.fr>
- *  Jimmy Beauvois <jimmy.beauvois@gmail.com>
+ *  Jirafeau, your web file repository
+ *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
@@ -20,7 +20,7 @@
  */
 
 /*
- * This stylesheet is the default stylesheet for Jyraphe.
+ * This stylesheet is the default dark mode stylesheet for Jirafeau.
  * The content is dynamically generated for easier handling.
  */
 
@@ -289,6 +289,26 @@ input[type="submit"]:focus {
   background: url(email.png) no-repeat;
 }
 
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
+
 /* ==========================================================================
    5 = Terms of service
    ========================================================================== */
@@ -471,4 +491,4 @@ textarea[readonly="readonly"] + p + p a:focus {
   padding-left: 40px;
   padding-top: 10px;
   padding-bottom: 10px;
-}
+}
\ No newline at end of file
index 7e04ac8624353de5512fa9f930406815d410d40b..253bcd018f4c25aff524331a3698d4980bd57814 100644 (file)
@@ -286,6 +286,26 @@ input[type="submit"]:focus {
   background: url(email.png) no-repeat;
 }
 
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
+
 /* ==========================================================================
    5 = Terms of service
    ========================================================================== */
index 71071956966a178c655d065fc5498825edf7ed86..401b37aa1c9cad30dda8081fb5dd53457e4e9504 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
- *  Jyraphe, your web file repository
- *  Copyright (C) 2013
- *  Jerome Jutteau <jerome@jutteau.fr>
- *  Jimmy Beauvois <jimmy.beauvois@gmail.com>
+ *  Jirafeau, your web file repository
+ *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
  *  along with this program.  If not, see <https://www.gnu.org/licenses/>.
  */
 
-/*
- * This stylesheet is the default stylesheet for Jyraphe.
- * The content is dynamically generated for easier handling.
- */
-
 $dark = '#8B4513';
 
 header('Content-type: text/css');
index 34d9990ec4b6c1f0fc306002550f52578933d0d5..f28921e0a6a87448fb5900e52a6e3ca90538fadf 100644 (file)
@@ -1,7 +1,9 @@
 <?php
 /*
- *  Jyraphe, your web file repository
+ *  Jirafeau, your web file repository
  *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
  *  along with this program.  If not, see <https://www.gnu.org/licenses/>.
  */
 
-/*
- * This stylesheet is the default stylesheet for Jyraphe.
- * The content is dynamically generated for easier handling.
- */
-
 $dark = '#8B4513';
 
 header('Content-type: text/css');
@@ -193,3 +190,23 @@ input:hover {
   padding-bottom: 15px;
   background: url(email.png) no-repeat;
 }
+
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
index 1a2b7896ced501fc74dcc262c66b2e30a2d2c396..517ae1c9d25a0e28f60cf60e01b83837fa28c878 100644 (file)
@@ -2,6 +2,8 @@
 /*
  *  Jirafeau, your web file repository
  *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
  *  along with this program.  If not, see <https://www.gnu.org/licenses/>.
  */
 
-/*
- * This stylesheet is the default stylesheet for Jirafeau.
- * The content is dynamically generated for easier handling.
- */
-
 $dark = '#8B4513';
 
 header('Content-type: text/css');
@@ -241,3 +238,23 @@ h1 a {
   padding-left: 20px;
   background: url(email.png) no-repeat;
 }
+
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
\ No newline at end of file
diff --git a/media/modern/favicon.ico b/media/modern/favicon.ico
new file mode 100644 (file)
index 0000000..c42c696
Binary files /dev/null and b/media/modern/favicon.ico differ
index fcdf9ca0e9c948fb10306e222018af4a20444fee..e40760a46febc2f7f4375412503c4ca0aa626cd4 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
- *  Jyraphe, your web file repository
- *  Copyright (C) 2013
- *  Jerome Jutteau <jerome@jutteau.fr>
- *  Jimmy Beauvois <jimmy.beauvois@gmail.com>
+ *  Jirafeau, your web file repository
+ *  Copyright (C) 2008  Julien "axolotl" BERNARD <axolotl@magieeternelle.org>
+ *  Copyright (C) 2015  Jerome Jutteau <jerome@jutteau.fr>
+ *  Copyright (C) 2024  Jirafeau project <https://gitlab.com/jirafeau> (see AUTHORS.md)
  *
  *  This program is free software: you can redistribute it and/or modify
  *  it under the terms of the GNU Affero General Public License as
  *  along with this program.  If not, see <https://www.gnu.org/licenses/>.
  */
 
-/*
- * This stylesheet is the default stylesheet for Jyraphe.
- * The content is dynamically generated for easier handling.
- */
-
 $dark = '#8B4513';
 
 header('Content-type: text/css');
@@ -233,3 +228,23 @@ font-size:90%;
   padding-left: 20px;
   background: url(email.png) no-repeat;
 }
+
+#show_password {
+  flex: 1 1 auto;
+  position: absolute;
+  right: 0%;
+  background: none;
+  border: none;
+  cursor: pointer;
+  opacity: 30%;
+}
+#show_password:hover {
+  opacity: 100%;
+}
+
+.passwordcolumn {
+  display: flex;
+  position: relative;
+  align-items: center;
+  width: 100%;
+}
index cc37c41351569b620b3767f9c3309af1f6345b6a..2fc297f3412302a0933ef91d3d85f82560c49df9 100644 (file)
@@ -183,7 +183,7 @@ if (isset($_FILES['file']) && is_writable(VAR_FILES)
         echo 'Error 9';
         exit;
     }
-    if (strlen($link['key']) > 0 && md5($key) != $link['key']) {
+    if (strlen($link['key']) > 0 && hash('sha256', $key) != $link['key']) {
         sleep(2);
         echo 'Error 10';
         exit;

patrick-canterino.de