apache RewriteMap program running as root user
Issue
Out web application provides a script which is used as a RewriteMap prg:
RewriteMap token_authorization prg:/my-app/bin/apache_token_authorization.sh
It seems that apache runs the RewriteMap prgs as root:
[root@webserver ~]# ps -ef|grep 8915
root 8915 1 0 17:42 ? 00:00:00 /usr/sbin/httpd
root 8917 8915 0 17:42 ? 00:00:00 /bin/sh /my-app/bin/apache_token_authorization.sh
apache 8918 8915 0 17:42 ? 00:00:00 userservices
apache 8919 8915 0 17:42 ? 00:00:00 /usr/sbin/httpd
apache 8920 8915 0 17:42 ? 00:00:00 /usr/sbin/httpd
apache 8921 8915 0 17:42 ? 00:00:00 /usr/sbin/httpd
apache 8922 8915 0 17:42 ? 00:00:00 /usr/sbin/httpd
Is it possible to run these scripts with normal user?
Environment
- Red Hat Enterprise Linux 6
- Apache 2
- RewriteMap program config option
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.