*BSD News Article 84637


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!cpk-news-hub1.bbnplanet.com!news.bbnplanet.com!cam-news-hub1.bbnplanet.com!news.idt.net!cdc2.cdc.net!vixen.cso.uiuc.edu!ux9.cso.uiuc.edu!not-for-mail
From: igor@students.uiuc.edu (igor vladimirovich roshchin)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: loss of root password
Date: 10 Dec 1996 05:42:01 GMT
Organization: University of Illinois at Urbana
Lines: 24
Message-ID: <58it79$1bb@vixen.cso.uiuc.edu>
References: <32A7AF66.49FF@li.net> <32A7FC1D.2781E494@cool.pvrr.ru>
NNTP-Posting-Host: ux9.cso.uiuc.edu
X-Newsreader: TIN [UNIX 1.3 950824BETA PL0]

Alexander Maksimov (sasha@cool.pvrr.ru) wrote:
: Jeff Auerbach wrote:
: > 
: > I changed my root shell to /bin/ksh not thinking at the time that the
: > ksh was actually in /usr/local/bin.  Basically I cannot log in as root
: > or su anymore because of the lack of shell.  How can I fix this without
: > rebuilding the system.  I want my rootly powers back.
: If you have network access to your machine, try to use ftp in order to
: get your "/etc/passwd", edit it and put it back.
: I've solved the same problem in this way (but I used SCO, not FreeBSD).

If you've done that, you should worry about your configuration.
Even in standard configuration of FreeBSD you should not be able to do that.
Reasons:
1. /etc/ftpusers should contain root, toor, and uucp as users dissalowed
any ftp access.
2. ftpd should not let you login as user if you default shell is not in
/etc/shells


IgoR
aka StR

IgoR@uiuc.edu