Re: [PHP] Re: How to limit source IP in PHP

2012-09-18 Thread Tonix (Antonio Nati)
Il 18/09/2012 16:24, Daniel Brown ha scritto: On Tue, Sep 18, 2012 at 9:15 AM, Ian wrote: Hi Curtis, I am suffering from sleep deprivation due to a new family addition and I fail to see how your code will prevent a malicious user from binding to an IP that I do not want him to. It appears to

Re: [PHP] How to limit source IP in PHP

2012-09-14 Thread Tonix (Antonio Nati)
Il 14/09/2012 21:19, Jim Lucas ha scritto: On 09/13/2012 04:15 PM, Tonix (Antonio Nati) wrote: Jim, sorry but you did not read carefully my posts. Since the fist post, I ALWAYS spoke about connections a PHP script may open autonomously (what you name second connection). I'm never spe

Re: [PHP] How to limit source IP in PHP

2012-09-13 Thread Tonix (Antonio Nati)
Il 14/09/2012 00:09, Jim Lucas ha scritto: On 09/13/2012 12:55 PM, Tonix (Antonio Nati) wrote: Il 13/09/2012 21:41, Jim Lucas ha scritto: On 09/13/2012 12:28 PM, Tonix (Antonio Nati) wrote: You are speaking about incoming connections, I suppose. I'm speaking about connections started

Re: [PHP] How to limit source IP in PHP

2012-09-13 Thread Tonix (Antonio Nati)
Il 13/09/2012 21:41, Jim Lucas ha scritto: On 09/13/2012 12:28 PM, Tonix (Antonio Nati) wrote: You are speaking about incoming connections, I suppose. I'm speaking about connections started from within PHP. Which is a response to the incoming connection. And so? There is no rel

Re: [PHP] How to limit source IP in PHP

2012-09-13 Thread Tonix (Antonio Nati)
Il 13/09/2012 18:19, Mihamina Rakotomandimby ha scritto: On 09/12/2012 04:53 PM, Tonix (Antonio Nati) wrote: PHP script can freely choose which IP to bind. PHP doesnt bind at all. The HTTP server (Apache, Lighthttpd,...) does. PHP is called only when the HTTP server wants (you configure it

Re: [PHP] How to limit source IP in PHP

2012-09-13 Thread Tonix (Antonio Nati)
Il 13/09/2012 18:16, Mihamina Rakotomandimby ha scritto: On 09/12/2012 07:02 PM, Daniel Brown wrote: So, the answer is no, PHP is not able to do that. There is an (heavy) BASEDIR directive for disk, but nothing equivalent (and simpler) for IP. That's correct. However, that doesn't mean

Re: [PHP] How to limit source IP in PHP

2012-09-12 Thread Tonix (Antonio Nati)
Il 12/09/2012 17:52, Tommy Pham ha scritto: On Wed, Sep 12, 2012 at 7:18 AM, Tonix (Antonio Nati) wrote: Il 12/09/2012 16:08, Tommy Pham ha scritto: On Wed, Sep 12, 2012 at 6:53 AM, Tonix (Antonio Nati) wrote: Is there a way to force a PHP script to bind to a prefixed IP? Actually, while

Re: [PHP] How to limit source IP in PHP

2012-09-12 Thread Tonix (Antonio Nati)
Il 12/09/2012 17:21, Daniel Brown ha scritto: On Wed, Sep 12, 2012 at 10:18 AM, Tonix (Antonio Nati) wrote: Is PHP able to 'force' binding IP? I hoped there was an external directive I did not see, but probably this is a PHP lack. Not at all. Essentially, PHP is an in

Re: [PHP] How to limit source IP in PHP

2012-09-12 Thread Tonix (Antonio Nati)
Il 12/09/2012 16:08, Tommy Pham ha scritto: On Wed, Sep 12, 2012 at 6:53 AM, Tonix (Antonio Nati) wrote: Is there a way to force a PHP script to bind to a prefixed IP? Actually, while you can assign more IPs to Apache for listening, assigning domains to specific IPs, it looks like any PHP

[PHP] How to limit source IP in PHP

2012-09-12 Thread Tonix (Antonio Nati)
Is there a way to force a PHP script to bind to a prefixed IP? Actually, while you can assign more IPs to Apache for listening, assigning domains to specific IPs, it looks like any PHP script can freely choose which IP to bind. Instead I'd love some domains are permitted to open connections o