4.6 Reference Box: Decision Center

/* kernel/lids.c */
int lids_check_base(struct dentry *base, int flag)
{
......        
/* check if the dentry is in the domain */
        while(dentry) {
        .......
       }
/* check the ACL */
        while (dentry) {
                if((ino=dentry->d_inode)!=NULL)
                    if((retval=lids_search_inode(ino->i_ino,ino->i_dev,
                        &lids_data[lids_curr&1])) >= 0) {
                        return (retval & flag) ? 0:
                                lids_check_acl(base,flag,lids_curr,0);
                }
                if (dentry==dentry->d_parent)
                        return 0;
                dentry=dentry->d_parent;
        }
        return 0;
}