Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F161486333
D28154.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
838 B
Referenced Files
None
Subscribers
None
D28154.id.diff
View Options
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c
--- a/sys/kern/kern_exec.c
+++ b/sys/kern/kern_exec.c
@@ -355,6 +355,16 @@
return (do_execve(td, args, mac_p, oldvmspace));
}
+static void
+execve_nosetid(struct image_params *imgp)
+{
+ imgp->credential_setid = false;
+ if (imgp->newcred != NULL) {
+ crfree(imgp->newcred);
+ imgp->newcred = NULL;
+ }
+}
+
/*
* In-kernel implementation of execve(). All arguments are assumed to be
* userspace pointers from the passed thread.
@@ -643,11 +653,7 @@
vput(newtextvp);
vm_object_deallocate(imgp->object);
imgp->object = NULL;
- imgp->credential_setid = false;
- if (imgp->newcred != NULL) {
- crfree(imgp->newcred);
- imgp->newcred = NULL;
- }
+ execve_nosetid(imgp);
imgp->execpath = NULL;
free(imgp->freepath, M_TEMP);
imgp->freepath = NULL;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jul 5, 5:50 AM (14 h, 49 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
34695045
Default Alt Text
D28154.id.diff (838 B)
Attached To
Mode
D28154: Add compat.linux.setid_allowed knob
Attached
Detach File
Event Timeline
Log In to Comment