Upgrade CVS to 0.33.18 current

This commit is contained in:
Michiel Broek
2001-08-25 19:53:11 +00:00
parent 2ff822f657
commit e90745a139
111 changed files with 3126 additions and 3121 deletions

View File

@@ -31,9 +31,9 @@ mbuser_SOURCES = mbuser.c mbuser.h
mbuseradd_SOURCES = mbuseradd.c mbuseradd.h
mbpasswd_SOURCES = mbpasswd.c commonio.c pwio.c shadowio.c sgetpwent.c \
xmalloc.c myname.c rad64.c salt.c getdef.c encrypt.c \
xmalloc.c myname.c rad64.c salt.c getdef.c encrypt.c putpwent.c \
mbpasswd.h commonio.h pwio.h shadowio.h sgetpwent.h \
xmalloc.h myname.h rad64.h salt.h getdef.h encrypt.h
xmalloc.h myname.h rad64.h salt.h getdef.h encrypt.h putpwent.h
mbsebbs_LDADD = ../lib/libmemwatch.a ../lib/libclcomm.a ../lib/libcommon.a ../lib/libmsgbase.a ../lib/libdbase.a ../lib/libmbinet.a
mball_LDADD = ../lib/libmemwatch.a ../lib/libclcomm.a ../lib/libcommon.a ../lib/libdbase.a
@@ -45,7 +45,7 @@ mbtoberep_LDADD = ../lib/libmemwatch.a ../lib/libclcomm.a ../lib/libcommon.a ../
mbuser_LDADD = ../lib/libmemwatch.a ../lib/libclcomm.a ../lib/libcommon.a ../lib/libdbase.a
install-exec-local:
@if [ "$(shell whoami)" != "root" ] ; then \
@if [ "`id -un`" != "root" ] ; then \
echo; echo " Must be root to install!"; echo; exit 3; \
fi
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 6711 mbsebbs $(bindir)
@@ -55,7 +55,7 @@ install-exec-local:
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbfbgen $(bindir)
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbstat $(bindir)
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbtoberep $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbuser $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbuseradd $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbpasswd $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbuser $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbuseradd $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbpasswd $(bindir)

View File

@@ -59,6 +59,7 @@ PRE_UNINSTALL = :
POST_UNINSTALL = :
AWK = @AWK@
CC = @CC@
CHOWN = @CHOWN@
COMPRESS = @COMPRESS@
GROUP = @GROUP@
GZIP = @GZIP@
@@ -70,7 +71,6 @@ OWNER = @OWNER@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
VERSION = @VERSION@
YACC = @YACC@
SUBDIRS = .
noinst_PROGRAMS = mbsebbs mball mblang mbchat mbfbgen mbstat mbtoberep mbuser mbuseradd mbpasswd
@@ -94,7 +94,7 @@ mbuser_SOURCES = mbuser.c mbuser.h
mbuseradd_SOURCES = mbuseradd.c mbuseradd.h
mbpasswd_SOURCES = mbpasswd.c commonio.c pwio.c shadowio.c sgetpwent.c xmalloc.c myname.c rad64.c salt.c getdef.c encrypt.c mbpasswd.h commonio.h pwio.h shadowio.h sgetpwent.h xmalloc.h myname.h rad64.h salt.h getdef.h encrypt.h
mbpasswd_SOURCES = mbpasswd.c commonio.c pwio.c shadowio.c sgetpwent.c xmalloc.c myname.c rad64.c salt.c getdef.c encrypt.c putpwent.c mbpasswd.h commonio.h pwio.h shadowio.h sgetpwent.h xmalloc.h myname.h rad64.h salt.h getdef.h encrypt.h putpwent.h
mbsebbs_LDADD = ../lib/libmemwatch.a ../lib/libclcomm.a ../lib/libcommon.a ../lib/libmsgbase.a ../lib/libdbase.a ../lib/libmbinet.a
@@ -157,7 +157,7 @@ mbuseradd_LDADD = $(LDADD)
mbuseradd_DEPENDENCIES =
mbuseradd_LDFLAGS =
mbpasswd_OBJECTS = mbpasswd.o commonio.o pwio.o shadowio.o sgetpwent.o \
xmalloc.o myname.o rad64.o salt.o getdef.o encrypt.o
xmalloc.o myname.o rad64.o salt.o getdef.o encrypt.o putpwent.o
mbpasswd_LDADD = $(LDADD)
mbpasswd_DEPENDENCIES =
mbpasswd_LDFLAGS =
@@ -172,6 +172,19 @@ DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
TAR = tar
GZIP_ENV = --best
DEP_FILES = .deps/bank.P .deps/bbslist.P .deps/bye.P .deps/change.P \
.deps/chat.P .deps/commonio.P .deps/email.P .deps/encrypt.P \
.deps/exitinfo.P .deps/file.P .deps/filesub.P .deps/fsedit.P \
.deps/funcs.P .deps/funcs4.P .deps/getdef.P .deps/language.P \
.deps/lineedit.P .deps/mail.P .deps/mball.P .deps/mbchat.P \
.deps/mbfbgen.P .deps/mblang.P .deps/mbpasswd.P .deps/mbsebbs.P \
.deps/mbstat.P .deps/mbtoberep.P .deps/mbuser.P .deps/mbuseradd.P \
.deps/menu.P .deps/misc.P .deps/msgutil.P .deps/myname.P \
.deps/newuser.P .deps/nextuser.P .deps/offline.P .deps/oneline.P \
.deps/page.P .deps/pinfo.P .deps/pop3.P .deps/putpwent.P \
.deps/pwcheck.P .deps/pwio.P .deps/rad64.P .deps/safe.P .deps/salt.P \
.deps/sgetpwent.P .deps/shadowio.P .deps/timecheck.P .deps/timeout.P \
.deps/user.P .deps/xmalloc.P
SOURCES = $(mbsebbs_SOURCES) $(mball_SOURCES) $(mblang_SOURCES) $(mbchat_SOURCES) $(mbfbgen_SOURCES) $(mbstat_SOURCES) $(mbtoberep_SOURCES) $(mbuser_SOURCES) $(mbuseradd_SOURCES) $(mbpasswd_SOURCES)
OBJECTS = $(mbsebbs_OBJECTS) $(mball_OBJECTS) $(mblang_OBJECTS) $(mbchat_OBJECTS) $(mbfbgen_OBJECTS) $(mbstat_OBJECTS) $(mbtoberep_OBJECTS) $(mbuser_OBJECTS) $(mbuseradd_OBJECTS) $(mbpasswd_OBJECTS)
@@ -179,9 +192,9 @@ all: all-redirect
.SUFFIXES:
.SUFFIXES: .S .c .o .s
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps mbsebbs/Makefile
cd $(top_srcdir) && $(AUTOMAKE) --gnu mbsebbs/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
cd $(top_builddir) \
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
@@ -195,9 +208,6 @@ distclean-noinstPROGRAMS:
maintainer-clean-noinstPROGRAMS:
.c.o:
$(COMPILE) -c $<
.s.o:
$(COMPILE) -c $<
@@ -348,6 +358,11 @@ distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
subdir = mbsebbs
distdir: $(DISTFILES)
here=`cd $(top_builddir) && pwd`; \
top_distdir=`cd $(top_distdir) && pwd`; \
distdir=`cd $(distdir) && pwd`; \
cd $(top_srcdir) \
&& $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu mbsebbs/Makefile
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
@@ -368,174 +383,38 @@ distdir: $(DISTFILES)
|| exit 1; \
fi; \
done
bank.o: bank.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/clcomm.h \
../lib/common.h bank.h funcs4.h language.h funcs.h timeout.h \
timecheck.h exitinfo.h
bbslist.o: bbslist.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/clcomm.h ../lib/common.h bbslist.h \
funcs.h funcs4.h language.h
bye.o: bye.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/clcomm.h \
../lib/common.h funcs.h language.h bye.h
change.o: change.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h change.h \
funcs.h funcs4.h language.h misc.h pwcheck.h timeout.h \
exitinfo.h bye.h
chat.o: chat.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h chat.h funcs.h funcs4.h language.h misc.h \
exitinfo.h
commonio.o: commonio.c ../config.h commonio.h
email.o: email.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/msgtext.h ../lib/msg.h ../lib/common.h \
../lib/clcomm.h ../lib/mbinet.h exitinfo.h language.h mail.h \
timeout.h msgutil.h funcs4.h email.h
encrypt.o: encrypt.c ../config.h encrypt.h
exitinfo.o: exitinfo.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h funcs.h \
funcs4.h language.h oneline.h misc.h bye.h timeout.h \
timecheck.h exitinfo.h
file.o: file.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h filesub.h file.h funcs.h funcs4.h language.h \
misc.h timeout.h exitinfo.h change.h
filesub.o: filesub.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h filesub.h \
funcs.h language.h funcs4.h misc.h timeout.h exitinfo.h \
change.h
fsedit.o: fsedit.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/ansi.h ../lib/common.h ../lib/clcomm.h \
mail.h funcs4.h language.h timeout.h pinfo.h fsedit.h
funcs.o: funcs.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/msgtext.h ../lib/msg.h \
../lib/clcomm.h funcs.h language.h funcs4.h oneline.h misc.h \
bye.h timeout.h timecheck.h exitinfo.h mail.h email.h
funcs4.o: funcs4.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/clcomm.h ../lib/common.h ../lib/msg.h \
funcs4.h misc.h timeout.h language.h
getdef.o: getdef.c ../config.h getdef.h
language.o: language.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h funcs4.h \
language.h
lineedit.o: lineedit.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h mail.h \
funcs4.h language.h timeout.h lineedit.h
mail.o: mail.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/msgtext.h ../lib/clcomm.h ../lib/msg.h mail.h funcs.h \
funcs4.h language.h misc.h timeout.h oneline.h exitinfo.h \
lineedit.h fsedit.h filesub.h msgutil.h pop3.h email.h
mball.o: mball.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/mbse.h \
../lib/records.h ../lib/common.h ../lib/dbcfg.h ../lib/clcomm.h \
mball.h
mbchat.o: mbchat.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/common.h \
../lib/clcomm.h
mbfbgen.o: mbfbgen.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/records.h \
../lib/common.h ../lib/clcomm.h ../lib/dbcfg.h
mblang.o: mblang.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/records.h
mbpasswd.o: mbpasswd.c ../config.h encrypt.h rad64.h myname.h xmalloc.h \
pwio.h shadowio.h mbpasswd.h
mbsebbs.o: mbsebbs.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h ../lib/msg.h \
mbsebbs.h user.h funcs.h funcs4.h language.h menu.h misc.h \
bye.h timeout.h
mbstat.o: mbstat.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/records.h \
../lib/common.h ../lib/clcomm.h ../lib/dbcfg.h mbstat.h
mbtoberep.o: mbtoberep.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h
mbuser.o: mbuser.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/records.h \
../lib/common.h ../lib/clcomm.h ../lib/dbcfg.h mbuser.h
mbuseradd.o: mbuseradd.c ../config.h mbuseradd.h
menu.o: menu.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h oneline.h mail.h bbslist.h change.h bank.h \
chat.h file.h funcs.h funcs4.h misc.h nextuser.h safe.h \
timeout.h menu.h page.h pinfo.h bye.h timecheck.h exitinfo.h \
language.h offline.h email.h
misc.o: misc.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/clcomm.h \
../lib/common.h funcs.h funcs4.h language.h misc.h timeout.h \
exitinfo.h
msgutil.o: msgutil.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h \
../lib/msgtext.h ../lib/msg.h oneline.h msgutil.h
myname.o: myname.c ../config.h
newuser.o: newuser.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/clcomm.h ../lib/common.h funcs4.h \
pwcheck.h newuser.h language.h timeout.h change.h bye.h
nextuser.o: nextuser.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/ansi.h ../lib/clcomm.h ../lib/common.h \
nextuser.h funcs.h funcs4.h language.h timeout.h
offline.o: offline.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/structs.h ../lib/mbse.h \
../lib/records.h ../lib/bluewave.h ../lib/common.h \
../lib/clcomm.h ../lib/msgtext.h ../lib/msg.h mail.h funcs.h \
funcs4.h language.h file.h filesub.h exitinfo.h timeout.h \
msgutil.h pop3.h offline.h
oneline.o: oneline.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h oneline.h \
funcs.h funcs4.h language.h
page.o: page.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h funcs.h funcs4.h chat.h page.h timeout.h mail.h \
language.h
pinfo.o: pinfo.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h funcs4.h
pop3.o: pop3.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h ../lib/mbinet.h ../lib/msgtext.h ../lib/msg.h \
msgutil.h pop3.h
pwcheck.o: pwcheck.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h pwcheck.h \
funcs4.h timeout.h
pwio.o: pwio.c ../config.h sgetpwent.h commonio.h pwio.h
rad64.o: rad64.c ../config.h rad64.h
safe.o: safe.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/clcomm.h \
../lib/common.h exitinfo.h funcs.h funcs4.h misc.h safe.h \
timeout.h language.h
salt.o: salt.c ../config.h rad64.h getdef.h
sgetpwent.o: sgetpwent.c ../config.h sgetpwent.h
shadowio.o: shadowio.c ../config.h commonio.h shadowio.h
timecheck.o: timecheck.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/clcomm.h ../lib/common.h timecheck.h \
funcs.h funcs4.h misc.h bye.h exitinfo.h language.h
timeout.o: timeout.c ../lib/libs.h ../lib/../config.h \
../lib/../lib/memwatch.h ../lib/mbse.h ../lib/structs.h \
../lib/records.h ../lib/common.h ../lib/clcomm.h ../lib/msg.h \
timeout.h funcs.h funcs4.h bye.h filesub.h language.h
user.o: user.c ../lib/libs.h ../lib/../config.h ../lib/../lib/memwatch.h \
../lib/mbse.h ../lib/structs.h ../lib/records.h ../lib/common.h \
../lib/clcomm.h timeout.h user.h pwcheck.h funcs.h funcs4.h \
misc.h bye.h file.h mail.h change.h menu.h exitinfo.h \
language.h offline.h statetbl.h email.h newuser.h
xmalloc.o: xmalloc.c ../config.h xmalloc.h
DEPS_MAGIC := $(shell mkdir .deps > /dev/null 2>&1 || :)
-include $(DEP_FILES)
mostlyclean-depend:
clean-depend:
distclean-depend:
-rm -rf .deps
maintainer-clean-depend:
%.o: %.c
@echo '$(COMPILE) -c $<'; \
$(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
@-cp .deps/$(*F).pp .deps/$(*F).P; \
tr ' ' '\012' < .deps/$(*F).pp \
| sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \
>> .deps/$(*F).P; \
rm .deps/$(*F).pp
%.lo: %.c
@echo '$(LTCOMPILE) -c $<'; \
$(LTCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
@-sed -e 's/^\([^:]*\)\.o[ ]*:/\1.lo \1.o :/' \
< .deps/$(*F).pp > .deps/$(*F).P; \
tr ' ' '\012' < .deps/$(*F).pp \
| sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \
>> .deps/$(*F).P; \
rm -f .deps/$(*F).pp
info-am:
info: info-recursive
dvi-am:
@@ -573,23 +452,24 @@ distclean-generic:
maintainer-clean-generic:
mostlyclean-am: mostlyclean-noinstPROGRAMS mostlyclean-compile \
mostlyclean-tags mostlyclean-generic
mostlyclean-tags mostlyclean-depend mostlyclean-generic
mostlyclean: mostlyclean-recursive
clean-am: clean-noinstPROGRAMS clean-compile clean-tags clean-generic \
mostlyclean-am
clean-am: clean-noinstPROGRAMS clean-compile clean-tags clean-depend \
clean-generic mostlyclean-am
clean: clean-recursive
distclean-am: distclean-noinstPROGRAMS distclean-compile distclean-tags \
distclean-generic clean-am
distclean-depend distclean-generic clean-am
distclean: distclean-recursive
maintainer-clean-am: maintainer-clean-noinstPROGRAMS \
maintainer-clean-compile maintainer-clean-tags \
maintainer-clean-generic distclean-am
maintainer-clean-depend maintainer-clean-generic \
distclean-am
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
@@ -604,17 +484,18 @@ uninstall-exec-recursive installdirs-recursive uninstalldirs-recursive \
all-recursive check-recursive installcheck-recursive info-recursive \
dvi-recursive mostlyclean-recursive distclean-recursive clean-recursive \
maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
distclean-tags clean-tags maintainer-clean-tags distdir info-am info \
dvi-am dvi check check-am installcheck-am installcheck \
install-exec-local install-exec-am install-exec install-data-am \
install-data install-am install uninstall-am uninstall all-redirect \
all-am all installdirs-am installdirs mostlyclean-generic \
distclean-generic clean-generic maintainer-clean-generic clean \
mostlyclean distclean maintainer-clean
distclean-tags clean-tags maintainer-clean-tags distdir \
mostlyclean-depend distclean-depend clean-depend \
maintainer-clean-depend info-am info dvi-am dvi check check-am \
installcheck-am installcheck install-exec-local install-exec-am \
install-exec install-data-am install-data install-am install \
uninstall-am uninstall all-redirect all-am all installdirs-am \
installdirs mostlyclean-generic distclean-generic clean-generic \
maintainer-clean-generic clean mostlyclean distclean maintainer-clean
install-exec-local:
@if [ "$(shell whoami)" != "root" ] ; then \
@if [ "`id -un`" != "root" ] ; then \
echo; echo " Must be root to install!"; echo; exit 3; \
fi
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 6711 mbsebbs $(bindir)
@@ -624,9 +505,9 @@ install-exec-local:
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbfbgen $(bindir)
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbstat $(bindir)
$(INSTALL) -s -o @OWNER@ -g @GROUP@ -m 0711 mbtoberep $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbuser $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbuseradd $(bindir)
$(INSTALL) -s -g root -o root -m 6711 mbpasswd $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbuser $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbuseradd $(bindir)
$(INSTALL) -s -o `id -un` -g `id -gn` -m 6711 mbpasswd $(bindir)
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbuseradd/commonio.c
* Purpose ...............: MBSE BBS Shadow Password Suite
* Last modification date : 07-Feb-2001
* Last modification date : 09-Aug-2001
* Original Source .......: Shadow Password Suite
* Original Copyrioght ...: Julianne Frances Haugh and others.
*
@@ -50,16 +50,19 @@
#include "commonio.h"
/* local function prototypes */
static int check_link_count (const char *);
static int do_lock_file (const char *, const char *);
static FILE *fopen_set_perms (const char *, const char *, const struct stat *);
static int create_backup (const char *, FILE *);
static void free_linked_list (struct commonio_db *);
static void add_one_entry (struct commonio_db *, struct commonio_entry *);
static int name_is_nis (const char *);
static int write_all (const struct commonio_db *);
static struct commonio_entry *find_entry_by_name (struct commonio_db *, const char *);
static int check_link_count (const char *);
static int do_lock_file (const char *, const char *);
static FILE *fopen_set_perms (const char *, const char *, const struct stat *);
static int create_backup (const char *, FILE *);
static void free_linked_list (struct commonio_db *);
static void add_one_entry (struct commonio_db *, struct commonio_entry *);
static int name_is_nis (const char *);
static int write_all (const struct commonio_db *);
static struct commonio_entry *find_entry_by_name (struct commonio_db *, const char *);
#ifdef HAVE_LCKPWDF
static int lock_count = 0;
#endif
static int check_link_count(const char *file)
{
@@ -142,8 +145,8 @@ static int do_lock_file(const char *file, const char *lock)
static FILE *fopen_set_perms(const char *name, const char *mode, const struct stat *sb)
{
FILE *fp;
int mask;
FILE *fp;
mode_t mask;
mask = umask(0777);
fp = fopen(name, mode);
@@ -151,14 +154,6 @@ static FILE *fopen_set_perms(const char *name, const char *mode, const struct st
if (!fp)
return NULL;
#ifdef HAVE_FCHMOD
if (fchmod(fileno(fp), sb->st_mode & 0777))
goto fail;
#else
if (chmod(name, sb->st_mode & 0777))
goto fail;
#endif
#ifdef HAVE_FCHOWN
if (fchown(fileno(fp), sb->st_uid, sb->st_gid))
goto fail;
@@ -166,6 +161,14 @@ static FILE *fopen_set_perms(const char *name, const char *mode, const struct st
if (chown(name, sb->st_mode))
goto fail;
#endif
#ifdef HAVE_FCHMOD
if (fchmod(fileno(fp), sb->st_mode & 0664))
goto fail;
#else
if (chmod(name, sb->st_mode & 0664))
goto fail;
#endif
return fp;
fail:
@@ -181,7 +184,8 @@ static int create_backup(const char *backup, FILE *fp)
struct stat sb;
struct utimbuf ub;
FILE *bkfp;
int c, mask;
int c;
mode_t mask;
if (fstat(fileno(fp), &sb))
return -1;
@@ -249,66 +253,71 @@ int commonio_present(const struct commonio_db *db)
int commonio_lock(struct commonio_db *db)
int commonio_lock_nowait(struct commonio_db *db)
{
char file[1024];
char lock[1024];
char file[1024];
char lock[1024];
if (db->locked)
return 1;
if (db->locked)
return 1;
snprintf(file, sizeof file, "%s.%ld", db->filename, (long) getpid());
snprintf(lock, sizeof lock, "%s.lock", db->filename);
if (do_lock_file(file, lock)) {
db->locked = 1;
return 1;
}
return 0;
snprintf(file, sizeof file, "%s.%ld", db->filename, (long) getpid());
snprintf(lock, sizeof lock, "%s.lock", db->filename);
if (do_lock_file(file, lock)) {
db->locked = 1;
return 1;
}
return 0;
}
int commonio_lock_first(struct commonio_db *db)
int commonio_lock(struct commonio_db *db)
{
int i;
#ifdef HAVE_LCKPWDF
/*
* When locking several files, *_lock_first() is called
* for the first one, and *_lock() for the others.
* If lckpwdf() is available, call it here (it may block
* for up to 15 seconds), and if it succeeds, call
* *_lock() once (no retries, it should always succeed).
*/
if (lckpwdf() == -1)
return 0; /* failure */
if (!commonio_lock(db)) {
ulckpwdf();
return 0; /* failure */
}
return 1; /* success */
#else
int i;
/*
* No lckpwdf() - do it the old way.
*/
/*
* only if the system libc has a real lckpwdf() - the one from
* lockpw.c calls us and would cause infinite recursion!
*/
if (db->use_lckpwdf) {
/*
* Call lckpwdf() on the first lock.
* If it succeeds, call *_lock() only once
* (no retries, it should always succeed).
*/
if (lock_count == 0) {
if (lckpwdf() == -1)
return 0; /* failure */
}
if (!commonio_lock_nowait(db)) {
ulckpwdf();
return 0; /* failure */
}
lock_count++;
return 1; /* success */
}
#endif
/*
* lckpwdf() not used - do it the old way.
*/
#ifndef LOCK_TRIES
#define LOCK_TRIES 15
#endif
for (i = 1; i < LOCK_TRIES; i++) {
if (commonio_lock(db))
return 1; /* success */
sleep(1);
}
/*
* Retry the last time...
*/
return commonio_lock(db);
#endif /* !HAVE_LCKPWDF */
#ifndef LOCK_SLEEP
#define LOCK_SLEEP 1
#endif
for (i = 0; i < LOCK_TRIES; i++) {
if (i > 0)
sleep(LOCK_SLEEP); /* delay between retries */
if (commonio_lock_nowait(db))
return 1; /* success */
/* no unnecessary retries on "permission denied" errors */
if (geteuid() != 0)
return 0;
}
return 0; /* failure */
}
@@ -322,13 +331,24 @@ int commonio_unlock(struct commonio_db *db)
if (!commonio_close(db))
return 0;
}
if (db->locked) {
db->locked = 0;
snprintf(lock, sizeof lock, "%s.lock", db->filename);
unlink(lock);
return 1;
}
return 0;
if (db->locked) {
/*
* Unlock in reverse order: remove the lock file,
* then call ulckpwdf() (if used) on last unlock.
*/
db->locked = 0;
snprintf(lock, sizeof lock, "%s.lock", db->filename);
unlink(lock);
#ifdef HAVE_LCKPWDF
if (db->use_lckpwdf && lock_count > 0) {
lock_count--;
if (lock_count == 0)
ulckpwdf();
}
#endif
return 1;
}
return 0;
}
@@ -508,6 +528,7 @@ int commonio_close(struct commonio_db *db)
goto success;
}
memset(&sb, 0, sizeof sb);
if (db->fp) {
if (fstat(fileno(db->fp), &sb)) {
fclose(db->fp);

View File

@@ -8,9 +8,9 @@
*/
struct commonio_entry {
char *line;
int changed;
void *entry; /* struct passwd, struct spwd, ... */
struct commonio_entry *prev, *next;
int changed:1;
};
@@ -85,7 +85,11 @@ struct commonio_db {
/*
* Various flags.
*/
int changed, isopen, locked, readonly;
int changed:1;
int isopen:1;
int locked:1;
int readonly:1;
int use_lckpwdf:1;
};
@@ -93,7 +97,7 @@ struct commonio_db {
int commonio_setname (struct commonio_db *, const char *);
int commonio_present (const struct commonio_db *);
int commonio_lock (struct commonio_db *);
int commonio_lock_first (struct commonio_db *);
int commonio_lock_nowait (struct commonio_db *);
int commonio_open (struct commonio_db *, int);
const void *commonio_locate (struct commonio_db *, const char *);
int commonio_update (struct commonio_db *, const void *);

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbuseradd/encrypt.c
* Purpose ...............: MBSE BBS Shadow Password Suite
* Last modification date : 13-May-2001
* Last modification date : 09-Aug-2001
* Original Source .......: Shadow Password Suite
* Original Copyrioght ...: Julianne Frances Haugh and others.
*
@@ -63,6 +63,7 @@
#include "../config.h"
#include <string.h>
#include <unistd.h>
#include <stdio.h>
#ifdef _XOPEN_CRYPT
#include <crypt.h>
#endif
@@ -113,6 +114,10 @@ char *pw_encrypt(const char *clear, const char *salt)
for (count = 0;count < 10;count++) {
cp = crypt (clear, salt);
if (!cp) {
perror("crypt");
exit(1);
}
if (strlen(cp) != 13)
return cp;
strcat (cipher, cp + 2);
@@ -125,6 +130,15 @@ char *pw_encrypt(const char *clear, const char *salt)
}
#else
cp = crypt (clear, salt);
if (!cp) {
/*
* Single Unix Spec: crypt() may return a null pointer,
* and set errno to indicate an error. The caller doesn't
* expect us to return NULL, so...
*/
perror("crypt");
exit(1);
}
if (strlen(cp) != 13)
return cp; /* nonstandard crypt() in libc, better bail out */
strcpy (cipher, cp);

View File

@@ -2,7 +2,7 @@
*
* File ..................: bbs/file.c
* Purpose ...............: All the file functions.
* Last modification date : 28-Jun-2001
* Last modification date : 10-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -473,7 +473,7 @@ void File_RawDir(char *OpData)
printf("%-20s", dp->d_name);
colour(13,0);
printf("%-12ld", statfile.st_size);
printf("%-12ld", (long)(statfile.st_size));
colour(10,0);
printf("%-10s\n", StrDateDMY(statfile.st_mtime));
@@ -1354,7 +1354,7 @@ void List_Home()
printf("%-20s", dp->d_name);
colour(13,0);
printf("%-12ld", statfile.st_size);
printf("%-12ld", (long)(statfile.st_size));
colour(10,0);
printf("%s ", StrDateDMY(statfile.st_mtime));
@@ -2098,7 +2098,7 @@ void EditTaglist()
Fg--;
colour(Fg, 0);
printf(" %8ld", Tag.Size);
printf(" %8ld", (long)(Tag.Size));
Fg--;
colour(Fg, 0);

View File

@@ -2,7 +2,7 @@
*
* File ..................: bbs/filesub.c
* Purpose ...............: All the file sub functions.
* Last modification date : 28-Jun-2001
* Last modification date : 09-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -427,9 +427,9 @@ int ShowOneFile()
colour(CFG.FilesizeF, CFG.FilesizeB);
if(strlen(file.Name) < 25)
printf("%10lu ", file.Size);
printf("%10lu ", (long)(file.Size));
else
printf("%25lu ", file.Size);
printf("%25lu ", (long)(file.Size));
colour(CFG.FiledateF, CFG.FiledateB);
printf("%-10s ", StrDateDMY(file.UploadDate));
@@ -813,7 +813,7 @@ int ImportFile(char *fn, int Area, int fileid, time_t iTime, off_t Size)
x = atoi(token);
Size *= i / x;
/* You have */ /* extra download KBytes. */
printf("%s %ld %s\n", (char *) Language(249), Size / 1024, (char *) Language(250));
printf("%s %ld %s\n", (char *) Language(249), (long)(Size / 1024), (char *) Language(250));
exitinfo.DownloadKToday += (Size / 1024);
Syslog('b', "DownloadKToday %d", exitinfo.DownloadKToday);
@@ -891,7 +891,7 @@ int Addfile(char *File, int AreaNum, int fileid)
memset(&file, 0, sizeof(file));
strcpy(file.Name, File);
sprintf(temp1,"%ld",statfile.st_size);
sprintf(temp1,"%ld",(long)(statfile.st_size));
file.Size = atoi(temp1);
file.FileDate = statfile.st_mtime;
strcpy(file.Uploader, exitinfo.sUserName);
@@ -998,7 +998,7 @@ int Addfile(char *File, int AreaNum, int fileid)
fprintf(pPrivate, "****************************************************");
fprintf(pPrivate, "\nUser : %s", file.Uploader);
fprintf(pPrivate, "\nFile : %s", file.Name);
fprintf(pPrivate, "\nSize : %lu", file.Size);
fprintf(pPrivate, "\nSize : %lu", (long)(file.Size));
fprintf(pPrivate, "\nUpload Date : %s\n\n", StrDateDMY(file.UploadDate));
for(i = 0; i < iDesc - 1; i++)

View File

@@ -2,7 +2,7 @@
*
* File ..................: bbs/funcs4.c
* Purpose ...............: Misc functions, also for some utils.
* Last modification date : 28-Jun-2001
* Last modification date : 08-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -834,14 +834,10 @@ int Check4UnixLogin(char *UsersName)
struct passwd *pw;
while ((pw = getpwent())) {
#ifdef linux
if(strcmp(pw->pw_gecos, UsersName) == 0) {
#else
if(strcmp(pw->pw_comment, UsersName) == 0) {
#endif
UID = pw->pw_uid;
break;
}
if(strcmp(pw->pw_gecos, UsersName) == 0) {
UID = pw->pw_uid;
break;
}
}
return UID;

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbuseradd/getdef.c
* Purpose ...............: MBSE BBS Shadow Password Suite
* Last modification date : 27-Jun-2001
* Last modification date : 09-Aug-2001
* Original Source .......: Shadow Password Suite
* Original Copyrioght ...: Julianne Frances Haugh and others.
*
@@ -78,30 +78,37 @@ struct itemdef {
char *value; /* value given, or NULL if no value */
};
/*
* This list *must* be sorted by the "name" member.
* This list *must* be sorted by the "name" member.
* It doesn't hurt that there are extra entries here
* that are not known by the system this is running
* on. Missing entries here gives a nasty message to
* new bbs users.
*/
#define NUMDEFS (sizeof(def_table)/sizeof(def_table[0]))
static struct itemdef def_table[] = {
{ "CHFN_AUTH", NULL },
{ "CHFN_RESTRICT", NULL },
{ "CLOSE_SESSIONS", NULL },
{ "CONSOLE", NULL },
{ "CONSOLE_GROUPS", NULL },
#ifdef HAVE_LIBCRACK
{ "CRACKLIB_DICTPATH", NULL },
#endif
{ "CREATE_HOME", NULL },
{ "DEFAULT_HOME", NULL },
{ "DIALUPS_CHECK_ENAB", NULL },
{ "ENVIRON_FILE", NULL },
{ "ENV_HZ", NULL },
{ "ENV_PATH" , NULL },
{ "ENV_ROOTPATH", NULL },
{ "ENV_SUPATH", NULL },
{ "ENV_TZ", NULL },
{ "ERASECHAR", NULL },
{ "FAILLOG_ENAB", NULL },
{ "FAIL_DELAY", NULL },
{ "FAKE_SHELL", NULL },
{ "FTMP_FILE", NULL },
{ "GID_MAX", NULL },
{ "GID_MIN", NULL },
@@ -121,6 +128,7 @@ static struct itemdef def_table[] = {
{ "MOTD_FILE", NULL },
{ "NOLOGINS_FILE", NULL },
{ "NOLOGIN_STR", NULL },
{ "NO_PASSWORD_CONSOLE", NULL },
{ "OBSCURE_CHECKS_ENAB", NULL },
{ "PASS_ALWAYS_WARN", NULL },
{ "PASS_CHANGE_TRIES", NULL },

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbsebbs/mball.c
* Purpose ...............: Creates allfiles listings
* Last modification date : 28-Jun-2001
* Last modification date : 09-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -564,7 +564,7 @@ void MakeIndex()
if (strlen(file.Desc[z])) {
if (z == 0)
fprintf(fp, "%-12s %7luK %s ", file.Name,
file.Size / 1024,
(long)(file.Size / 1024),
StrDateDMY(file.UploadDate));
else
fprintf(fp, " ");
@@ -604,7 +604,8 @@ void MakeIndex()
area.Path+strlen(CFG.ftp_base), file.Name, file.Name);
}
fprintf(fa, "<TD><PRE>%s</PRE></TD>", StrDateDMY(file.FileDate));
fprintf(fa, "<TD align=right><PRE>%lu Kb.</PRE></TD>", file.Size / 1024);
fprintf(fa, "<TD align=right><PRE>%lu Kb.</PRE></TD>",
(long)(file.Size / 1024));
fprintf(fa, "<TD><PRE>%8ld</PRE></TD>",
file.TimesDL + file.TimesFTP + file.TimesReq);
fprintf(fa, "<TD><PRE>");
@@ -856,7 +857,7 @@ void Masterlist()
if((!file.Deleted) && (!file.Missing)) {
New = (((t_start - file.UploadDate) / 84400) <= CFG.newdays);
sprintf(temp, "%-12s%10lu K %s [%04ld] Uploader: %s",
file.Name, file.Size / 1024, StrDateDMY(file.UploadDate),
file.Name, (long)(file.Size / 1024), StrDateDMY(file.UploadDate),
file.TimesDL + file.TimesFTP + file.TimesReq,
strlen(file.Uploader)?file.Uploader:"");
fprintf(fp, "%s\r\n", temp);

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbpasswd.c
* Purpose ...............: setuid root version of passwd
* Last modification date : 27-Jun-2001
* Last modification date : 10-Aug-2001
* Shadow Suite (c) ......: Julianne Frances Haugh
*
*****************************************************************************
@@ -32,10 +32,13 @@
#include "../config.h"
#include <stdio.h>
#include <sys/time.h>
#include <sys/types.h>
#ifdef HAVE_SYS_RESOURCE_H
#include <sys/resource.h>
#endif
#include <grp.h>
#include <pwd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <syslog.h>
#include <string.h>
@@ -43,9 +46,15 @@
#include <unistd.h>
#include <fcntl.h>
#include <time.h>
#include <stdlib.h>
#if defined(SHADOW_PASSWORD)
#include <shadow.h>
#endif
#ifdef HAVE_USERSEC_H
#include <userpw.h>
#include <usersec.h>
#include <userconf.h>
#endif
#include "encrypt.h"
#include "rad64.h"
@@ -107,12 +116,19 @@ static int force; /* Force update of locked passwords */
#ifndef __FreeBSD__
static void fail_exit(int status)
{
pw_unlock();
#ifdef SHADOWPWD
spw_unlock();
// gr_unlock();
#ifdef SHADOWGRP
if (is_shadow_grp)
sgr_unlock();
#endif
#ifdef SHADOWPWD
if (is_shadow_pwd)
spw_unlock();
#endif
pw_unlock();
exit(status);
}
@@ -121,7 +137,7 @@ static void fail_exit(int status)
static void oom(void)
{
fprintf(stderr, "mbpasswd: out of memory\n");
fail_exit(3);
fail_exit(E_FAILURE);
}
@@ -130,8 +146,7 @@ static void oom(void)
* insert_crypt_passwd - add an "old-style" password to authentication string
* result now malloced to avoid overflow, just in case. --marekm
*/
static char *
insert_crypt_passwd(const char *string, char *passwd)
static char *insert_crypt_passwd(const char *string, char *passwd)
{
#ifdef AUTH_METHODS
if (string && *string) {
@@ -158,9 +173,10 @@ insert_crypt_passwd(const char *string, char *passwd)
#endif
return xstrdup(passwd);
}
#endif /* FreeBSD */
#ifndef __FreeBSD__
static char *update_crypt_pw(char *cp)
{
if (do_update_pwd)
@@ -168,6 +184,7 @@ static char *update_crypt_pw(char *cp)
return cp;
}
#endif
@@ -178,6 +195,7 @@ static char *update_crypt_pw(char *cp)
*/
void pwd_init(void)
{
#ifdef HAVE_SYS_RESOURCE_H
struct rlimit rlim;
#ifdef RLIMIT_CORE
@@ -206,9 +224,14 @@ void pwd_init(void)
#ifdef RLIMIT_STACK
setrlimit(RLIMIT_STACK, &rlim);
#endif
#else /* !HAVE_SYS_RESOURCE_H */
set_filesize_limit(30000);
/* don't know how to set the other limits... */
#endif /* !HAVE_SYS_RESOURCE_H */
signal(SIGALRM, SIG_IGN);
signal(SIGHUP, SIG_IGN);
signal(SIGINT, SIG_IGN);
signal(SIGHUP, SIG_IGN);
signal(SIGINT, SIG_IGN);
signal(SIGPIPE, SIG_IGN);
signal(SIGQUIT, SIG_IGN);
signal(SIGTERM, SIG_IGN);
@@ -238,6 +261,12 @@ int isexpired(const struct passwd *pw)
{
#endif
long now;
#ifdef HAVE_USERSEC_H
int minage = 0;
int maxage = 10000;
int curage = 0;
struct userpw *pu;
#endif
now = time ((time_t *) 0) / SCALE;
@@ -267,24 +296,57 @@ int isexpired(const struct passwd *pw)
if (sp->sp_lstchg > 0 && sp->sp_max >= 0 && sp->sp_inact >= 0 &&
now >= sp->sp_lstchg + sp->sp_max + sp->sp_inact)
return 2;
#endif
#ifdef HAVE_USERSEC_H /*{*/
/*
* The aging information lives someplace else. Get it from the
* login.cfg file
*/
if (getconfattr (SC_SYS_PASSWD, SC_MINAGE, &minage, SEC_INT))
minage = -1;
if (getconfattr (SC_SYS_PASSWD, SC_MAXAGE, &maxage, SEC_INT))
maxage = -1;
pu = getuserpw (pw->pw_name);
curage = (time (0) - pu->upw_lastupdate) / (7*86400L);
if (maxage != -1 && curage > maxage)
return 1;
#else /*} !HAVE_USERSEC_H */
/*
* The last and max fields must be present for an account
* to have an expired password. A maximum of >10000 days
* is considered to be infinite.
*/
#ifdef SHADOWPWD
if (sp->sp_lstchg == -1 ||
sp->sp_max == -1 || sp->sp_max >= (10000L*DAY/SCALE))
return 0;
#endif
#ifdef ATT_AGE
if (pw->pw_age[0] == '\0' || pw->pw_age[0] == '/')
return 0;
#endif
/*
* Calculate today's day and the day on which the password
* is going to expire. If that date has already passed,
* the password has expired.
*/
#ifdef SHADOWPWD
if (now >= sp->sp_lstchg + sp->sp_max)
return 1;
#endif
#ifdef ATT_AGE
if (a64l (pw->pw_age + 2) + c64i (pw->pw_age[1]) < now / 7)
return 1;
#endif
#endif /*} HAVE_USERSEC_H */
return 0;
}
@@ -305,6 +367,9 @@ static void check_password(const struct passwd *pw)
#endif
time_t now, last, ok;
int exp_status;
#ifdef HAVE_USERSEC_H
struct userpw *pu;
#endif
#ifdef SHADOW_PASSWORD
exp_status = isexpired(pw, sp);
@@ -332,7 +397,7 @@ static void check_password(const struct passwd *pw)
fprintf (stderr, "The password for %s cannot be changed.\n", sp->sp_namp);
syslog(LOG_WARNING, "password locked for %s", sp->sp_namp);
closelog();
exit (1);
exit (E_NOPERM);
}
/*
@@ -346,16 +411,34 @@ static void check_password(const struct passwd *pw)
fprintf (stderr, "The password for %s cannot be changed.\n", pw->pw_name);
syslog(LOG_WARNING, "password locked for %s", pw->pw_name);
closelog();
exit (1);
exit (E_NOPERM);
}
last = 0;
ok = 0;
#ifdef ATT_AGE
/*
* Can always be changed if there is no age info
*/
if (! pw->pw_age[0])
return;
last = a64l (pw->pw_age + 2) * WEEK;
ok = last + c64i (pw->pw_age[1]) * WEEK;
#else /* !ATT_AGE */
#ifdef HAVE_USERSEC_H
pu = getuserpw(pw->pw_name);
last = pu ? pu->upw_lastupdate : 0L;
ok = last + (minage > 0 ? minage * WEEK : 0);
#else
last = 0;
ok = 0;
#endif
#endif /* !ATT_AGE */
#endif /* !SHADOW_PASSWORD */
if (now < ok) {
fprintf(stderr, "Sorry, the password for %s cannot be changed yet.\n", pw->pw_name);
syslog(LOG_WARNING, "now < minimum age for `%s'", pw->pw_name);
closelog();
exit (1);
exit (E_NOPERM);
}
}
@@ -381,12 +464,34 @@ struct spwd *pwd_to_spwd(const struct passwd *pw)
sp.sp_namp = pw->pw_name;
sp.sp_pwdp = pw->pw_passwd;
#ifdef ATT_AGE
/*
* Defaults used if there is no pw_age information.
* AT&T-style password aging maps the sp_min, sp_max, and
* sp_lstchg information from the pw_age field, which appears
* after the encrypted password.
*/
sp.sp_min = 0;
sp.sp_max = (10000L * DAY) / SCALE;
sp.sp_lstchg = time((time_t *) 0) / SCALE;
if (pw->pw_age[0]) {
sp.sp_max = (c64i(pw->pw_age[0]) * WEEK) / SCALE;
if (pw->pw_age[1])
sp.sp_min = (c64i(pw->pw_age[1]) * WEEK) / SCALE;
else
sp.sp_min = (10000L * DAY) / SCALE;
if (pw->pw_age[1] && pw->pw_age[2])
sp.sp_lstchg = (a64l(pw->pw_age + 2) * WEEK) / SCALE;
else
sp.sp_lstchg = time((time_t *) 0) / SCALE;
} else
#endif
{
/*
* Defaults used if there is no pw_age information.
*/
sp.sp_min = 0;
sp.sp_max = (10000L * DAY) / SCALE;
sp.sp_lstchg = time((time_t *) 0) / SCALE;
}
/*
* These fields have no corresponding information in the password
@@ -421,7 +526,7 @@ static int new_password(const struct passwd *pw, char *newpasswd)
* Encrypt the password, then wipe the cleartext password.
*/
cp = pw_encrypt(pass, crypt_make_salt());
bzero(pass, sizeof pass);
memset(&pass, 0, sizeof(pass));
#ifdef HAVE_LIBCRACK_HIST
HistUpdate(pw->pw_name, crypt_passwd);
@@ -431,11 +536,17 @@ static int new_password(const struct passwd *pw, char *newpasswd)
}
#ifndef __FreeBSD__
static void update_noshadow(int shadow_locked)
{
const struct passwd *pw;
struct passwd *npw;
const struct passwd *pw;
struct passwd *npw;
#ifdef ATT_AGE
char age[5];
long week = time((time_t *) 0) / WEEK;
char *cp;
#endif
/*
* call this with shadow_locked != 0 to avoid calling lckpwdf()
@@ -444,38 +555,112 @@ static void update_noshadow(int shadow_locked)
* and call lckpwdf() only before the first lock, and ulckpwdf()
* after the last unlock.
*/
if (!(shadow_locked ? pw_lock() : pw_lock_first())) {
fprintf(stderr, "Cannot lock the password file; try again later.\n");
if (!pw_lock()) {
fprintf(stderr, "Cannot lock the password file; try again later.\n");
syslog(LOG_WARNING, "can't lock password file");
exit(5);
exit(E_PWDBUSY);
}
if (!pw_open(O_RDWR)) {
fprintf(stderr, "Cannot open the password file.\n");
syslog(LOG_ERR, "can't open password file");
fail_exit(3);
fail_exit(E_MISSING);
}
pw = pw_locate(name);
if (!pw) {
fprintf(stderr, "mbpasswd: user %s not found in /etc/passwd\n", name);
fail_exit(1);
fail_exit(E_NOPERM);
}
npw = __pw_dup(pw);
if (!npw)
oom();
npw->pw_passwd = update_crypt_pw(npw->pw_passwd);
#ifdef ATT_AGE
memset(age, 0, sizeof(age));
STRFCPY(age, npw->pw_age);
/*
* Just changing the password - update the last change date
* if there is one, otherwise the age just disappears.
*/
if (do_update_age) {
if (strlen(age) > 2) {
cp = l64a(week);
age[2] = cp[0];
age[3] = cp[1];
} else {
age[0] = '\0';
}
}
if (xflg) {
if (age_max > 0)
age[0] = i64c((age_max + 6) / 7);
else
age[0] = '.';
if (age[1] == '\0')
age[1] = '.';
}
if (nflg) {
if (age[0] == '\0')
age[0] = 'z';
if (age_min > 0)
age[1] = i64c((age_min + 6) / 7);
else
age[1] = '.';
}
/*
* The last change date is added by -n or -x if it's
* not already there.
*/
if ((nflg || xflg) && strlen(age) <= 2) {
cp = l64a(week);
age[2] = cp[0];
age[3] = cp[1];
}
/*
* Force password change - if last change date is
* present, it will be set to (today - max - 1 week).
* Otherwise, just set min = max = 0 (will disappear
* when password is changed).
*/
if (eflg) {
if (strlen(age) > 2) {
cp = l64a(week - c64i(age[0]) - 1);
age[2] = cp[0];
age[3] = cp[1];
} else {
strcpy(age, "..");
}
}
npw->pw_age = age;
#endif
if (!pw_update(npw)) {
fprintf(stderr, "Error updating the password entry.\n");
syslog(LOG_ERR, "error updating password entry");
fail_exit(3);
fail_exit(E_FAILURE);
}
#ifdef NDBM
if (pw_dbm_present() && !pw_dbm_update(npw)) {
fprintf(stderr, _("Error updating the DBM password entry.\n"));
SYSLOG((LOG_ERR, DBMERROR2));
fail_exit(E_FAILURE);
}
endpwent();
#endif
if (!pw_close()) {
fprintf(stderr, "Cannot commit password file changes.\n");
syslog(LOG_ERR, "can't rewrite password file");
fail_exit(3);
fail_exit(E_FAILURE);
}
pw_unlock();
}
#endif /* Not __FreeBSD__ */
#ifdef SHADOW_PASSWORD
@@ -484,28 +669,23 @@ static void update_shadow(void)
const struct spwd *sp;
struct spwd *nsp;
if (!spw_lock_first()) {
if (!spw_lock()) {
fprintf(stderr, "Cannot lock the password file; try again later.\n");
syslog(LOG_WARNING, "can't lock password file");
exit(5);
exit(E_PWDBUSY);
}
if (!spw_open(O_RDWR)) {
fprintf(stderr, "Cannot open the password file.\n");
syslog(LOG_ERR, "can't open password file");
fail_exit(3);
fail_exit(E_FAILURE);
}
sp = spw_locate(name);
if (!sp) {
#if 0
fprintf(stderr, "%s: user %s not found in /etc/shadow\n",
Prog, name);
fail_exit(1);
#else
/* Try to update the password in /etc/passwd instead. */
spw_unlock();
spw_close();
update_noshadow(1);
spw_unlock();
return;
#endif
}
nsp = __spw_dup(sp);
if (!nsp)
@@ -517,12 +697,20 @@ static void update_shadow(void)
if (!spw_update(nsp)) {
fprintf(stderr, "Error updating the password entry.\n");
syslog(LOG_ERR, "error updating password entry");
fail_exit(3);
fail_exit(E_FAILURE);
}
#ifdef NDBM
if (sp_dbm_present() && !sp_dbm_update(nsp)) {
fprintf(stderr, _("Error updating the DBM password entry.\n"));
SYSLOG((LOG_ERR, DBMERROR2));
fail_exit(E_FAILURE);
}
endspent();
#endif
if (!spw_close()) {
fprintf(stderr, "Cannot commit password file changes.\n");
syslog(LOG_ERR, "can't rewrite password file");
fail_exit(3);
fail_exit(E_FAILURE);
}
spw_unlock();
}
@@ -541,7 +729,11 @@ int main(int argc, char *argv[])
#ifdef SHADOW_PASSWORD
const struct spwd *sp;
#endif
char *cp;
char *cp;
#ifdef __FreeBSD__
char temp[81];
char cmd[256];
#endif
/*
* Get my username
@@ -560,11 +752,11 @@ int main(int argc, char *argv[])
gr = getgrgid(pw->pw_gid);
if (!gr) {
fprintf(stderr, "mbpasswd: Cannot determine group name.\n");
exit(1);
exit(E_NOPERM);
}
if (strcmp(gr->gr_name, (char *)"bbs")) {
fprintf(stderr, "mbpasswd: You are not a member of group \"bbs\".\n");
exit(1);
exit(E_NOPERM);
}
// NOOT dit programma moet kontroleren of het is aangeroepen door mbsebbs.
@@ -577,7 +769,7 @@ int main(int argc, char *argv[])
printf("mbpasswd [-opt] [username] [newpassword]\n");
printf("options are: -n normal password change\n");
printf(" -f forced password change\n");
exit(1);
exit(E_FAILURE);
}
if (strncmp(argv[1], "-f", 2) == 0)
@@ -590,17 +782,17 @@ int main(int argc, char *argv[])
*/
if (strlen(argv[2]) > 16) {
fprintf(stderr, "mbpasswd: Username too long\n");
exit(1);
exit(E_FAILURE);
}
if (strlen(argv[3]) > 16) {
fprintf(stderr, "mbpasswd: Password too long\n");
exit(1);
exit(E_FAILURE);
}
name = strdup(argv[2]);
if ((pw = getpwnam(name)) == NULL) {
fprintf(stderr, "mbpasswd: Unknown user %s\n", name);
exit(1);
exit(E_FAILURE);
}
openlog("mbpasswd", LOG_PID|LOG_CONS|LOG_NOWAIT, LOG_AUTH);
@@ -627,8 +819,9 @@ int main(int argc, char *argv[])
if (new_password(pw, argv[3])) {
fprintf(stderr, "The password for %s is unchanged.\n", name);
syslog(LOG_ERR, "The password for %s is unchanged", name);
closelog();
exit(1);
exit(E_FAILURE);
}
do_update_pwd = 1;
do_update_age = 1;
@@ -645,19 +838,57 @@ int main(int argc, char *argv[])
fprintf(stderr, "Cannot change ID to root.\n");
syslog(LOG_ERR, "can't setuid(0)");
closelog();
exit(1);
exit(E_FAILURE);
}
#ifndef __FreeBSD__
#ifdef HAVE_USERSEC_H
update_userpw(pw->pw_passwd);
#else /* !HAVE_USERSEC_H */
#ifdef SHADOW_PASSWORD
if (spw_file_present())
update_shadow();
else
#endif
update_noshadow(0);
#endif /* !HAVE_USERSEC_H */
#else /* __FreeBSD__ */
/*
* FreeBSD has no interface (that I know of) to change the users password,
* but they do have a utility that does it. We will use that.
*/
if ((access("/usr/bin/chpass", X_OK)) == 0)
strcpy(temp, "/usr/bin/chpass");
else if ((access("/usr/sbin/chpass", X_OK)) == 0)
strcpy(temp, "/usr/sbin/chpass");
else if ((access("/bin/chpass", X_OK)) == 0)
strcpy(temp, "/bin/chpass");
else if ((access("/sbin/chpass", X_OK)) == 0)
strcpy(temp, "/sbin/chpass");
else {
fprintf(stderr, "mbpasswd: Can't find chpass\n");
syslog(LOG_INFO, "Can't find chpass");
closelog();
exit(E_FAILURE);
}
sprintf(cmd, "%s -p \"%s\" %s", temp, crypt_passwd, name);
if (system(cmd) != 0) {
perror("mbpasswd: failed to change password\n");
syslog(LOG_INFO, "password change for `%s' failed", name);
closelog();
exit(E_FAILURE);
}
#endif /* __FreeBSD__ */
syslog(LOG_INFO, "password for `%s' changed by user `%s'", name, myname);
closelog();
exit(0);
exit(E_SUCCESS);
}

View File

@@ -6,21 +6,35 @@
#define STRFCPY(A,B) \
(strncpy((A), (B), sizeof(A) - 1), (A)[sizeof(A) - 1] = '\0')
/*
* exit status values
*/
#define E_SUCCESS 0 /* success */
#define E_NOPERM 1 /* permission denied */
#define E_USAGE 2 /* invalid combination of options */
#define E_FAILURE 3 /* unexpected failure, nothing done */
#define E_MISSING 4 /* unexpected failure, passwd file missing */
#define E_PWDBUSY 5 /* passwd file busy, try again later */
#define E_BAD_ARG 6 /* invalid argument to option */
/*
* Function prototypes
*/
struct passwd *get_my_pwent(void);
static int new_password (const struct passwd *, char *);
static void fail_exit(int);
static void oom(void);
void pwd_init(void);
char *crypt_make_salt(void);
char *pw_encrypt(const char *, const char *);
int i64c(int);
char *l64a(long);
#ifndef __FreeBSD__
static void fail_exit(int);
static void oom(void);
static void update_noshadow(int);
#endif
#ifdef SHADOW_PASSWORD
struct spwd *pwd_to_spwd(const struct passwd *);
static void update_shadow(void);

View File

@@ -102,6 +102,13 @@ int main(int argc, char **argv)
#endif
exit(1);
}
// if (seteuid(pw->pw_uid) == -1) {
// perror("Can't seteuid() to \"mbse\" user");
//#ifdef MEMWATCH
// mwTerm();
//#endif
// exit(1);
// }
/*
* Set local time and statistic indexes.
@@ -158,7 +165,7 @@ int main(int argc, char **argv)
sprintf(pTTY, "%s", tty);
}
umask(007);
umask(000);
/*
* Trap signals

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbtoberep/mbtoberep.c
* Purpose ...............: Show contents of toberep.data
* Last modification date : 28-Jun-2001
* Last modification date : 09-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -69,7 +69,7 @@ int main(int argc, char **argv)
printf("Comment %s\n", rep.Comment);
printf("Group %s\n", rep.Group);
printf("File name %s\n", rep.Name);
printf("FIle size %lu\n", rep.Size);
printf("FIle size %lu\n", (long)(rep.Size));
printf("File size Kb %lu\n", rep.SizeKb);
printf("File date %s", ctime(&rep.Fdate));
printf("File CRC %s\n", rep.Crc);

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbuser/mbuser.c
* Purpose ...............: User Pack Util
* Last modification date : 01-Jul-2001
* Last modification date : 12-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -305,8 +305,13 @@ void UserPack(int days, int level, int pack)
WriteError("Cannot setuid(root) or setgid(root)");
WriteError("Cannot delete unix account %s", usr.Name);
} else {
#ifndef __FreeBSD__
rc = execute((char *)"/usr/sbin/userdel ", usr.Name, NULL,
(char *)"/dev/null",(char *)"/dev/null",(char *)"/dev/null");
#else
rc = execute((char *)"/usr/sbin/pw userdel ", usr.Name, NULL,
(char *)"/dev/null",(char *)"/dev/null",(char *)"/dev/null");
#endif
if (chdir(CFG.bbs_usersdir) == 0)
rc = execute((char *)"/bin/rm -Rf ", usr.Name, NULL,
(char *)"/dev/null",(char *)"/dev/null",(char *)"/dev/null");

View File

@@ -2,7 +2,7 @@
*
* File ..................: mbuseradd.c
* Purpose ...............: setuid root version of useradd
* Last modification date : 28-Jun-2001
* Last modification date : 25-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -41,8 +41,7 @@
#include <errno.h>
#include <signal.h>
#include <sys/wait.h>
#include <linux/limits.h>
#include <sys/param.h>
#include "mbuseradd.h"
@@ -71,7 +70,7 @@ int execute(char *cmd, char *file, char *in, char *out, char *err)
if (open(in, O_RDONLY) != 0) {
perror("");
fprintf(stderr, "mbuseradd: Reopen of stdin to %s failed\n", in);
exit(-1);
_exit(-1);
}
}
if (out) {
@@ -79,7 +78,7 @@ int execute(char *cmd, char *file, char *in, char *out, char *err)
if (open(out, O_WRONLY | O_APPEND | O_CREAT,0600) != 1) {
perror("");
fprintf(stderr, "mbuseradd: Reopen of stdout to %s failed\n", out);
exit(-1);
_exit(-1);
}
}
if (err) {
@@ -87,12 +86,12 @@ int execute(char *cmd, char *file, char *in, char *out, char *err)
if (open(err, O_WRONLY | O_APPEND | O_CREAT,0600) != 2) {
perror("");
fprintf(stderr, "mbuseradd: Reopen of stderr to %s failed\n", err);
exit(-1);
_exit(-1);
}
}
rc = execv(vector[0],vector);
fprintf(stderr, "mbuseradd: Exec \"%s\" returned %d\n", vector[0], rc);
exit(-1);
_exit(-1);
}
do {
@@ -135,19 +134,13 @@ int main(int argc, char *argv[])
char *PassEnt, *temp, *shell;
int i;
struct passwd *pwent, *pwuser;
FILE *fp;
if (setuid(0) == -1 || setgid(1) == -1) {
perror("");
fprintf(stderr, "mbuseradd: Unable to setuid(root) or setgid(root)\n");
fprintf(stderr, "Make sure that this program is set to -rwsr-sr-x\n");
fprintf(stderr, "Owner must be root and group root\n");
exit(1);
}
if (argc != 5)
Help();
/*
* First simple check for argument overflow
*/
for (i = 1; i < 5; i++) {
if (strlen(argv[i]) > 80) {
fprintf(stderr, "mbuseradd: Argument %d is too long\n", i);
@@ -159,10 +152,20 @@ int main(int argc, char *argv[])
temp = calloc(PATH_MAX, sizeof(char));
shell = calloc(PATH_MAX, sizeof(char));
if (setuid(0) == -1 || setgid(1) == -1) {
perror("");
fprintf(stderr, "mbuseradd: Unable to setuid(root) or setgid(root)\n");
fprintf(stderr, "Make sure that this program is set to -rwsr-sr-x\n");
fprintf(stderr, "Owner must be root and group root\n");
exit(1);
}
umask(0000);
/*
* Build command to add user entry to the /etc/passwd and /etc/shadow
* files. We use the systems own useradd program.
*/
#ifdef __linux__
if ((access("/usr/bin/useradd", R_OK)) == 0)
strcpy(temp, "/usr/bin/useradd");
else if ((access("/bin/useradd", R_OK)) == 0)
@@ -175,11 +178,30 @@ int main(int argc, char *argv[])
fprintf(stderr, "mbuseradd: Can't find useradd\n");
exit(1);
}
#elif __FreeBSD__
if ((access("/usr/sbin/pw", X_OK)) == 0)
strcpy(temp, "/usr/sbin/pw");
else if ((access("/sbin/pw", X_OK)) == 0)
strcpy(temp, "/sbin/pw");
else {
fprintf(stderr, "mbuseradd: Can't find pw\n");
exit(1);
}
#else
fprintf(stderr, "mbuseradd: Don't know how to add a user on this OS\n");
exit(1);
#endif
sprintf(shell, "%s/bin/mbsebbs", getenv("MBSE_ROOT"));
#ifdef __linux__
sprintf(PassEnt, "%s -c \"%s\" -d %s/%s -g %s -s %s %s",
temp, argv[3], argv[4], argv[2], argv[1], shell, argv[2]);
#endif
#ifdef __FreeBSD__
sprintf(PassEnt, "%s useradd %s -c \"%s\" -d %s/%s -g %s -s %s",
temp, argv[2], argv[3], argv[4], argv[2], argv[1], shell);
#endif
fflush(stdout);
fflush(stdin);

View File

@@ -2,12 +2,12 @@
*
* File ..................: mbuseradd/pwio.c
* Purpose ...............: MBSE BBS Shadow Password Suite
* Last modification date : 18-Sep-2000
* Last modification date : 09-Aug-2001
* Original Source .......: Shadow Password Suite
* Original Copyrioght ...: Julianne Frances Haugh and others.
*
*****************************************************************************
* Copyright (C) 1997-2000
* Copyright (C) 1997-2001
*
* Michiel Broek FIDO: 2:280/2802
* Beekmansbos 10
@@ -43,6 +43,9 @@
#include <string.h>
#include "sgetpwent.h"
#include "commonio.h"
#ifndef HAVE_PUTPWENT
#include "putpwent.h"
#endif
#include "pwio.h"
@@ -143,16 +146,17 @@ static struct commonio_ops passwd_ops = {
static struct commonio_db passwd_db = {
"/etc/passwd",
&passwd_ops,
NULL,
NULL,
NULL,
NULL,
0,
0,
0,
0
PASSWD_FILE, /* filename */
&passwd_ops, /* ops */
NULL, /* fp */
NULL, /* head */
NULL, /* tail */
NULL, /* cursor */
0, /* changed */
0, /* isopen */
0, /* locked */
0, /* readonly */
1 /* use_lckpwdf */
};
@@ -171,13 +175,6 @@ int pw_lock(void)
int pw_lock_first(void)
{
return commonio_lock_first(&passwd_db);
}
int pw_open(int mode)
{
return commonio_open(&passwd_db, mode);

View File

@@ -1,6 +1,14 @@
#ifndef _PWIO_H
#define _PWIO_H
#ifndef PASSWD_FILE
#define PASSWD_FILE "/etc/passwd"
#endif
#ifndef GROUP_FILE
#define GROUP_FILE "/etc/group"
#endif
struct passwd *__pw_dup (const struct passwd *);
void __pw_set_changed (void);
int pw_close (void);

View File

@@ -2,12 +2,12 @@
*
* File ..................: mbuseradd/shadowio.c
* Purpose ...............: MBSE BBS Shadow Password Suite
* Last modification date : 13-Aug-2000
* Last modification date : 09-Aug-2001
* Original Source .......: Shadow Password Suite
* Original Copyrioght ...: Julianne Frances Haugh and others.
*
*****************************************************************************
* Copyright (C) 1997-2000
* Copyright (C) 1997-2001
*
* Michiel Broek FIDO: 2:280/2802
* Beekmansbos 10
@@ -117,16 +117,17 @@ static struct commonio_ops shadow_ops = {
static struct commonio_db shadow_db = {
SHADOW_FILE,
&shadow_ops,
NULL,
NULL,
NULL,
NULL,
0,
0,
0,
0
SHADOW_FILE, /* filename */
&shadow_ops, /* ops */
NULL, /* fp */
NULL, /* head */
NULL, /* tail */
NULL, /* cursor */
0, /* changed */
0, /* isopen */
0, /* locked */
0, /* readonly */
1 /* use_lckpwdf */
};
@@ -152,13 +153,6 @@ int spw_lock(void)
int spw_lock_first(void)
{
return commonio_lock_first(&shadow_db);
}
int spw_open(int mode)
{
return commonio_open(&shadow_db, mode);

View File

@@ -5,6 +5,13 @@
#ifndef SHADOW_FILE
#define SHADOW_FILE "/etc/shadow"
#endif
#ifdef SHADOWGRP
#ifndef SGROUP_FILE
#define SGROUP_FILE "/etc/gshadow"
#endif
#endif
#endif
@@ -14,7 +21,6 @@ int spw_close (void);
int spw_file_present (void);
const struct spwd *spw_locate (const char *);
int spw_lock (void);
int spw_lock_first (void);
int spw_name (const char *);
const struct spwd *spw_next (void);
int spw_open (int);

View File

@@ -4,7 +4,7 @@
* Purpose ...............: Main user login procedure. Checks for limits,
* new ratio's cats all the welcome screens, and
* does a lot of checking in general.
* Last modification date : 28-Jun-2001
* Last modification date : 08-Aug-2001
*
*****************************************************************************
* Copyright (C) 1997-2001
@@ -615,11 +615,7 @@ void user()
} else {
Syslog('+', "Unixmode login: %s", sUnixName);
if ((pw = getpwnam(sUnixName)))
#ifdef linux
strcpy(sGetName, pw->pw_gecos);
#else
strcpy(sGetName, pw->pw_comment);
#endif
/*
* If there are more fields in the passwd gecos field