Opened 10 years ago

Closed 10 years ago

#810 closed defect (fixed)

setgid() in run_email2trac doesn't work because it happens after setuid() call

Reported by: anonymous Owned by: anonymous
Priority: high Component: EmailtoTracScript
Severity: major Keywords:
Cc: Trac Release: 0.9


Switch the order of the two calls. Per the documentation (on freebsd at least) for setgid():

The setgid() function is permitted if the specified ID is equal to the real group ID
or the effective group ID of the process, or if the effective user ID is that of the super user.

So if you call setgid() first, the uid of the proc is still root and it will work. I noticed this b/c I own my project dir, but have it group www-data writeable and that wasn't working.

Attachments (0)

Change History (2)

comment:1 Changed 10 years ago by anonymous

  • Owner changed from bas to anonymous
  • Status changed from new to assigned

Thanks it is fixed in the trunk version

comment:2 Changed 10 years ago by bas

  • Resolution set to fixed
  • Status changed from assigned to closed

Fixed in 0.8.2 version. Hope i can close it now ;-)

Add Comment

Modify Ticket

as closed The owner will remain anonymous.
The resolution will be deleted. Next status will be 'reopened'.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.