New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expose setresuid #50757
Comments
Python should expose setresuid in the same module that exposes setuid. The reason why is complicated, but is best explained here: http://www.eecs.berkeley.edu/~daw/papers/setuid-usenix02.pdf I might work on a patch to implement this. |
should also expose setresgid for same reason. Paper also defines a higher-level API in section 8.2.1 that would |
Where would be the best place to put these non-POSIX calls? I looked at posixmodule.c and it's a mess; much conditional CPP logic Perhaps there should be a module called Unix or something? Also, knowing whether the functions were avaiable at compile time would Thoughts? |
Yes, just put it near the numerous set_XXXuid functions, protected with a |
Don't worry about that - the POSIX module is the right place, despite
That wouldn't reduce the need to remove CPP logic. I personally don't
I don't understand. When you compile for a specific Unix, it either has
Correct - you need to change configure.in as well. |
I have coded up a first draft at implemented {get,set}res{gid,uid} I cannot test this in my current environment because I'm stuck with Red |
FWIW, it may be an _autoconf_ version issue; I'm able to recreate a |
Please do try this out on your system. Installing autoconf locally is ./configure --prefix=$HOME/ac261 This will give you $HOME/ac261/bin/auto{conf|header}; automake is not |
Your patch looks right, although I have a few style issues:
|
Simplified if/else chaining Uploading here before testing on new machine (m4 was too old on previous |
I applied the same patch to Python 2.6.2 and believe that I got the I also executed autoconf to convert configure.in to configure, and I ran "strings" on libpython2.6a and found that it has the strings Does anyone have any idea why this might be? I'm trying hard to get |
Your patch looks good (except that in getresuid, you seem to be missing The one puzzling detail is that you don't include a patch to |
This patch fixes a number of typos in the original and, to my knowledge, I have tested this manually and confirmed that it works. I would start |
On Fri, Sep 18, 2009 at 07:44:56AM +0000, Martin v. L??wis wrote:
I am testing it out now on a more up-to-date machine.
No, I did not - it has been a long time since I was familiar with I've now got a complete, tested patch up on bugs.python.orgObama Nation | My emails do not have attachments; it's a digital signature |
So this patch is done and tested, but no movement on it since 18 |
I'll take care of it. It needs unittests but those will be trivial. |
Attaching an updated patch that includes unittests. I also changed the set functions to take input as long's instead of int's Remaining work: os module documentation. |
I have now added documentation to os.rst, and committed the patch as Thanks for contributing it. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: