Hi Joshua,
Yes. I did use the libselinux API:
@@ -243,16 +408,18 @@ static void rollback(SELboolean * boollist, int end)
}
int security_set_boolean_list(size_t boolcnt, SELboolean * boollist,
- int permanent __attribute__((unused)))
+ int permanent )
{
Please see the bitbucket pull request link:
https://bitbucket.org/seandroid/external-libselinux/pull-request/6/permanent-sebooleans-feature/diff
Thanks,
Haiqing
On Wed, Dec 11, 2013 at 6:02 PM, Joshua Brindle
<[email protected]>wrote:
> On Wed, Dec 11, 2013 at 8:39 PM, Haiqing Jiang <[email protected]>
> wrote:
> > ---
> > include/selinux/selinux.h | 6 ++
> > src/android.c | 4 +
> > src/booleans.c | 183
> +++++++++++++++++++++++++++++++++++++++++++--
> > src/selinux_internal.h | 2 +
> > 4 files changed, 187 insertions(+), 8 deletions(-)
> >
> > diff --git a/include/selinux/selinux.h b/include/selinux/selinux.h
> > index c7c2571..c8690f4 100644
> > --- a/include/selinux/selinux.h
> > +++ b/include/selinux/selinux.h
> > @@ -244,6 +244,12 @@ extern int security_get_boolean_active(const char
> *name);
> > /* Set the pending value for the boolean */
> > extern int security_set_boolean(const char *name, int value);
> >
> > +/* Set the pending value for the permanent boolean */
> > +extern int security_set_permanent_boolean(const char *name, int value);
>
> Is there a good reason not to use the upstream libselinux API?
>
> extern int security_set_boolean_list(size_t boolcnt, SELboolean *
> boollist, int permanent);
>
--
Thanks,
Haiqing Jiang