Return to BSD News archive
Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!news.cs.su.oz.au!inferno.mpx.com.au!news.unimelb.EDU.AU!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!dciteleport.com!usenet.logical.net!node2.frontiernet.net!not-for-mail From: dsf@node6.frontiernet.net (Dan Foster) Newsgroups: comp.unix.bsd.freebsd.misc Subject: Getting encrypted password information - a better way? Date: 27 Dec 1996 05:39:27 -0500 Organization: Frontier Internet, A reliable part of your life Lines: 25 Message-ID: <5a090v$o5u@node6.frontiernet.net> NNTP-Posting-Host: node6.frontiernet.net Xref: euryale.cc.adfa.oz.au comp.unix.bsd.freebsd.misc:33338 I wasn't sure if this was a suitable item to send-pr, so I didn't. Anyway... problem: I have cyrus IMAP server (v1.4) and FreeBSD 2.1.5-RELEASE. I had to make minor modifications in order to make imapd work under FreeBSD. Biggest single problem? Apparently, under FreeBSD, you get encrypted password info only if your euid is 0. But... cyrus imapd *insists* on having a non-zero euid. Temporary workaround/terrible hack: make imapd suid root, and then immediately put a setreuid(<cyrus user uid>); and doing this later on: setreuid(0); getpwnam(); setreuid(<cyrus user uid>); in order to get the encrypted password information. I'm sure there's a better way to do this, implementation-wise. Any suggestions? Would be glad to summarize solution. Once I have this fixed, I'll submit a formal patch to the cyrus group. -Dan Foster Internet: dsf@frontiernet.net