[libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Guannan Ren
If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file contexts database by matchpathcon_init() and free memory when finished using matchpathcon by matchpathcon_fini(). --- src/security/security_selinux.c | 8 1 file changed, 8

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Martin Kletzander
On 10/15/2012 09:12 AM, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file contexts database by matchpathcon_init() and free memory when finished using matchpathcon by matchpathcon_fini(). ---

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Daniel P. Berrange
On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file contexts database by matchpathcon_init() and free memory when finished using matchpathcon by matchpathcon_fini(). ---

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Martin Kletzander
On 10/15/2012 12:22 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file contexts database by matchpathcon_init() and free memory when finished using

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Daniel P. Berrange
On Mon, Oct 15, 2012 at 12:40:56PM +0200, Martin Kletzander wrote: On 10/15/2012 12:22 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Guannan Ren
On 10/15/2012 06:40 PM, Martin Kletzander wrote: On 10/15/2012 12:22 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific pathname, it'd better actively load file contexts database by

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Daniel P. Berrange
On Mon, Oct 15, 2012 at 07:03:07PM +0800, Guannan Ren wrote: On 10/15/2012 06:40 PM, Martin Kletzander wrote: On 10/15/2012 12:22 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use matchpathcon() to look up selinux context for specific

Re: [libvirt] [PATCH 1/2] selinux: load and free selinux active file contexts configuration database

2012-10-15 Thread Guannan Ren
On 10/15/2012 07:35 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 07:03:07PM +0800, Guannan Ren wrote: On 10/15/2012 06:40 PM, Martin Kletzander wrote: On 10/15/2012 12:22 PM, Daniel P. Berrange wrote: On Mon, Oct 15, 2012 at 03:12:45PM +0800, Guannan Ren wrote: If we use