Bug 131390 - crond core when selinux not enabled and crontab has no jobs
Summary: crond core when selinux not enabled and crontab has no jobs
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: vixie-cron
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jason Vas Dias
QA Contact: Brock Organ
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-08-31 20:47 UTC by Jason Vas Dias
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version: vixie-cron-4.1-10
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-08-31 20:52:55 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Jason Vas Dias 2004-08-31 20:47:56 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040510

Description of problem:
 crond can get a SIGSEGV and generate core (or die silently) if
 selinux is not enabled (is_selinux_enabled()==0) and a crontab
 file contains no valid jobs (eg. is empty or contains only comments).


Version-Release number of selected component (if applicable):
vixie-cron-4.1-9

How reproducible:
Always

Steps to Reproduce:
1. install FC3 with selinux disabled
2. create crontab with no jobs - just a commented line

    

Actual Results:  crond gets SIGSEGV and is not running

Expected Results:  crond should continue running

Additional info:

Comment 1 Jason Vas Dias 2004-08-31 20:52:55 UTC
This was caused by most recent selinux patch in user.c:
in load_user(), if is_selinux_enabled() was false, the user->scontext
pointer was not assigned or initialized (could contain garbage)
which was then always free'd in free_user with freecon() - the
core always happened in freecon with u->context being "address out of
bounds".
If is_selinux_enabled is false, then u->scontext is initialized
to NULL, and free_user will now only free it if it is non-null.
 


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