<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/bin/rm, branch stable/14</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=stable%2F14</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=stable%2F14'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2023-08-16T17:55:15Z</updated>
<entry>
<title>Remove $FreeBSD$: one-line nroff pattern</title>
<updated>2023-08-16T17:55:15Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:55:15Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=b2c76c41be32f904179efed29c0ca04d53f3996c'/>
<id>urn:sha1:b2c76c41be32f904179efed29c0ca04d53f3996c</id>
<content type='text'>
Remove /^\.\\"\s*\$FreeBSD\$$\n/
</content>
</entry>
<entry>
<title>Remove $FreeBSD$: one-line sh pattern</title>
<updated>2023-08-16T17:55:03Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:55:03Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=d0b2dbfa0ecf2bbc9709efc5e20baf8e4b44bbbf'/>
<id>urn:sha1:d0b2dbfa0ecf2bbc9709efc5e20baf8e4b44bbbf</id>
<content type='text'>
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
</content>
</entry>
<entry>
<title>Remove $FreeBSD$: one-line .c pattern</title>
<updated>2023-08-16T17:54:42Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:54:42Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=1d386b48a555f61cb7325543adbbb5c3f3407a66'/>
<id>urn:sha1:1d386b48a555f61cb7325543adbbb5c3f3407a66</id>
<content type='text'>
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
</content>
</entry>
<entry>
<title>Update/fix Makefile.depend for userland</title>
<updated>2023-04-19T00:14:23Z</updated>
<author>
<name>Simon J. Gerraty</name>
<email>sjg@FreeBSD.org</email>
</author>
<published>2023-04-19T00:14:23Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=d9a42747950146bf03cda7f6e25d219253f8a57a'/>
<id>urn:sha1:d9a42747950146bf03cda7f6e25d219253f8a57a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fts_read: Handle error from a NULL return better.</title>
<updated>2020-12-08T23:38:26Z</updated>
<author>
<name>Bryan Drewery</name>
<email>bdrewery@FreeBSD.org</email>
</author>
<published>2020-12-08T23:38:26Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=2dfa4b66b3d0caaaae6ce2df476b5615f8415a19'/>
<id>urn:sha1:2dfa4b66b3d0caaaae6ce2df476b5615f8415a19</id>
<content type='text'>
This is addressing cases such as fts_read(3) encountering an [EIO]
from fchdir(2) when FTS_NOCHDIR is not set.  That would otherwise be
seen as a successful traversal in some of these cases while silently
discarding expected work.

As noted in r264201, fts_read() does not set errno to 0 on a successful
EOF so it needs to be set before calling it.  Otherwise we might see
a random error from one of the iterations.

gzip is ignoring most errors and could be improved separately.

Reviewed by:	vangyzen
Sponsored by:	Dell EMC
Differential Revision:	https://reviews.freebsd.org/D27184
</content>
</entry>
<entry>
<title>Remove include of stdint.h.  It was added in r241014 for uintmax_t,</title>
<updated>2020-04-23T03:46:41Z</updated>
<author>
<name>Xin LI</name>
<email>delphij@FreeBSD.org</email>
</author>
<published>2020-04-23T03:46:41Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=201ee4ae977e1213650abd2ea73fa0e884d0735f'/>
<id>urn:sha1:201ee4ae977e1213650abd2ea73fa0e884d0735f</id>
<content type='text'>
which is gone in r340330 and is therefore no longer necessary.

MFC after:	2 weeks
</content>
</entry>
<entry>
<title>rm(1): Formalize non-functional status of -P flag</title>
<updated>2018-11-10T20:26:55Z</updated>
<author>
<name>Conrad Meyer</name>
<email>cem@FreeBSD.org</email>
</author>
<published>2018-11-10T20:26:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=900c4ed3ca131f4985bfc0b7e073c5a7430cc2b0'/>
<id>urn:sha1:900c4ed3ca131f4985bfc0b7e073c5a7430cc2b0</id>
<content type='text'>
-P was introduced in 4.4BSD-Lite2 around 1994.  It overwrote file contents
with a pass of 0xff, 0x00, then 0xff, in a low effort attempt to "really
delete" files.

It has no user-visible effect; at the end of the day, the file is unlinked via
the filesystem.  Furthermore, the utility of overwriting files with patterned
data is extremely limited due to caveats at every layer of the stack[0] and
therefore mostly futile.  At the least, three passes is likely wasteful on
modern hardware[1].  It could also be seen as a violation of the "Unix
Philosophy" to do one thing per tiny, composable program.

Since 1994, FreeBSD has left it alone; OpenBSD replaced it with a single
pass of arc4random(3) output in 2012[2]; and NetBSD implemented partial, but
explicitly incomplete support for U.S. DoD 5220.22-M, "National Industrial
Security Program Operating Manual" in 2004[3].

NetBSD's enhanced comment above rm_overwrite makes a strong case for removing
the flag entirely:

&gt; This is an expensive way to keep people from recovering files from your
&gt; non-snapshotted FFS filesystems using fsdb(8).  Really.  No more.
&gt;
&gt; It is impossible to actually conform to the exact procedure given in
&gt; [NISPOM] if one is overwriting a file, not an entire disk, because the
&gt; procedure requires examination and comparison of the disk's defect lists.
&gt; Any program that claims to securely erase *files* while conforming to the
&gt; standard, then, is not correct.
&gt;
&gt; Furthermore, the presence of track caches, disk and controller write
&gt; caches, and so forth make it extremely difficult to ensure that data have
&gt; actually been written to the disk, particularly when one tries to repeatedly
&gt; overwrite the same sectors in quick succession.  We call fsync(), but
&gt; controllers with nonvolatile cache, as well as IDE disks that just plain lie
&gt; about the stable storage of data, will defeat this.
&gt;
&gt; [NISPOM] requires physical media destruction, rather than any technique of
&gt; the sort attempted here, for secret data.

As a first step towards evental removal, make it a placebo.  It's not like
it was serving any security function.  It is not defined in or mentioned by
POSIX.

If you are security conscious and need to erase your files, use a
woodchipper.  At a minimum, the entire disk needs to be overwritten, not
just one file.

[0]: https://www.ru.nl/publish/pages/909282/draft-paper.pdf
[1]: https://commons.erau.edu/cgi/viewcontent.cgi?article=1131&amp;context=jdfsl
[2]: https://github.com/openbsd/src/commit/7c5c57ba81b5fe8ff2d4899ff643af18c
[3]: https://github.com/NetBSD/src/commit/fdf0a7a25e59af958fca1e2159921562cd

Reviewed by:	markj, Daniel O'Connor &lt;darius AT dons.net.au&gt; (previous version)
Differential Revision:	https://reviews.freebsd.org/D17906
</content>
</entry>
<entry>
<title>Fix unlink(1) for files starting with -</title>
<updated>2018-09-12T19:41:16Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2018-09-12T19:41:16Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=19b4f0dca0cf914fa9a60c824f5dfe6be962c703'/>
<id>urn:sha1:19b4f0dca0cf914fa9a60c824f5dfe6be962c703</id>
<content type='text'>
Restore the original behavior of unlink(1), passing the provided filename
directly to unlink(2), handling the first argument being "--" correctly.

This fixes "unlink -foo", broken in r97533.

PR:		228448
Submitted by:	Brennan Vincent &lt;brennan@umanwizard.com&gt; (original version)
Submitted by:	Yuri Pankov
Reported by:	Brennan Vincent &lt;brennan@umanwizard.com&gt;
Reviewed by:	emaste, kevans, vangyzen, 0mp
Approved by:	re (delphij)
Differential Revision: https://reviews.freebsd.org/D17132
</content>
</entry>
<entry>
<title>General further adoption of SPDX licensing ID tags.</title>
<updated>2017-11-20T19:49:47Z</updated>
<author>
<name>Pedro F. Giffuni</name>
<email>pfg@FreeBSD.org</email>
</author>
<published>2017-11-20T19:49:47Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=8a16b7a18f5d0b031f09832fd7752fba717e2a97'/>
<id>urn:sha1:8a16b7a18f5d0b031f09832fd7752fba717e2a97</id>
<content type='text'>
Mainly focus on files that use BSD 3-Clause license.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.
</content>
</entry>
<entry>
<title>Fix cosmetic nit when printing out "override $mode" and "$owner/$group ..."</title>
<updated>2017-11-05T21:43:26Z</updated>
<author>
<name>Enji Cooper</name>
<email>ngie@FreeBSD.org</email>
</author>
<published>2017-11-05T21:43:26Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=6f74a1c9525640ad47ff5755074b1869c187a589'/>
<id>urn:sha1:6f74a1c9525640ad47ff5755074b1869c187a589</id>
<content type='text'>
The wrong index was being checked for == ' ' in the resulting stringified
mode from strmode(3) -- it should have been the 11th value, not the 10th.

MFC after:	3 days
PR:		76711
Submitted by:	Vasil Dimov &lt;vd@datamax.bg&gt;
</content>
</entry>
</feed>
