Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 150938 Details for
Bug 133098
CVE-2004-0813 SG_IO unsafe user command execution
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Simple PAM support for cdrecord
cdrtools-2.01-pam.patch (text/plain), 1.84 KB, created by
Tomas Mraz
on 2007-03-26 19:21:44 UTC
(
hide
)
Description:
Simple PAM support for cdrecord
Filename:
MIME Type:
Creator:
Tomas Mraz
Created:
2007-03-26 19:21:44 UTC
Size:
1.84 KB
patch
obsolete
>--- cdrtools-2.01/cdrecord/Makefile.pam 2004-05-26 09:31:00.000000000 +0200 >+++ cdrtools-2.01/cdrecord/Makefile 2007-03-26 21:07:59.000000000 +0200 >@@ -33,7 +33,7 @@ > ../include/scg/scgio.h ../include/scg/scsidefs.h \ > ../include/scg/scsireg.h ../include/scg/scsitransp.h > #LIBS= -lschily $(LIB_SOCKET) >-LIBS= -lrscg -lscg $(LIB_VOLMGT) -ledc_ecc -ldeflt -lschily $(SCSILIB) $(LIB_SOCKET) >+LIBS= -lrscg -lscg $(LIB_VOLMGT) -ledc_ecc -ldeflt -lschily $(SCSILIB) $(LIB_SOCKET) -lpam -lpam_misc > XMK_FILE= Makefile.man > > ########################################################################### >--- cdrtools-2.01/cdrecord/cdrecord.c.pam 2007-03-26 21:07:59.000000000 +0200 >+++ cdrtools-2.01/cdrecord/cdrecord.c 2007-03-26 21:12:08.000000000 +0200 >@@ -45,6 +45,10 @@ > #include <signal.h> > #include <schily.h> > #include <getargs.h> >+#include <sys/types.h> >+#include <pwd.h> >+#include <security/pam_appl.h> >+#include <security/pam_misc.h> > > #include "xio.h" > >@@ -251,6 +255,11 @@ > int exflags; > } exargs; > >+static struct pam_conv conv = { >+ misc_conv, >+ NULL >+}; >+ > EXPORT int > main(ac, av) > int ac; >@@ -386,6 +395,31 @@ > > if (flags & F_VERSION) > exit(0); >+ >+ if (geteuid() != getuid() && geteuid() == 0) { >+ int rv; >+ struct passwd *pw; >+ struct passwd pwd; >+ pam_handle_t *pamh = NULL; >+ >+ pw = getpwuid(getuid()); >+ if (pw != NULL) { >+ memcpy(&pwd, pw, sizeof(pwd)); >+ } else { >+ comerrno(EX_BAD, "Cannot obtain user name.\n"); >+ } >+ rv = pam_start("cdrecord", pwd.pw_name, &conv, &pamh); >+ if (rv != PAM_SUCCESS) { >+ comerrno(EX_BAD, "Cannot start PAM: %s\n", pam_strerror(NULL, rv)); >+ } >+ rv = pam_authenticate(pamh, 0); >+ if (rv != PAM_SUCCESS) { >+ pam_end(pamh, rv); >+ comerrno(EX_BAD, "PAM authentication failed: %s\n", pam_strerror(NULL, rv)); >+ } >+ pam_end(pamh, rv); >+ } >+ > /* > * End restricted code for quality assurance. > */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 133098
:
135302
|
135398
| 150938 |
150940