Bug 59080 - doing: userhelper -w /// will cause SEGV
doing: userhelper -w /// will cause SEGV
Status: CLOSED CURRENTRELEASE
Product: Red Hat Linux
Classification: Retired
Component: usermode (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jindrich Novy
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-01-30 12:43 EST by Luki Rustianto
Modified: 2013-07-02 18:55 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-09-29 20:38:18 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Luki Rustianto 2002-01-30 12:43:42 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.76 [en] (X11; U; Linux 2.4.2-2 i686)

Description of problem:
command:
userhelper -w ///
will cause segmentation fault

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.userhelper -w ///
2.
3.
	

Actual Results:  the userhelper program segmentation fault

Additional info:

[luki@gringgo luki]$ cat /etc/redhat-release
Red Hat Linux release 7.1 (Seawolf)
[luki@gringgo luki]$ userhelper -w //
Segmentation fault

In userhelper.c line 615: did not check NULL return result from
svNewFile(apps_filename), it should be

possibly fix:
--- userhelper.orig.c   Thu Jan 31 00:13:42 2002
+++ userhelper.c        Thu Jan 31 00:14:18 2002
@@ -612,7 +612,7 @@
        snprintf(apps_filename, aft, "/etc/security/console.apps/%s", progname);
        s = svNewFile(apps_filename);
 
-       if (fstat(s->fd, &sbuf) ||
+       if ((!s) || fstat(s->fd, &sbuf) ||
            !S_ISREG(sbuf.st_mode) ||
            (sbuf.st_mode & S_IWOTH))
                exit(ERR_UNK_ERROR); /* don't be verbose about security
Comment 1 Miloslav Trmač 2004-09-29 20:38:18 EDT
This is fixed in current version (usermode-1.70-2).
Thanks for your report.

Note You need to log in before you can comment on or make changes to this bug.