Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2224859/?format=api
{ "id": 2224859, "url": "http://patchwork.ozlabs.org/api/patches/2224859/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20260418223850.20351-2-ablagodarenko@ddn.com/", "project": { "id": 8, "url": "http://patchwork.ozlabs.org/api/projects/8/?format=api", "name": "Linux ext4 filesystem development", "link_name": "linux-ext4", "list_id": "linux-ext4.vger.kernel.org", "list_email": "linux-ext4@vger.kernel.org", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260418223850.20351-2-ablagodarenko@ddn.com>", "list_archive_url": null, "date": "2026-04-18T22:38:50", "name": "[2/2] ext4/065 encryption + casefold + dirdata feature combination", "commit_ref": null, "pull_url": null, "state": "not-applicable", "archived": false, "hash": "c54cdf35a35e137fa9cbc27b2e44a32d551588f8", "submitter": { "id": 70973, "url": "http://patchwork.ozlabs.org/api/people/70973/?format=api", "name": "Artem Blagodarenko", "email": "artem.blagodarenko@gmail.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20260418223850.20351-2-ablagodarenko@ddn.com/mbox/", "series": [ { "id": 500476, "url": "http://patchwork.ozlabs.org/api/series/500476/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/list/?series=500476", "date": "2026-04-18T22:38:49", "name": "[1/2] ext4/064 encryption + casefold feature combination WITHOUT dirdata", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/500476/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2224859/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2224859/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "\n <SRS0=VRLe=CR=vger.kernel.org=linux-ext4+bounces-15899-patchwork-incoming=ozlabs.org@ozlabs.org>", "X-Original-To": [ "incoming@patchwork.ozlabs.org", "linux-ext4@vger.kernel.org" ], "Delivered-To": [ "patchwork-incoming@legolas.ozlabs.org", "patchwork-incoming@ozlabs.org" ], "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=BtfKktuC;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=ozlabs.org\n (client-ip=2404:9400:2221:ea00::3; helo=mail.ozlabs.org;\n envelope-from=srs0=vrle=cr=vger.kernel.org=linux-ext4+bounces-15899-patchwork-incoming=ozlabs.org@ozlabs.org;\n receiver=patchwork.ozlabs.org)", "gandalf.ozlabs.org;\n arc=pass smtp.remote-ip=\"2600:3c0a:e001:db::12fc:5321\"\n arc.chain=subspace.kernel.org", "gandalf.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=gmail.com", "gandalf.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=BtfKktuC;\n\tdkim-atps=neutral", "gandalf.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-ext4+bounces-15899-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org)", "smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com\n header.b=\"BtfKktuC\"", "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=209.85.128.52", "smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=gmail.com", "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=gmail.com" ], "Received": [ "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1 raw public key)\n server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fymtd0R4Lz1yGs\n\tfor <incoming@patchwork.ozlabs.org>; Sun, 19 Apr 2026 08:40:57 +1000 (AEST)", "from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3])\n\tby gandalf.ozlabs.org (Postfix) with ESMTP id 4fymtd0Gvmz4wCp\n\tfor <incoming@patchwork.ozlabs.org>; Sun, 19 Apr 2026 08:40:57 +1000 (AEST)", "by gandalf.ozlabs.org (Postfix)\n\tid 4fymtd0BzYz4wH2; Sun, 19 Apr 2026 08:40:57 +1000 (AEST)", "from sea.lore.kernel.org (sea.lore.kernel.org\n [IPv6:2600:3c0a:e001:db::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby gandalf.ozlabs.org (Postfix) with ESMTPS id 4fymtY48w0z4wCp\n\tfor <patchwork-incoming@ozlabs.org>; Sun, 19 Apr 2026 08:40:53 +1000 (AEST)", "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sea.lore.kernel.org (Postfix) with ESMTP id A5EE9300BCA9\n\tfor <patchwork-incoming@ozlabs.org>; Sat, 18 Apr 2026 22:39:10 +0000 (UTC)", "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id E1F1634FF41;\n\tSat, 18 Apr 2026 22:39:09 +0000 (UTC)", "from mail-wm1-f52.google.com (mail-wm1-f52.google.com\n [209.85.128.52])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 0D9AB338593\n\tfor <linux-ext4@vger.kernel.org>; Sat, 18 Apr 2026 22:39:07 +0000 (UTC)", "by mail-wm1-f52.google.com with SMTP id\n 5b1f17b1804b1-4888375f735so20483765e9.3\n for <linux-ext4@vger.kernel.org>;\n Sat, 18 Apr 2026 15:39:07 -0700 (PDT)", "from Cluster1.local ([2a00:23c7:90c1:9201:ef47:d559:d907:fd0b])\n by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-488fc177dafsm201330545e9.4.2026.04.18.15.39.05\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Sat, 18 Apr 2026 15:39:05 -0700 (PDT)" ], "ARC-Seal": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1776552056; cv=pass;\n\tb=nJBoyWKgP0IALuQ6hGj2tuR2fE70qZ1ZmSzHW8FV/4fDtdZoKVIFt04I8TC7caNqM44bgkwqyiolRrNF9w+i79I9eSpQIGlIQ4/r/sq68eRBIMEno+rYPjFW+SKwODumAJRmtn1oCf87rSWlYhj0o9TdZgn4S6Y21aPcTwCNKTfORmLKl/kHqY0oIDRpPqTlt15qPuTyou8BDfeLYFSBwInpCb5MJ1nLwiEMeCbI7NZpurE8TdfA8Cwu+AyRyYQFoNYAexlyNozXDe2SCRfmB8ah0F1jZc/t5Tcy7KN/KbJzFfvGX9imaxilSuVTammZE8NtpPo9yf20IDGWYqwjjw==", "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1776551949; cv=none;\n b=Gz9RK18ITFC93kkHv8MH9Hr8w7qk8sUYYyfSEA65+s8UKVWA7fXJqBIUIO7aoNeWYQY8mj+bscrworobM6OB1ONsJY6/BLxHSUewn8NriSfp5G7ZfE5KgdAcwBgD08KcIUoxJ4xbyzQUiL1ntb6YIy7l7T3UkAI8jQvI76yK9io=" ], "ARC-Message-Signature": [ "i=2; a=rsa-sha256; d=ozlabs.org; s=201707;\n\tt=1776552056; c=relaxed/relaxed;\n\tbh=JizdQQUWo88QZWsvp/MEmuK2lZp6YdT42tANpTBZ+Gc=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=BnG8WLoD42+QGvPQ6hR8XtwQe/yiOW6B/aC1Ok5NKGPUiRHfBPja1XskNioEwUGQtH8HtGC4rFgQvlFmfYqnpZNszlya9JxXKJGA6Ctm/H7VjaQRj2I5+ZRT37uhrbtX/o7FP5wCODR73GFApcu8Qy1GWkIb/I6bWH7yRWvGGo0vn4hzVYTOqPzKjbVAdn5K/hsJjEhmO6Qb1tO/QJfYYV7ISDJxQFtuwAmbdbmo8ztL2eo3MbbRNky3J8weyBAUG6itQu62a/4ljNlvNwTyur/mp9NH8+1B47xaYJuJVxv7ehFBYgH+YhU6flwtQZ+4n5cUZHXGkB3JPyggjTFJyw==", "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1776551949; c=relaxed/simple;\n\tbh=TH+1KVvOdG0Ck9pqvalAAoLcVoUj0MFTTnvpwNe6ltM=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=Mp1Wmfg6I3Wq03B7eF2G8esrsTZ30l8F41RDlUAZctdDTkUcilOMNbdDlVuRqMPV7Y++fKh0VgzY7b4wUPaBZGZTsl0mSc/boq1fXCVlHv3KXfOjrKFF4z/oes9fZbvL6/Id3m8QEOoeIqrSWdyofrCOxPTpSVtonEnw/GyauqQ=" ], "ARC-Authentication-Results": [ "i=2; gandalf.ozlabs.org;\n dmarc=pass (p=none dis=none) header.from=gmail.com; dkim=pass (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=BtfKktuC; dkim-atps=neutral;\n spf=pass (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-ext4+bounces-15899-patchwork-incoming=ozlabs.org@vger.kernel.org;\n receiver=ozlabs.org) smtp.mailfrom=vger.kernel.org", "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=gmail.com;\n spf=pass smtp.mailfrom=gmail.com;\n dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com\n header.b=BtfKktuC; arc=none smtp.client-ip=209.85.128.52" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20251104; t=1776551946; x=1777156746;\n darn=vger.kernel.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=JizdQQUWo88QZWsvp/MEmuK2lZp6YdT42tANpTBZ+Gc=;\n b=BtfKktuCFnlTKXTYspdtdTJaAKej2Zrv+nUlEwXb6JpJFTPkcu/sTEbTxWVix6tKJZ\n BIWLCcfRMLLg5x5Bx+PjsskxW8vi1IDIP79UjSWFpiSLkuWpXATCOt1aX80v2XMBU84S\n m00SIgOQDyy3f6yJ1V8nBTQe84rJPB/fDllLKBujkga15uzkS3YXs5qO6Tk5bxaLQYy7\n K0wZnj3WPRA76xwrd8U/WZtsRsJMJk3cZ0TlY8XemkITX8eCxnfNu1umjgQsA7jZWFa2\n 9M9NzyrrttJZFi7xxwuDsx01W4GdmaDEGPNRBlePi3MgMshptmFB4amFdiaW/9x61bQA\n iJ0A==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776551946; x=1777156746;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=JizdQQUWo88QZWsvp/MEmuK2lZp6YdT42tANpTBZ+Gc=;\n b=Uu9hAwgfJkgC11JC1kFvxK5bOuvaOuhzcLC1jZJL6RA06u5wX/z6NAzyDnrAo5Yrxq\n wrGjJRifJIqkEvbJwiUOlbztpZIuLnMhgC9WjET6M04rCu+00asGPSyWlEkTnlkJIFVN\n U5oBCAWNefKTUhgdBfu8i4NuIwguEzDP7lVxq/U28jGk0dXPHenboS0NzVt1g7dx56Q9\n 7mf619CjQRCiHXygAKxMdKc5m9WBl5Wxla2ZtIfRYbcCP/co9HyRlg6Cl4+BrbPl9P1h\n sLTyYfkGNsVyYK3M0qPPDNWvLNelDM/PQSHNlKEokP/1jPWbnxYbtX0IXYeUDW/Yjq6c\n MICQ==", "X-Gm-Message-State": "AOJu0YyzCEsTi+TwzJ0X5US4X2V4ge1dYw29Vm3aTziRadBnWc5ZXK/Y\n\tbXFPHpa/4Gae+jdSljwSI7/tYlpw2muS/PjV6fxRQiGn5rFLVrPxw4N4WeOmsBR+", "X-Gm-Gg": "AeBDiesqVZmLa+bvagqptbJ4JhkC9bRGCB+pUvqm6TmchInwrZKSimzhwscFMUn07NG\n\tM4LHQYj1iGCyVCTrEWQa1ul2Cbm1ECr8iNFVNNIGKJOK4tq5GAmD8M47EGhuRQX3dKpKKf7vZr9\n\tSHsQOLstGKSA5ntE1JhBISZqJs40YU3ZjaKzngLPG0hZK6OPTjl9rm/4S7p61PECEYhnj7GndbY\n\t1TG8kASN2dcggsvb191kc7kDJ/8Jo9L/oKOB3CwkYiLCWuV5FhBaifrpDUNgkmrFOps+gC1wdQc\n\tpxQZm0xGmH3/hUk9miB5SER1xZNHykaGW9NDahb4U54FfB90syQi5dsnhoieyWhfPFf/dw8SLWK\n\thVFnrntRaZ3wwQjYE58lPNo1NawNImBUjxIjEo1YNgLzamiTEVeRfleq5ANP8x+ygFcV60kITJA\n\t25v/GJpZTCfZoK+JVCs/RTyCIf9eu6WdSsOYp3ZjQjcg==", "X-Received": "by 2002:a05:600c:a116:b0:485:b6dd:5066 with SMTP id\n 5b1f17b1804b1-488fb7471dbmr83261995e9.7.1776551946032;\n Sat, 18 Apr 2026 15:39:06 -0700 (PDT)", "From": "Artem Blagodarenko <artem.blagodarenko@gmail.com>", "X-Google-Original-From": "Artem Blagodarenko <ablagodarenko@ddn.com>", "To": "linux-ext4@vger.kernel.org", "Cc": "adilger.kernel@dilger.ca,\n\tArtem Blagodarenko <artem.blagodarenko@gmail.com>", "Subject": "[PATCH 2/2] ext4/065 encryption + casefold + dirdata feature\n combination", "Date": "Sat, 18 Apr 2026 18:38:50 -0400", "Message-ID": "<20260418223850.20351-2-ablagodarenko@ddn.com>", "X-Mailer": "git-send-email 2.43.5", "In-Reply-To": "<20260418223850.20351-1-ablagodarenko@ddn.com>", "References": "<20260418223850.20351-1-ablagodarenko@ddn.com>", "Precedence": "bulk", "X-Mailing-List": "linux-ext4@vger.kernel.org", "List-Id": "<linux-ext4.vger.kernel.org>", "List-Subscribe": "<mailto:linux-ext4+subscribe@vger.kernel.org>", "List-Unsubscribe": "<mailto:linux-ext4+unsubscribe@vger.kernel.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "X-Spam-Status": "No, score=-1.2 required=5.0 tests=ARC_SIGNED,ARC_VALID,\n\tDKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DMARC_PASS,\n\tFREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,\n\tMAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=disabled\n\tversion=4.0.1", "X-Spam-Checker-Version": "SpamAssassin 4.0.1 (2024-03-25) on gandalf.ozlabs.org" }, "content": "From: Artem Blagodarenko <artem.blagodarenko@gmail.com>\n\nTest ext4 encryption + casefold + dirdata feature combination.\nThis test verifies that files created in directories with encryption,\ncase-insensitive (casefold), and dirdata attributes work correctly.\nSee ext4/064 for the same test WITHOUT dirdata feature.\n\nSigned-off-by: Artem Blagodarenko <artem.blagodarenko@gmail.com>\n---\n tests/ext4/065 | 208 +++++++++++++++++++++++++++++++++++++++++++++\n tests/ext4/065.out | 17 ++++\n 2 files changed, 225 insertions(+)\n create mode 100755 tests/ext4/065\n create mode 100644 tests/ext4/065.out", "diff": "diff --git a/tests/ext4/065 b/tests/ext4/065\nnew file mode 100755\nindex 00000000..08863ac0\n--- /dev/null\n+++ b/tests/ext4/065\n@@ -0,0 +1,208 @@\n+#! /bin/bash\n+# SPDX-License-Identifier: GPL-2.0\n+# Copyright (c) 2026 The Lustre Collective. All Rights Reserved.\n+# Author: Artem Blagodarenko <ablagodarenko@thelustrecollective.com>\n+#\n+# FS QA Test ext4/065\n+#\n+# Test ext4 encryption + casefold + dirdata feature combination.\n+# This test verifies that files created in directories with encryption,\n+# case-insensitive (casefold), and dirdata attributes work correctly.\n+# See ext4/064 for the same test WITHOUT dirdata feature.\n+#\n+. ./common/preamble\n+_begin_fstest auto quick encrypt casefold\n+\n+# get standard environment and checks\n+. ./common/filter\n+. ./common/encrypt\n+. ./common/casefold\n+. ./common/attr\n+\n+_exclude_fs ext2\n+_exclude_fs ext3\n+\n+# Check if dirdata feature is supported and can be used with encrypt+casefold\n+_require_scratch_dirdata()\n+{\n+\tif test ! -f /sys/fs/ext4/features/dirdata ; then\n+\t\t_notrun \"dirdata feature not supported by kernel\"\n+\tfi\n+\n+\t# Debug: log e2fsprogs tool paths and versions\n+\techo \"=== _require_scratch_dirdata debug info ===\" >> $seqres.full\n+\techo \"E2FSCK_PROG: $E2FSCK_PROG\" >> $seqres.full\n+\techo \"E2FSCK_PROG resolved: $(type -P e2fsck)\" >> $seqres.full\n+\techo \"MKFS_EXT4_PROG: $MKFS_EXT4_PROG\" >> $seqres.full\n+\techo \"fsck -t ext4 resolves to: $(type -P fsck.ext4)\" >> $seqres.full\n+\t$E2FSCK_PROG -V >> $seqres.full 2>&1\n+\t$MKFS_EXT4_PROG -V >> $seqres.full 2>&1\n+\techo \"=== end debug info ===\" >> $seqres.full\n+\n+\t# Also verify that mkfs supports dirdata\n+\tif ! $MKFS_EXT4_PROG -O dirdata -n $SCRATCH_DEV &>>$seqres.full ; then\n+\t\t_notrun \"mkfs.ext4 does not support dirdata feature\"\n+\tfi\n+\n+\t# Verify kernel can mount filesystem with encrypt+casefold+dirdata\n+\techo \"Running: _scratch_mkfs -O encrypt,casefold,dirdata\" >> $seqres.full\n+\tif ! _scratch_mkfs -O encrypt,casefold,dirdata &>>$seqres.full ; then\n+\t\t_notrun \"failed to create filesystem with encrypt+casefold+dirdata\"\n+\tfi\n+\tif ! _try_scratch_mount &>>$seqres.full ; then\n+\t\t_notrun \"kernel cannot mount filesystem with encrypt+casefold+dirdata\"\n+\tfi\n+\t_scratch_unmount\n+}\n+\n+_require_scratch_nocheck\n+_require_encrypted_casefold\n+_require_scratch_dirdata\n+_require_command \"$CHATTR_PROG\" chattr\n+_require_command \"$LSATTR_PROG\" lsattr\n+_require_xfs_io_command \"set_encpolicy\"\n+_require_xfs_io_command \"add_enckey\"\n+\n+# Helper to add a v2 encryption key and set policy on a directory\n+_setup_encrypted_casefold_dir()\n+{\n+\tlocal dir=$1\n+\tlocal raw_key=$(_generate_raw_encryption_key)\n+\tlocal keyspec=$(_add_enckey $SCRATCH_MNT \"$raw_key\" | awk '{print $NF}')\n+\t_set_encpolicy $dir $keyspec\n+\t_casefold_set_attr $dir\n+\techo $keyspec\n+}\n+\n+# Create a filesystem with encrypt, casefold, and dirdata features\n+# Debug: log e2fsprogs tool paths and versions\n+echo \"=== e2fsprogs debug info ===\" >> $seqres.full\n+echo \"E2FSCK_PROG: $E2FSCK_PROG\" >> $seqres.full\n+echo \"E2FSCK_PROG resolved: $(type -P e2fsck)\" >> $seqres.full\n+echo \"MKFS_EXT4_PROG: $MKFS_EXT4_PROG\" >> $seqres.full\n+echo \"FSCK_OPTIONS: $FSCK_OPTIONS\" >> $seqres.full\n+echo \"fsck -t ext4 resolves to: $(type -P fsck.ext4)\" >> $seqres.full\n+$E2FSCK_PROG -V >> $seqres.full 2>&1\n+$MKFS_EXT4_PROG -V >> $seqres.full 2>&1\n+echo \"=== end e2fsprogs debug info ===\" >> $seqres.full\n+\n+_scratch_mkfs -O encrypt,casefold,dirdata &>>$seqres.full\n+_scratch_mount\n+\n+# Test 1: Create an encrypted + casefolded directory and verify lookups work\n+echo \"Test 1: Basic encrypted casefold lookup with dirdata\"\n+mkdir $SCRATCH_MNT/test1\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test1 > /dev/null\n+\n+# Create file with lowercase, lookup with uppercase\n+echo \"hello\" > $SCRATCH_MNT/test1/testfile.txt\n+if [ -f \"$SCRATCH_MNT/test1/TESTFILE.TXT\" ]; then\n+\techo \"Case-insensitive lookup works in encrypted dir\"\n+else\n+\techo \"FAIL: Case-insensitive lookup failed in encrypted dir\"\n+fi\n+\n+# Verify the exact name on disk is preserved\n+if _casefold_check_exact_name \"$SCRATCH_MNT/test1\" \"testfile.txt\"; then\n+\techo \"Original filename preserved\"\n+else\n+\techo \"FAIL: Original filename not preserved\"\n+fi\n+\n+# Test 2: Create files with different case variations\n+echo \"Test 2: Conflicting names in encrypted casefold dir\"\n+mkdir $SCRATCH_MNT/test2\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test2 > /dev/null\n+\n+echo \"first\" > $SCRATCH_MNT/test2/MyFile.txt\n+# This should fail or overwrite since \"MYFILE.TXT\" is equivalent\n+echo \"second\" > $SCRATCH_MNT/test2/MYFILE.TXT 2>/dev/null\n+content=$(cat $SCRATCH_MNT/test2/myfile.txt)\n+echo \"Content after writes: $content\"\n+\n+# Test 3: Unicode normalization in encrypted casefold dir\n+echo \"Test 3: Unicode in encrypted casefold dir\"\n+mkdir $SCRATCH_MNT/test3\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test3 > /dev/null\n+\n+# Test with UTF-8 characters\n+fr_file1=$(echo -e \"cafe\\xcc\\x81.txt\")\n+fr_file2=$(echo -e \"caf\\xc3\\xa9.txt\")\n+echo \"french\" > \"$SCRATCH_MNT/test3/$fr_file1\"\n+if [ -f \"$SCRATCH_MNT/test3/$fr_file2\" ]; then\n+\techo \"Unicode normalization works in encrypted dir\"\n+else\n+\techo \"FAIL: Unicode normalization failed in encrypted dir\"\n+fi\n+\n+# Test 4: Directory operations in encrypted casefold dir\n+echo \"Test 4: Directory operations in encrypted casefold dir\"\n+mkdir $SCRATCH_MNT/test4\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test4 > /dev/null\n+\n+mkdir $SCRATCH_MNT/test4/SubDir\n+if [ -d \"$SCRATCH_MNT/test4/SUBDIR\" ]; then\n+\techo \"Directory case-insensitive lookup works\"\n+else\n+\techo \"FAIL: Directory case-insensitive lookup failed\"\n+fi\n+\n+# Test 5: Verify inheritance of casefold+encryption in subdirectories\n+echo \"Test 5: Inheritance of attributes\"\n+mkdir $SCRATCH_MNT/test5\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test5 > /dev/null\n+\n+mkdir $SCRATCH_MNT/test5/child\n+echo \"data\" > $SCRATCH_MNT/test5/child/file.txt\n+if [ -f \"$SCRATCH_MNT/test5/CHILD/FILE.TXT\" ]; then\n+\techo \"Attributes inherited correctly\"\n+else\n+\techo \"FAIL: Attributes not inherited\"\n+fi\n+\n+# Test 6: Remove and recreate with different case\n+echo \"Test 6: Remove and recreate with different case\"\n+mkdir $SCRATCH_MNT/test6\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test6 > /dev/null\n+\n+echo \"original\" > $SCRATCH_MNT/test6/RemoveMe.txt\n+rm $SCRATCH_MNT/test6/REMOVEME.TXT\n+echo \"recreated\" > $SCRATCH_MNT/test6/REMOVEME.TXT\n+if _casefold_check_exact_name \"$SCRATCH_MNT/test6\" \"REMOVEME.TXT\"; then\n+\techo \"Recreated file has new case\"\n+else\n+\techo \"FAIL: Recreated file case incorrect\"\n+fi\n+\n+# Test 7: Hard links in encrypted casefold dir\n+echo \"Test 7: Hard links in encrypted casefold dir\"\n+mkdir $SCRATCH_MNT/test7\n+_setup_encrypted_casefold_dir $SCRATCH_MNT/test7 > /dev/null\n+\n+echo \"linkdata\" > $SCRATCH_MNT/test7/original.txt\n+ln $SCRATCH_MNT/test7/original.txt $SCRATCH_MNT/test7/hardlink.txt\n+if [ -f \"$SCRATCH_MNT/test7/HARDLINK.TXT\" ]; then\n+\techo \"Hard link case-insensitive lookup works\"\n+else\n+\techo \"FAIL: Hard link case-insensitive lookup failed\"\n+fi\n+\n+# Cleanup and verify filesystem\n+_scratch_unmount\n+\n+# Debug: log e2fsprogs tool paths before _check_scratch_fs\n+echo \"=== e2fsprogs debug info (before _check_scratch_fs) ===\" >> $seqres.full\n+echo \"E2FSCK_PROG: $E2FSCK_PROG\" >> $seqres.full\n+echo \"E2FSCK_PROG resolved: $(type -P e2fsck)\" >> $seqres.full\n+echo \"fsck -t ext4 resolves to: $(type -P fsck.ext4)\" >> $seqres.full\n+echo \"FSCK_OPTIONS: $FSCK_OPTIONS\" >> $seqres.full\n+$E2FSCK_PROG -V >> $seqres.full 2>&1\n+echo \"=== end e2fsprogs debug info ===\" >> $seqres.full\n+\n+_check_scratch_fs\n+\n+echo \"Encrypted casefold tests with dirdata completed\"\n+\n+# success, all done\n+status=0\n+exit\ndiff --git a/tests/ext4/065.out b/tests/ext4/065.out\nnew file mode 100644\nindex 00000000..e771d884\n--- /dev/null\n+++ b/tests/ext4/065.out\n@@ -0,0 +1,17 @@\n+QA output created by 065\n+Test 1: Basic encrypted casefold lookup with dirdata\n+Case-insensitive lookup works in encrypted dir\n+Original filename preserved\n+Test 2: Conflicting names in encrypted casefold dir\n+Content after writes: second\n+Test 3: Unicode in encrypted casefold dir\n+Unicode normalization works in encrypted dir\n+Test 4: Directory operations in encrypted casefold dir\n+Directory case-insensitive lookup works\n+Test 5: Inheritance of attributes\n+Attributes inherited correctly\n+Test 6: Remove and recreate with different case\n+Recreated file has new case\n+Test 7: Hard links in encrypted casefold dir\n+Hard link case-insensitive lookup works\n+Encrypted casefold tests with dirdata completed\n", "prefixes": [ "2/2" ] }