[Twisted-Python] Switch to a different uid/gid after binding reserved ports

Itamar Shtull-Trauring itamar at itamarst.org
Sun Jun 8 05:54:34 MDT 2003


On Sun, 8 Jun 2003 11:10:00 +0100
"Richard Townsend" <richard at starfighter.freeuk.com> wrote:

> I want it to listen on reserved port 80, and then switch to a
> different uid/gid but it's not clear to me how to do this. Could
> someone please explain what the necessary steps should be?

At a guess, set uid and gid attributes on the Application instance, then
run() it as root.

> (Note: I can't use twistd because it would not compatible with our
> system architecture).

The sounds very unlikely. Are you aware of the "twistd -y" option?


-- 
Itamar Shtull-Trauring    http://itamarst.org/
http://www.zoteca.com -- Python & Twisted consulting




More information about the Twisted-Python mailing list