Bugzilla – Attachment 26816 Details for
Bug 64002
VUL-0: CVE-2004-1014: rpc.statd DoS
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
patch
sgi-statd-fixes.patch (text/plain), 3.04 KB, created by
Ludwig Nussel
on 2004-12-07 21:53:43 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Ludwig Nussel
Created:
2004-12-07 21:53:43 UTC
Size:
3.04 KB
patch
obsolete
>diff -prauN --exclude-from=excludes nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/monitor.c nfs-utils-work/nfs-utils-1.0.6/utils/statd/monitor.c >--- nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/monitor.c Fri Sep 12 15:41:35 2003 >+++ nfs-utils-work/nfs-utils-1.0.6/utils/statd/monitor.c Sun Jun 20 23:41:01 2004 >@@ -15,6 +15,7 @@ > #include <string.h> > #include <unistd.h> > #include <sys/stat.h> >+#include <errno.h> > #include <arpa/inet.h> > #include "misc.h" > #include "statd.h" >@@ -171,7 +172,7 @@ sm_mon_1_svc(struct mon *argp, struct sv > sprintf(path, "%s/%s", SM_DIR, mon_name); > if ((fd = open(path, O_WRONLY|O_SYNC|O_CREAT, S_IRUSR|S_IWUSR)) < 0) { > /* Didn't fly. We won't monitor. */ >- note(N_ERROR, "creat(%s) failed: %m", path); >+ note(N_ERROR, "creat(%s) failed: %s", path, strerror (errno)); > nlist_free(NULL, clnt); > free(path); > goto failure; >diff -prauN --exclude-from=excludes nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/simulate.c nfs-utils-work/nfs-utils-1.0.6/utils/statd/simulate.c >--- nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/simulate.c Fri Sep 12 15:41:38 2003 >+++ nfs-utils-work/nfs-utils-1.0.6/utils/statd/simulate.c Sun Jun 20 22:51:15 2004 >@@ -219,7 +219,7 @@ sim_sm_mon_1_svc (struct status *argp, s > { > static char *result; > >- dprintf (N_DEBUG, "Recieved state %d for mon_name %s (opaque \"%s\")", >+ dprintf (N_DEBUG, "Received state %d for mon_name %s (opaque \"%s\")", > argp->state, argp->mon_name, argp->priv); > svc_exit (); > return ((void *)&result); >diff -prauN --exclude-from=excludes nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/statd.c nfs-utils-work/nfs-utils-1.0.6/utils/statd/statd.c >--- nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/statd.c Fri Sep 12 16:24:29 2003 >+++ nfs-utils-work/nfs-utils-1.0.6/utils/statd/statd.c Sun Jun 20 22:39:11 2004 >@@ -179,8 +179,10 @@ static void drop_privs(void) > struct stat st; > > if (stat(SM_DIR, &st) == -1 && >- stat(DIR_BASE, &st) == -1) >+ stat(DIR_BASE, &st) == -1) { > st.st_uid = 0; >+ st.st_gid = 0; >+ } > > if (st.st_uid == 0) { > note(N_WARNING, "statd running as root. chown %s to choose different user\n", >@@ -399,6 +401,11 @@ int main (int argc, char **argv) > signal (SIGTERM, killer); > /* WARNING: the following works on Linux and SysV, but not BSD! */ > signal(SIGCHLD, SIG_IGN); >+ /* >+ * Ignore SIGPIPE to avoid statd dying when peers close their >+ * TCP connection while we're trying to reply to them. >+ */ >+ signal(SIGPIPE, SIG_IGN); > > /* initialize out_port */ > statd_get_socket(out_port); >diff -prauN --exclude-from=excludes nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/svc_run.c nfs-utils-work/nfs-utils-1.0.6/utils/statd/svc_run.c >--- nfs-utils-sgi/nfs-utils-1.0.6/utils/statd/svc_run.c Fri Sep 12 15:41:40 2003 >+++ nfs-utils-work/nfs-utils-1.0.6/utils/statd/svc_run.c Sun Jun 20 22:40:28 2004 >@@ -113,7 +113,8 @@ my_svc_run(void) > if (errno == EINTR || errno == ECONNREFUSED > || errno == ENETUNREACH || errno == EHOSTUNREACH) > continue; >- note(N_ERROR, "my_svc_run() - select: %m"); >+ note(N_ERROR, "my_svc_run() - select: %s", >+ strerror (errno)); > return; > > case 0:
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 64002
: 26816 |
26856
|
26858
|
26859