- Timestamp:
- Sep 1, 2012, 4:25:30 PM (12 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_calls.c
r361 r412 696 696 SL_ENTER(_("aud_open")); 697 697 698 #ifdef USE_SUID 699 if (0 == strcmp(pathname, "/usr/bin/sudo")) 700 { 701 uid_t ruid; uid_t euid; uid_t suid; 702 getresuid(&ruid, &euid, &suid); 703 } 704 if (privs == SL_YESPRIV) 705 sl_set_suid(); 706 #else 707 /*@-noeffect@*/ 708 (void) privs; /* fix compiler warning */ 709 /*@+noeffect@*/ 710 #endif 711 698 712 val_return = open (pathname, *o_noatime|flags, mode); 713 714 #ifdef USE_SUID 715 if (privs == SL_YESPRIV) 716 sl_unset_suid(); 717 #endif 718 699 719 if ((val_return < 0) && (*o_noatime != 0)) 700 720 { … … 704 724 } 705 725 error = errno; 706 /*@-noeffect@*/707 (void) privs; /* fix compiler warning */708 /*@+noeffect@*/709 726 710 727 if (val_return < 0) … … 736 753 SL_ENTER(_("aud_open")); 737 754 738 val_return = open (pathname, flags, mode); 739 error = errno; 755 #ifdef USE_SUID 756 if (privs == SL_YESPRIV) 757 sl_set_suid(); 758 #else 740 759 /*@-noeffect@*/ 741 760 (void) privs; /* fix compiler warning */ 742 761 /*@+noeffect@*/ 762 #endif 763 764 val_return = open (pathname, flags, mode); 765 766 #ifdef USE_SUID 767 if (privs == SL_YESPRIV) 768 sl_unset_suid(); 769 #endif 770 771 error = errno; 743 772 744 773 if (val_return < 0) -
trunk/src/sh_database.c
r362 r412 1764 1764 1765 1765 /* recursively enter linked list of messages into database, last first 1766 * - last is client (if this is a client message received by client) 1766 1767 */ 1767 1768 long sh_database_insert_rec (dbins * curr, int depth, char * host) -
trunk/src/slib.c
r395 r412 1535 1535 SL_REQUIRE (sl_save_uids() == SL_ENONE, _("sl_save_uids() == SL_ENONE")); 1536 1536 1537 #ifndef SH_ALLOW_SUID 1537 1538 if (euid != ruid || egid != rgid) 1538 1539 { … … 1556 1557 #endif 1557 1558 } 1559 #endif 1558 1560 SL_IRETURN(SL_ENONE, _("sl_policy_get_user")); 1559 1561 }
Note:
See TracChangeset
for help on using the changeset viewer.