From nobody Thu Jul 03 19:24:57 2025 X-Original-To: freebsd-current@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 4bY6D11v1Tz60y7x for ; Thu, 03 Jul 2025 19:25:05 +0000 (UTC) (envelope-from wjw@digiware.nl) Received: from mail.digiware.nl (smtp.digiware.nl [176.74.240.9]) by mx1.freebsd.org (Postfix) with ESMTP id 4bY6Cz44Dbz3rvM for ; Thu, 03 Jul 2025 19:25:03 +0000 (UTC) (envelope-from wjw@digiware.nl) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=digiware.nl header.s=medusa-2017 header.b=grlzGuqX; spf=pass (mx1.freebsd.org: domain of wjw@digiware.nl designates 176.74.240.9 as permitted sender) smtp.mailfrom=wjw@digiware.nl; dmarc=pass (policy=quarantine) header.from=digiware.nl Received: from [IPV6:2001:4cb8:3:1:148f:848e:f00:1728] (unknown [IPv6:2001:4cb8:3:1:148f:848e:f00:1728]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mail.digiware.nl (Postfix) with ESMTPSA id 959389BD46; Thu, 03 Jul 2025 21:24:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=digiware.nl; s=medusa-2017; t=1751570695; bh=p0KTmanuFirTU1LZXZ/hIN3Jlncz0LqoZLtJS1nMclM=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=grlzGuqXwhdDbcA7NWexpuwmlS664+mTK+BAal2hPKDSU1WZCDI6tRADEjlq25+Js dg635uwg7kdMBrkcNO2l2Q4WRcW+uUCmGar01dDYYbWT5tKSglNf4+mmo8BXz9budF lCmYPFctnyW3n2IRBvfoGjBdZfl2cQYcUe2URnKre/cQXfT2a1ja15X867hYEfcANu SKQDes9WHwckmGV/NlAYUmCRjHGjtvNAYZcs2NuqcQBcQaLMO53HM2J9IjfZwTEgR8 bFZKNpYK/7iEujXNav9tMFBh0atPcTdZTu3UK4v7HiEcJlfbGNmNG05gcG1Wtqs41s 3780JN2cq3MuA== Content-Type: multipart/alternative; boundary="------------tvZJghMj4zjnXAFD2PbT3p0B" Message-ID: <3a05b953-cfba-4cd2-a1ea-22348702563f@digiware.nl> Date: Thu, 3 Jul 2025 21:24:57 +0200 List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: RFC: checking file systems support UF_HIDDEN, UF_SYSTEM To: Rick Macklem , Shawn Webb Cc: FreeBSD CURRENT References: <5emcw3uocuaenm2lwdrqqvxgiqpo7uazon6y2hzelhi5qjxxj4@trymutqekdiy> Content-Language: nl, en-GB From: Willem Jan Withagen In-Reply-To: X-Rspamd-Server: router10G.digiware.nl X-Rspamd-Action: no action X-Spamd-Result: default: False [-2.14 / 15.00]; NEURAL_HAM_SHORT(-0.83)[-0.828]; NEURAL_HAM_LONG(-0.82)[-0.817]; DMARC_POLICY_ALLOW(-0.50)[digiware.nl,quarantine]; NEURAL_SPAM_MEDIUM(0.20)[0.201]; R_DKIM_ALLOW(-0.20)[digiware.nl:s=medusa-2017]; R_SPF_ALLOW(-0.20)[+mx]; ONCE_RECEIVED(0.20)[]; RCVD_NO_TLS_LAST(0.10)[]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; FROM_EQ_ENVFROM(0.00)[]; ARC_NA(0.00)[]; ASN(0.00)[asn:28878, ipnet:176.74.224.0/19, country:NL]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FROM_HAS_DN(0.00)[]; RCVD_COUNT_ONE(0.00)[1]; RCVD_VIA_SMTP_AUTH(0.00)[]; TAGGED_RCPT(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; FREEMAIL_TO(0.00)[gmail.com,hardenedbsd.org]; TO_DN_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; MLMMJ_DEST(0.00)[freebsd-current@freebsd.org]; DKIM_TRACE(0.00)[digiware.nl:+] X-Rspamd-Queue-Id: 4bY6Cz44Dbz3rvM X-Spamd-Bar: -- This is a multi-part message in MIME format. --------------tvZJghMj4zjnXAFD2PbT3p0B Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 2-7-2025 23:45, Rick Macklem wrote: > I don't know why or when these were added to FreeBSD, but I believe > their origin is in MSDOS long ago. The fat file system had these two flags > that MSDOS used, called "hiiden" and "system". > I believe "hidden" is somewhat similar to POSIX file > names that start with "." and "system" made the file harder to delete. > (But, I hate to admit I even recall anything about MSDOS;-) > > If you google "windows system and hidden" you'll get something that > might answer your question, thanks to their AI This happens when you grow old, memory starts acting up. ;-) I even wrote a CPM and DOS driver for a wierd HD controller we had lying around from some Unix  projects. (5 MB disks.) But in MS-DOS the system flag was for files that were needed by the DOS system and should not be deleted easily, so basically files were hidden and not deletable.... But with the right tools the flag was easily removed. (anybody remember Norton disk editor?) In essence it was a rather useless flag, it looked interesting but did very little. Once Long FileNames on FAT were created that was indicated by ORing all flags... READ_ONLY=0x01 HIDDEN=0x02 SYSTEM=0x04 VOLUME_ID=0x08 DIRECTORY=0x10 ARCHIVE=0x20 LFN=READ_ONLY|HIDDEN|SYSTEM|VOLUME_ID So not sure it that would be of interest in representing a FAT filesystem over NFS4 This is from an MS-DOS manual I had in my archives: In MS-DOS, the "system" file attribute, when set, indicates that a file is a critical system file required by the operating system.These files are typically hidden from casual access and should not be deleted, renamed, or moved without specific knowledge of the potential consequences. Here's a more detailed explanation: * *System Attribute:* This attribute is part of the file's metadata and tells the operating system that the file is essential for its proper functioning. * *Hidden from View:* Files with the system attribute set are usually hidden from standard directory listings (like when you use the |DIR| command). * *Protection:* The system attribute helps prevent accidental modification or deletion of crucial files, ensuring the operating system remains stable. * *Examples:* Files like |IO.SYS|, |MSDOS.SYS|, and |COMMAND.COM| in MS-DOS are typically marked with the system attribute. * *Advanced Users:* While the system attribute offers protection, advanced users can still access and manipulate these files using specific commands or tools, but this is generally not recommended unless you understand the implications. --WjW --------------tvZJghMj4zjnXAFD2PbT3p0B Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit

On 2-7-2025 23:45, Rick Macklem wrote:
I don't know why or when these were added to FreeBSD, but I believe
their origin is in MSDOS long ago. The fat file system had these two flags
that MSDOS used, called "hiiden" and "system".
I believe "hidden" is somewhat similar to POSIX file
names that start with "." and "system" made the file harder to delete.
(But, I hate to admit I even recall anything about MSDOS;-)

If you google "windows system and hidden" you'll get something that
might answer your question, thanks to their AI

This happens when you grow old, memory starts acting up. ;-)
I even wrote a CPM and DOS driver for a wierd HD controller we had lying around from some
Unix  projects. (5 MB disks.)

But in MS-DOS the system flag was for files that were needed by the DOS system
and should not be deleted easily, so basically files were hidden and not deletable....
But with the right tools the flag was easily removed. (anybody remember Norton disk editor?)

In essence it was a rather useless flag, it looked interesting but did very little.

Once Long FileNames on FAT were created that was indicated by ORing all flags...
READ_ONLY=0x01 HIDDEN=0x02 SYSTEM=0x04 VOLUME_ID=0x08 DIRECTORY=0x10 ARCHIVE=0x20 LFN=READ_ONLY|HIDDEN|SYSTEM|VOLUME_ID
So not sure it that would be of interest in representing a FAT filesystem over NFS4

This is from an MS-DOS manual I had in my archives:

In MS-DOS, the "system" file attribute, when set, indicates that a file is a critical system file required by the operating system. These files are typically hidden from casual access and should not be deleted, renamed, or moved without specific knowledge of the potential consequences. 
Here's a more detailed explanation: 
  • System Attribute:
    This attribute is part of the file's metadata and tells the operating system that the file is essential for its proper functioning.
  • Hidden from View:
    Files with the system attribute set are usually hidden from standard directory listings (like when you use the DIR command).
  • Protection:
    The system attribute helps prevent accidental modification or deletion of crucial files, ensuring the operating system remains stable.
  • Examples:
    Files like IO.SYS, MSDOS.SYS, and COMMAND.COM in MS-DOS are typically marked with the system attribute.
  • Advanced Users:
    While the system attribute offers protection, advanced users can still access and manipulate these files using specific commands or tools, but this is generally not recommended unless you understand the implications.

--WjW

--------------tvZJghMj4zjnXAFD2PbT3p0B--