Commit Graph

11831 Commits

Author SHA1 Message Date
Todd C. Miller
ab00d29ecf Merge pull request #152 from particleflux/fix-sudoers-typo
Fix typo in sudoers comment
2022-06-07 08:30:44 -06:00
Helio Machado
3405fac05e Add missing colon in Tag_Spec documentation 2022-06-07 16:28:14 +02:00
Stefan Linke
a074d058ef Fix typo in sudoers comment
Fix a typo in the sudoers comment about `maxseq` param.

Introduced by 906eb19ece in 1.9.11.
2022-06-07 13:03:03 +02:00
Todd C. Miller
e4ea5ad8af Only shift unsigned values to avoid implementation-specific behavior.
This converts the arithmetic shifts to logical shifts.
2022-06-06 20:15:37 -06:00
Todd C. Miller
263fdc6b06 Fix issue protobuf-c#499: unsigned integer overflow
Signed-off-by: 10054172 <hui.zhang@thalesgroup.com>
2022-06-06 20:15:03 -06:00
Todd C. Miller
b77cbb2e67 Fix building with select (not poll) when fd_set is not defined in sys/types.h.
We can use a void * for the fd_set arrays and just add a cast when
using the FD_SET macros.
2022-06-06 19:42:29 -06:00
Todd C. Miller
c2a131714a Reinstall the event handler if we get EAGAIN from read/write callback.
The read and write events do not set SUDO_EV_PERSIST so we need to
explicitly re-enable the event if there is still data to be read.
Bug #963.
2022-06-06 19:42:07 -06:00
Todd C. Miller
db6fc237c4 If write(2) returns EAGAIN just re-enter the event loop.
This is consistent with how we handle EAGAIN for read(2).
2022-06-06 19:42:06 -06:00
Todd C. Miller
fcb5867f1d Document how setting ModulePath affects the Python search path.
Also advise the user to use a unique prefix to avoid name space
collisions with installed Python modules.  Bug #1031.
2022-06-06 08:39:22 -06:00
Todd C. Miller
96c3c28194 Add EXAMPLES variables for use in the man pages for the examples directory. 2022-06-06 08:36:44 -06:00
Todd C. Miller
24522fb4e4 Updated translations from translationproject.org 2022-06-04 11:44:13 -06:00
Todd C. Miller
258b504be8 Rebuild Croatian message catalog. 2022-06-04 10:25:30 -06:00
Todd C. Miller
4386be3d68 Add new test binaries to the ignore files. 2022-06-03 15:26:06 -06:00
Todd C. Miller
5cb94eb258 Updated translations from translationproject.org 2022-06-03 13:09:57 -06:00
Todd C. Miller
ac06fb7f29 Define WORDS_BIGENDIAN on big endian systems.
Instead of a configure check, we use endian.h (or a fallback).
2022-06-03 12:51:21 -06:00
Todd C. Miller
71c07579ba Update to protobuf-c 1.4.0 2022-06-03 12:50:31 -06:00
Todd C. Miller
aee276ea63 Quiet two clang analyzer false positives. 2022-06-03 11:05:34 -06:00
Todd C. Miller
f19a71a3db Move a comment to the correct location. 2022-06-03 10:32:47 -06:00
Todd C. Miller
5012c7f978 union sockaddr_union: pass in sockaddr_union * instead of sockaddr *.
This eliminates the need for a few casts and is consistent with how
create_listener() is written.
2022-06-03 10:11:37 -06:00
Todd C. Miller
898ca50545 Eliminate some dead stores that clang-analyzer complains about. 2022-06-03 10:01:11 -06:00
Todd C. Miller
63e6973ad1 ptrace_read_vec: don't try to free memory on the error path
This is leftover from when ptrace_read_string() allocated its own memory.
2022-06-03 10:00:08 -06:00
Todd C. Miller
25a26f5042 Avoid using vfork(2) in the DSO system(3) wrapper.
Traditional vfork(2) semantics make it unsafe for use for more than
just vfork(2) + execve(2).
2022-06-03 09:43:34 -06:00
Todd C. Miller
06bf1be67c Updated translations from translationproject.org 2022-06-02 14:10:15 -06:00
Todd C. Miller
66909a4831 Mention sudo_logsrvd.conf "log_server" parsing fix. 2022-06-02 14:09:46 -06:00
Todd C. Miller
2d6b9d22e1 For logsrvd_conf_test include both tls and non-tls configs. 2022-06-02 11:38:43 -06:00
Todd C. Miller
d7b2ff3214 Add a simple regression test for logsrvd.conf parser.
Unlike the parser fuzzer, this includes sample certs and keys.
This test would have detected the BIO_new_file() bug in set_dhparams().
2022-06-02 11:13:18 -06:00
Todd C. Miller
0ca222aa88 Fix inverted logic when setting server_log.
A value that starts with a '/' should be treated as a path.
2022-06-02 10:59:30 -06:00
Todd C. Miller
bec9603f3a Use abs_top_builddir instead of pwd/$(top_builddir). 2022-06-02 10:23:04 -06:00
Todd C. Miller
51b64780c0 Plug a memory leak. 2022-06-01 15:24:28 -06:00
Todd C. Miller
89b80ea690 Fix bug in last commit, need to reinitialize role to NULL. 2022-06-01 14:49:31 -06:00
Todd C. Miller
eb0135a93a Simplify the check for when we can reuse the previous user and host specs.
This makes the code easier to read and quiets a cppcheck false positive.
2022-06-01 14:30:47 -06:00
Todd C. Miller
77a47affb4 Install the plugin man pages in section 5 (or 4 for System V).
The manual had the correct section in the text but was installed
in the wrong directory.
2022-06-01 10:02:34 -06:00
Todd C. Miller
3074f64bd1 Updated translations from translationproject.org 2022-06-01 09:25:06 -06:00
Todd C. Miller
4b5ee47e0d Sudo now supports intercepting system(3). 2022-06-01 09:25:03 -06:00
Todd C. Miller
c20c3b5631 Only display "unable to connect to log server" warning once.
Previously, in intercept mode, if the log server is unreachable the
message would be printed for each sub-command.
2022-05-31 20:03:17 -06:00
Todd C. Miller
de4d53e488 When using ptrace(2), push the point where we suspend into exec_cmnd().
This should reduce the amount of time the child has to wait for
the parent to use PTRACE_SEIZE to seize control and then PTRACE_CONT
to continue the child.
2022-05-31 19:51:26 -06:00
Todd C. Miller
cec83a05a3 Add configure check for vfork(2) and fall back to fork(2) if missing. 2022-05-31 14:47:39 -06:00
Todd C. Miller
f52342031d Add support for intercepting the system(3) function.
This also means we can log system(3) with log_subcmds.
2022-05-31 14:45:00 -06:00
Todd C. Miller
436deda08d Newer compilers define __BYTE_ORDER__ and __ORDER_{BIG,LITTLE}_ENDIAN__
Also add riscv the little endian list.
2022-05-31 10:18:39 -06:00
Todd C. Miller
1c83161622 On AIX, fmemopen(3) has a bug where feof() returns false at EOF.
See https://www.ibm.com/support/pages/apar/IJ11845
2022-05-29 15:52:48 -06:00
Todd C. Miller
dc8311dae9 Fix potential signed integer overflow on 32-bit CPUs.
Converting fractional minutes to nanoseconds could overflow a 32-bit
integer, use long long instead.
2022-05-27 15:47:32 -06:00
Todd C. Miller
93916fde4f Fix path to example sudoers file, it is now in the build dir. 2022-05-27 15:33:58 -06:00
Todd C. Miller
b497d74544 init_options: initialize apparmor_profile to NULL 2022-05-27 13:57:22 -06:00
Todd C. Miller
c1934a6366 Update with latest 1.9.11 changes. 2022-05-27 13:09:08 -06:00
Todd C. Miller
6eda28ef51 Fix typo 2022-05-27 13:08:01 -06:00
Todd C. Miller
789bc6ec8e Update contributors. 2022-05-27 12:42:40 -06:00
Todd C. Miller
15f167c3a0 Fix uninitialized use of ca_store when building with wolfSSL. 2022-05-27 11:23:45 -06:00
Todd C. Miller
7125a9cc23 Newer Debian/Ubuntu uses libsepol-dev not libsepol1-dev. 2022-05-27 09:34:04 -06:00
Todd C. Miller
346e63cd7c Update .pot files for 1.9.11 2022-05-26 09:41:54 -06:00
Todd C. Miller
9bb288d10e Regenerate files after merging AppArmor integration. 2022-05-27 08:30:34 -06:00