Bug 23191

Summary: balsa initialisation fails
Product: [Retired] Red Hat Linux Reporter: Chris Evans <chris>
Component: balsaAssignee: Bill Nottingham <notting>
Status: CLOSED RAWHIDE QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1CC: herrold, rvokal
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-04-11 03:43:21 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Chris Evans 2001-01-02 23:15:49 UTC
NOTE!! Filing against GNOME because there does not seem to be a
"balsa" component. (I filed that against bugzilla too ;-)

I fired up balsa. It detected this was the first time and proceeded to
create all
neccessary files etc.

Unfortunately, initialisation fails because it was unable to create
/var/spool/mail/chris

I suspect /var/spool/mail/chris should have been created when the "chris"
account was created. The "chris" account was created by anaconda rather
than the "useradd" utility.

Comment 1 Bill Nottingham 2001-01-03 17:19:41 UTC
Actually, nothing creates that; its just created when the first
mail is delivered there.

Comment 2 Bill Nottingham 2001-02-09 00:50:05 UTC
*** Bug 26731 has been marked as a duplicate of this bug. ***

Comment 3 Bill Nottingham 2001-02-12 22:54:04 UTC
The people who do shadow-utils & the installer say that creating
the mail spool file on account creation is a bad idea. From looking
at the balsa source, hacking it to accept some sort of 'null' mailbox
there is major surgery.

I suppose that you could do some horrible hack like having it send
you mail when it configures itself, but that would be Wrong.

Marking it as wontfix for now.

Comment 4 Bill Nottingham 2001-02-16 17:46:35 UTC
*** Bug 26731 has been marked as a duplicate of this bug. ***

Comment 5 R P Herrold 2001-03-29 04:08:55 UTC
After the current release goes gold, I will re-open this for consideration as
Deferred -- it may be possible to apply my proposed fix now, but it is not
MUSTFIX for 7.1 ...

This may be simply 'fixable' ... if one simply skips the error condition arising
from the check for /var/spool/mail/(userid)

--------------------------------------
Replication and fix procedure:

First window:  (both as root ...)
==============================================

[root@couch RPMS]# rpm -Uvh balsa-1.1.1-3.i386.rpm
Preparing...                ########################################### [100%]
   1:balsa                  ########################################### [100%]
[root@couch RPMS]# cd /var/spool/mail/
[root@couch mail]# ls
russ4
[root@couch mail]# ssh herrold@localhost
herrold@localhost's password:
Last login: Wed Mar 28 21:54:35 2001
[herrold@couch herrold]$ balsa
 
** WARNING **: Balsa cannot open your "Inbox" mailbox.
 
** WARNING **: Balsa cannot open your "Outbox" mailbox.
 
** WARNING **: Balsa cannot open your "Sentbox" mailbox.
 
** WARNING **: Balsa cannot open your "Draftbox" mailbox.
 
** WARNING **: Balsa cannot open your "Trash" mailbox.
 
** WARNING **: *** Could not load basic mailboxes!
 
 
** WARNING **: An error:
Permission denied
 occured while trying to create the mailbox "/var/spool/mail/herrold"

======================================

error pops about the missing /var/spool/mail/(userid) -- at this point, BALSA
should touch the missing file, and avoid the need for the error message -- but 
if it is not running SUID root, it lacks the permissions to do so ...

Second window:
---------------------------------------
[root@couch /root]# cd /var/spool/mail/
[root@couch mail]# touch herrold
[root@couch mail]# chown herrold.herrold herrold
[root@couch mail]# ls -al
total 17
drwxrwxr-x    2 root     mail         1024 Mar 28 22:43 .
drwxr-xr-x   12 root     root         1024 Dec  7 19:05 ..
-rw-r--r--    1 herrold  herrold         0 Mar 28 22:43 herrold
-rw-rw----    1 russ4    mail        13382 Jan 28 18:01 russ4
[root@couch mail]# chmod 700 herrold

At this point, te Finish box will ungrey on a back/fwd click pair ...

----------------------------------

IF bugzilla 12494 -- http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=12494
-- had been done, the SUID need goes away.  Is the potential DOS of filling a
directory more risky than a SUID balsa? -- but theis is the rejected solution by
the shadow utils folks, etc ...

---------------------------------

I then ran:

[root@couch mail]# rm /var/spool/mail/herrold

and in the end user window, re-started balsa -- it 'Check's cleanly with a
non-existent /vra/spool/mail/(userid) mail file ... 

-------------------------------------

Summary -- ignore, or remove the check for a file at, the missing mailspool
error, and proceed to completion at initial setup.


Comment 6 R P Herrold 2001-04-11 03:43:17 UTC
Re-open for consideration of proposed fix in RH 7.2

Comment 7 Bill Nottingham 2001-10-22 15:01:02 UTC
Fixed in 1.2.1-1; useradd also creates /var/spool/mail/$USER now too.

Comment 8 Brock Organ 2001-10-22 22:26:14 UTC
verified fix (ie useradd adds entry /var/spool/mail/$USER) while testing 
balsa-1.2.1-1 ...