Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-11-07 Thread Matt Riedemann
On 10/27/2017 1:23 PM, Matt Riedemann wrote: Nova has had this long-standing known performance issue if you're filtering a large number of instances by IP. The instance IPs are stored in a JSON blob in the database so we don't do filtering in SQL. We pull the instances out of the database,

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-11-02 Thread Alex Xu
FYI, Nova did use regex https://github.com/openstack/nova/blob/master/nova/db/sqlalchemy/api.py#L2408 2017-10-27 11:35 GMT+08:00 Matt Riedemann : > On 10/26/2017 9:54 PM, Tony Breeds wrote: > >> Can you use RLIKE/REGEX? or is that too MySQL specific ? >> > > I thought about

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-28 Thread Joshua Harlow
Matt Riedemann wrote: On 10/26/2017 10:56 PM, Joshua Harlow wrote: Just the paranoid person in me, but is it safe to say that the filter that you are showing here does not come from user text? Ie these two lines don't come from a user input directly (without going through some filter) do they?

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-27 Thread Matt Riedemann
On 10/26/2017 10:56 PM, Joshua Harlow wrote: Just the paranoid person in me, but is it safe to say that the filter that you are showing here does not come from user text? Ie these two lines don't come from a user input directly (without going through some filter) do they?

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-27 Thread Jeremy Stanley
On 2017-10-27 14:26:06 -0400 (-0400), Mohammed Naser wrote: [...] > in our experience, malicious VMs are not short lived but they are > long lived. We'll generally find them running before we received > the report which means that the abuse report came for that user > indeed. [...] I guess the

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-27 Thread Mohammed Naser
On Fri, Oct 27, 2017 at 12:48 PM, Jeremy Stanley wrote: > On 2017-10-26 22:26:59 -0400 (-0400), Mohammed Naser wrote: > [...] > > The use-case for us is that it helps us easily identify or find VMs which > > we get any abuse reports for (or anything we see malicious traffic

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Joshua Harlow
Just the paranoid person in me, but is it safe to say that the filter that you are showing here does not come from user text? Ie these two lines don't come from a user input directly (without going through some filter) do they?

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Tony Breeds
On Thu, Oct 26, 2017 at 10:35:47PM -0500, Matt Riedemann wrote: > On 10/26/2017 9:54 PM, Tony Breeds wrote: > > Can you use RLIKE/REGEX? or is that too MySQL specific ? > > I thought about that, and my gut response is 'no' because even if it does > work for mysql, I'm assuming regex pattern

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Matt Riedemann
On 10/26/2017 9:54 PM, Tony Breeds wrote: Can you use RLIKE/REGEX? or is that too MySQL specific ? I thought about that, and my gut response is 'no' because even if it does work for mysql, I'm assuming regex pattern matching for postgresql is different. And then you have different API

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Tony Breeds
On Thu, Oct 26, 2017 at 09:23:50PM -0500, Matt Riedemann wrote: > Nova has had this long-standing known performance issue if you're filtering > a large number of instances by IP. The instance IPs are stored in a JSON > blob in the database so we don't do filtering in SQL. We pull the instances >

Re: [openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Mohammed Naser
On Thu, Oct 26, 2017 at 10:23 PM, Matt Riedemann wrote: > Nova has had this long-standing known performance issue if you're > filtering a large number of instances by IP. The instance IPs are stored in > a JSON blob in the database so we don't do filtering in SQL. We pull

[openstack-dev] [nova][neutron] How do you use the instance IP filter?

2017-10-26 Thread Matt Riedemann
Nova has had this long-standing known performance issue if you're filtering a large number of instances by IP. The instance IPs are stored in a JSON blob in the database so we don't do filtering in SQL. We pull the instances out of the database, deserialize the JSON and then apply a regex