ericbrunson
Technical User
An earlier post about security prompted me to ask this, I'm kind of in a quandry.
Running PHP as a module of Apache basically gives anyone with a little know-how access to any file that is readable by the web server process. Currently, I store config files with database username/passwords on the filesystem, but out of the document directories. But, if I had ftp access to a customer's account I could (and 90% of the readers of this forum could) write a simple PHP that would let me snoop the filesystem, and if I found those credentials I could acceess that customer's database freely.
It isn't currently a pressing matter, since none of our customers actually do their own PHP development. But that may not always be the case, and I have a client that wants me to start storing credit card information for people who shop on his site, and I'm *very* reluctant.
Is this a problem that has been resolved? I've considered encrypting the creds and prompting for a password at startup. That's kind of a hassle, but the best solution I've come up with the foil the average script kiddie. Other than that, I've considered SELinux and running PHP as a CGI (SELinux can only do a role-change during context switch).
Your thoughts are appreciated.
Running PHP as a module of Apache basically gives anyone with a little know-how access to any file that is readable by the web server process. Currently, I store config files with database username/passwords on the filesystem, but out of the document directories. But, if I had ftp access to a customer's account I could (and 90% of the readers of this forum could) write a simple PHP that would let me snoop the filesystem, and if I found those credentials I could acceess that customer's database freely.
It isn't currently a pressing matter, since none of our customers actually do their own PHP development. But that may not always be the case, and I have a client that wants me to start storing credit card information for people who shop on his site, and I'm *very* reluctant.
Is this a problem that has been resolved? I've considered encrypting the creds and prompting for a password at startup. That's kind of a hassle, but the best solution I've come up with the foil the average script kiddie. Other than that, I've considered SELinux and running PHP as a CGI (SELinux can only do a role-change during context switch).
Your thoughts are appreciated.