mirror of
https://github.com/sudo-project/sudo.git
synced 2025-09-01 23:05:17 +00:00
For the audit plugin, command_info may be NULL.
Fixes a NULL dereference in sudoers_audit when an I/O logging plugin rejects input/output or returns an error.
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
.\"
|
||||
.TH "SUDO_PLUGIN" "5" "November 2, 2020" "Sudo @PACKAGE_VERSION@" "File Formats Manual"
|
||||
.TH "SUDO_PLUGIN" "5" "November 17, 2020" "Sudo @PACKAGE_VERSION@" "File Formats Manual"
|
||||
.nh
|
||||
.if n .ad l
|
||||
.SH "NAME"
|
||||
@@ -3074,7 +3074,8 @@ functions will
|
||||
be called.
|
||||
.TP 6n
|
||||
command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
\(lqname=value\(rq
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
@@ -3188,7 +3189,8 @@ will be the
|
||||
pointer.
|
||||
.TP 6n
|
||||
command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
\(lqname=value\(rq
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
@@ -3272,7 +3274,8 @@ will be the
|
||||
pointer.
|
||||
.TP 6n
|
||||
command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
\(lqname=value\(rq
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
|
@@ -15,7 +15,7 @@
|
||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
.\"
|
||||
.Dd November 2, 2020
|
||||
.Dd November 17, 2020
|
||||
.Dt SUDO_PLUGIN @mansectform@
|
||||
.Os Sudo @PACKAGE_VERSION@
|
||||
.Sh NAME
|
||||
@@ -2741,7 +2741,8 @@ functions will
|
||||
.Em both
|
||||
be called.
|
||||
.It command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
.Dq name=value
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
@@ -2842,7 +2843,8 @@ will be the
|
||||
.Dv NULL
|
||||
pointer.
|
||||
.It command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
.Dq name=value
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
@@ -2914,7 +2916,8 @@ will be the
|
||||
.Dv NULL
|
||||
pointer.
|
||||
.It command_info
|
||||
A vector of information describing the command being run in the form of
|
||||
An optional
|
||||
vector of information describing the command being run in the form of
|
||||
.Dq name=value
|
||||
strings.
|
||||
The vector is terminated by a
|
||||
|
@@ -201,6 +201,7 @@ audit_to_eventlog(struct eventlog *evlog, char * const command_info[],
|
||||
sudoers_to_eventlog(evlog, run_argv, run_envp);
|
||||
|
||||
/* Update iolog and execution environment from command_info[]. */
|
||||
if (command_info != NULL) {
|
||||
for (cur = command_info; *cur != NULL; cur++) {
|
||||
switch (**cur) {
|
||||
case 'c':
|
||||
@@ -230,6 +231,7 @@ audit_to_eventlog(struct eventlog *evlog, char * const command_info[],
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
debug_return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user