| #
632c73b4
|
| 09-Feb-2026 |
Tuukka Pasanen <tuukka.pasanen@ilmi.fi> |
sh: Add SPDX-License-Identifier tags
Reviewed by: imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D55213
|
| #
e043f372
|
| 24-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
bin: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remov
bin: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
show more ...
|
| #
90aea514
|
| 23-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
bin: Remove ancient SCCS tags.
Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl s
bin: Remove ancient SCCS tags.
Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl script.
Sponsored by: Netflix
show more ...
|
| #
bec7b9a2
|
| 30-Apr-2023 |
Piotr Pawel Stefaniak <pstef@FreeBSD.org> |
sh: introduce a function to iterate over all hashed commands
While aliases and built-ins are opportunistically stored in cmdtable, each function will be added to it immediately on definition.
Facto
sh: introduce a function to iterate over all hashed commands
While aliases and built-ins are opportunistically stored in cmdtable, each function will be added to it immediately on definition.
Factor out the hashing function, write the iterator function and make it use the hashing function.
Add the cmdname pointer to struct cmdentry so that the command name can be exposed that way.
Differential Revision: https://reviews.freebsd.org/D40619
show more ...
|
| #
1d386b48
|
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
| #
d2c23317
|
| 23-Sep-2021 |
Stephane Rochoy <stephane.rochoy@stormshield.eu> |
sh: Add -o verify to use O_VERIFY when sourcing scripts
Add -o verify to sh to make it use O_VERIFY when sourcing scripts and reading profiles.
Useful in conjunction with mac_veriexec to help prote
sh: Add -o verify to use O_VERIFY when sourcing scripts
Add -o verify to sh to make it use O_VERIFY when sourcing scripts and reading profiles.
Useful in conjunction with mac_veriexec to help protect at least some parts of the boot sequence, e.g., /etc/rc*.
Differential revision: https://reviews.freebsd.org/D30464 Reviewed by: jilles, sjg Obtained from: Stormshield
show more ...
|
| #
ccd0a51f
|
| 01-Sep-2020 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Write absolute path in command -vV and type
POSIX is pretty clear that command -v, command -V and type shall write absolute pathnames. Therefore, we need to prepend the current directory's name
sh: Write absolute path in command -vV and type
POSIX is pretty clear that command -v, command -V and type shall write absolute pathnames. Therefore, we need to prepend the current directory's name to relative pathnames.
This can happen either when PATH contains a relative pathname or when the operand contains a slash but is not an absolute pathname.
show more ...
|
| #
e0f5c138
|
| 30-May-2020 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Allow more scripts without #!
Austin Group bugs #1226 and #1250 changed the requirements for shell scripts without #! (POSIX does not specify #!; this is about the shell execution when execve(2)
sh: Allow more scripts without #!
Austin Group bugs #1226 and #1250 changed the requirements for shell scripts without #! (POSIX does not specify #!; this is about the shell execution when execve(2) returns an [ENOEXEC] error).
POSIX says we shall allow execution if the initial part intended to be parsed by the shell consists of characters and does not contain the NUL character. This allows concatenating a shell script (ending with exec or exit) and a binary payload.
In order to reject common binary files such as PNG images, check that there is a lowercase letter or expansion before the last newline before the NUL character, in addition to the check for the newline character suggested by POSIX.
show more ...
|
| #
9b5cb2f6
|
| 12-Nov-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r340235 through r340367.
|
| #
bb324af6
|
| 09-Nov-2018 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Unify EXERROR and EXEXEC
The difference between EXERROR and EXEXEC was that EXEXEC passed along exitstatus and EXERROR set exitstatus to 2 in the handling code.
By changing the places that rais
sh: Unify EXERROR and EXEXEC
The difference between EXERROR and EXEXEC was that EXEXEC passed along exitstatus and EXERROR set exitstatus to 2 in the handling code.
By changing the places that raised EXERROR to set exitstatus to 2, the handling of EXERROR and EXEXEC becomes the same.
show more ...
|
| #
2a22df74
|
| 04-Nov-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r339813 through r340125.
|
| #
b5532964
|
| 27-Oct-2018 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Use exitstatus instead of exerrno to pass EXEXEC status
No functional change is intended.
|
| #
e043f372
|
| 24-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
bin: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remov
bin: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
show more ...
|
| #
90aea514
|
| 23-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
bin: Remove ancient SCCS tags.
Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl s
bin: Remove ancient SCCS tags.
Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl script.
Sponsored by: Netflix
show more ...
|
| #
bec7b9a2
|
| 30-Apr-2023 |
Piotr Pawel Stefaniak <pstef@FreeBSD.org> |
sh: introduce a function to iterate over all hashed commands
While aliases and built-ins are opportunistically stored in cmdtable, each function will be added to it immediately on definition.
Facto
sh: introduce a function to iterate over all hashed commands
While aliases and built-ins are opportunistically stored in cmdtable, each function will be added to it immediately on definition.
Factor out the hashing function, write the iterator function and make it use the hashing function.
Add the cmdname pointer to struct cmdentry so that the command name can be exposed that way.
Differential Revision: https://reviews.freebsd.org/D40619
show more ...
|
| #
1d386b48
|
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
| #
d2c23317
|
| 23-Sep-2021 |
Stephane Rochoy <stephane.rochoy@stormshield.eu> |
sh: Add -o verify to use O_VERIFY when sourcing scripts
Add -o verify to sh to make it use O_VERIFY when sourcing scripts and reading profiles.
Useful in conjunction with mac_veriexec to help prote
sh: Add -o verify to use O_VERIFY when sourcing scripts
Add -o verify to sh to make it use O_VERIFY when sourcing scripts and reading profiles.
Useful in conjunction with mac_veriexec to help protect at least some parts of the boot sequence, e.g., /etc/rc*.
Differential revision: https://reviews.freebsd.org/D30464 Reviewed by: jilles, sjg Obtained from: Stormshield
show more ...
|
| #
ccd0a51f
|
| 01-Sep-2020 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Write absolute path in command -vV and type
POSIX is pretty clear that command -v, command -V and type shall write absolute pathnames. Therefore, we need to prepend the current directory's name
sh: Write absolute path in command -vV and type
POSIX is pretty clear that command -v, command -V and type shall write absolute pathnames. Therefore, we need to prepend the current directory's name to relative pathnames.
This can happen either when PATH contains a relative pathname or when the operand contains a slash but is not an absolute pathname.
show more ...
|
| #
e0f5c138
|
| 30-May-2020 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Allow more scripts without #!
Austin Group bugs #1226 and #1250 changed the requirements for shell scripts without #! (POSIX does not specify #!; this is about the shell execution when execve(2)
sh: Allow more scripts without #!
Austin Group bugs #1226 and #1250 changed the requirements for shell scripts without #! (POSIX does not specify #!; this is about the shell execution when execve(2) returns an [ENOEXEC] error).
POSIX says we shall allow execution if the initial part intended to be parsed by the shell consists of characters and does not contain the NUL character. This allows concatenating a shell script (ending with exec or exit) and a binary payload.
In order to reject common binary files such as PNG images, check that there is a lowercase letter or expansion before the last newline before the NUL character, in addition to the check for the newline character suggested by POSIX.
show more ...
|
| #
9b5cb2f6
|
| 12-Nov-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r340235 through r340367.
|
| #
bb324af6
|
| 09-Nov-2018 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Unify EXERROR and EXEXEC
The difference between EXERROR and EXEXEC was that EXEXEC passed along exitstatus and EXERROR set exitstatus to 2 in the handling code.
By changing the places that rais
sh: Unify EXERROR and EXEXEC
The difference between EXERROR and EXEXEC was that EXEXEC passed along exitstatus and EXERROR set exitstatus to 2 in the handling code.
By changing the places that raised EXERROR to set exitstatus to 2, the handling of EXERROR and EXEXEC becomes the same.
show more ...
|
| #
2a22df74
|
| 04-Nov-2018 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r339813 through r340125.
|
| #
b5532964
|
| 27-Oct-2018 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Use exitstatus instead of exerrno to pass EXEXEC status
No functional change is intended.
|
| #
4600b569
|
| 15-Jul-2018 |
Jilles Tjoelker <jilles@FreeBSD.org> |
sh: Don't treat % specially in CDPATH
|
| #
7e1b7636
|
| 08-May-2017 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r317808 through r317970.
|