I am running this small python script on both linux and Solaris as a not privileged user :
#!/usr/bin/python
import os
print 'uid,euid =',os.getuid(),os.geteuid()
Before running, the setuid bit is set on the script (not on python interpreter) :
chown root:myusergrp getuid.py
chmod 4750 getuid.py
On Solaris, the effective uid is set because of the setuid bit :
uid,euid = 10002 0
But not on Linux :
uid,euid = 10002 10002
Note the python version is 2.6 for both Solaris and Linux
Is it possibe to have Python Linux working as Python Solaris ?