Advice please: PHP.ini allow_url_fopen = On?

Advice please: PHP.ini allow_url_fopen = On?

Posted by: smx
Posted on: 2007-07-31 11:03:00

I want to read some public data directly from a data file online on another site and use it in a PHP custom application. However, the setting allow_url_fopen = Off in the default PHP.ini file prevents me from doing this. I could try and get around this by implementing a custom PHP.ini solution, but could someone advise me as to why this is set to Off in the default PHP.ini? In other words, is there a good reason why not to set this to On?
THanks
Roger

Re: Advice please: PHP.ini allow_url_fopen = On?

Posted by: scjessey
Posted on: 2007-07-31 11:19:00

Leaving allow_url_fopen set to "on" is a huge security risk. Please read this wiki article for a secure solution.

-- si-blog --

Re: Advice please: PHP.ini allow_url_fopen = On?

Posted by: smx
Posted on: 2007-07-31 12:37:00

Thanks for the advice, much appreciated!
I will implement the alternative solution instead.

Tags: fopenini file