[Android-tools-devel] setuid on android

Matt Flax flatmax at flatmax.org
Sat Dec 29 06:34:14 UTC 2012


Hi there,

I have been experimenting with setting up a chroot debian server on an
android.
I have some questions and was wondering whether anyone here would be
able to help me please ?

The problem I am working with is allowing the Debian exim executable to
setuid and gid. I get the following error :
unable to set gid=1002 or uid=1002 (euid=103): local delivery to .......

I am aware that the android kernel has extra security (for example
requiring group 3003 to create AF_INET sockets + others) I am wondering
whether anyone out there knows of a trick to enable uid and gid changes
by an executable ?

Here is the longer story ...

I am having trouble setting up exim4. If for example you want to send
from the server to the web,  you can set Debian-exim as part of the 3003
group and set deliver_drop_privilege=true in the exim4.conf.template
file (which requires update-exim.conf to be called for refresh+init.d
restart)

However when deliver_drop_privelege is set, Debian-exim can't deliver
locally. The problem is that Debian-exim tries to set gid and uid to the
user 'userName' before altering their /home/userName/Maildir files ....
unfortunately the android kernel will not allow this to happen and it
gives the unable to set 'gid=....' error mentioned at the top of this
message.

Any ideas or help appreciated.
Matt



More information about the Android-tools-devel mailing list