亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? services.c

?? xen虛擬機源代碼安裝包
?? C
?? 第 1 頁 / 共 3 頁
字號:
        context_struct_to_string(context, &s, &len);        printk(KERN_ERR "security:  context %s is invalid\n", s);        xfree(s);    }    return rc;}struct convert_context_args {    struct policydb *oldp;    struct policydb *newp;};/* * Convert the values in the security context * structure `c' from the values specified * in the policy `p->oldp' to the values specified * in the policy `p->newp'.  Verify that the * context is valid under the new policy. */static int convert_context(u32 key, struct context *c, void *p){    struct convert_context_args *args;    struct context oldc;    struct role_datum *role;    struct type_datum *typdatum;    struct user_datum *usrdatum;    char *s;    u32 len;    int rc;    args = p;    rc = context_cpy(&oldc, c);    if ( rc )        goto out;    rc = -EINVAL;    /* Convert the user. */    usrdatum = hashtab_search(args->newp->p_users.table,                              args->oldp->p_user_val_to_name[c->user - 1]);    if ( !usrdatum )        goto bad;    c->user = usrdatum->value;    /* Convert the role. */    role = hashtab_search(args->newp->p_roles.table,                          args->oldp->p_role_val_to_name[c->role - 1]);    if ( !role )        goto bad;    c->role = role->value;    /* Convert the type. */    typdatum = hashtab_search(args->newp->p_types.table,                              args->oldp->p_type_val_to_name[c->type - 1]);    if ( !typdatum )        goto bad;    c->type = typdatum->value;    rc = mls_convert_context(args->oldp, args->newp, c);    if ( rc )        goto bad;    /* Check the validity of the new context. */    if ( !policydb_context_isvalid(args->newp, c) )    {        rc = convert_context_handle_invalid_context(&oldc);        if ( rc )            goto bad;    }    context_destroy(&oldc);out:    return rc;bad:    context_struct_to_string(&oldc, &s, &len);    context_destroy(&oldc);    printk(KERN_ERR "security:  invalidating context %s\n", s);    xfree(s);    goto out;}extern void flask_complete_init(void);/** * security_load_policy - Load a security policy configuration. * @data: binary policy data * @len: length of data in bytes * * Load a new set of security policy configuration data, * validate it and convert the SID table as necessary. * This function will flush the access vector cache after * loading the new policy. */int security_load_policy(void *data, size_t len){    struct policydb oldpolicydb, newpolicydb;    struct sidtab oldsidtab, newsidtab;    struct convert_context_args args;    u32 seqno;    int rc = 0;    struct policy_file file = { data, len }, *fp = &file;    LOAD_LOCK;    if ( !ss_initialized )    {        if ( policydb_read(&policydb, fp) )        {            LOAD_UNLOCK;            return -EINVAL;        }        if ( policydb_load_isids(&policydb, &sidtab) )        {            LOAD_UNLOCK;            policydb_destroy(&policydb);            return -EINVAL;        }        policydb_loaded_version = policydb.policyvers;        ss_initialized = 1;        seqno = ++latest_granting;        LOAD_UNLOCK;        avc_ss_reset(seqno);        return 0;    }#if 0    sidtab_hash_eval(&sidtab, "sids");#endif    if ( policydb_read(&newpolicydb, fp) )    {        LOAD_UNLOCK;        return -EINVAL;    }    sidtab_init(&newsidtab);    /* Verify that the existing classes did not change. */    if ( hashtab_map(policydb.p_classes.table, validate_class, &newpolicydb) )    {        printk(KERN_ERR "security:  the definition of an existing "                                                            "class changed\n");        rc = -EINVAL;        goto err;    }    /* Clone the SID table. */    sidtab_shutdown(&sidtab);    if ( sidtab_map(&sidtab, clone_sid, &newsidtab) )    {        rc = -ENOMEM;        goto err;    }    /* Convert the internal representations of contexts       in the new SID table and remove invalid SIDs. */    args.oldp = &policydb;    args.newp = &newpolicydb;    sidtab_map_remove_on_error(&newsidtab, convert_context, &args);    /* Save the old policydb and SID table to free later. */    memcpy(&oldpolicydb, &policydb, sizeof policydb);    sidtab_set(&oldsidtab, &sidtab);    /* Install the new policydb and SID table. */    POLICY_WRLOCK;    memcpy(&policydb, &newpolicydb, sizeof policydb);    sidtab_set(&sidtab, &newsidtab);    seqno = ++latest_granting;    policydb_loaded_version = policydb.policyvers;    POLICY_WRUNLOCK;    LOAD_UNLOCK;    /* Free the old policydb and SID table. */    policydb_destroy(&oldpolicydb);    sidtab_destroy(&oldsidtab);    avc_ss_reset(seqno);    return 0;err:    LOAD_UNLOCK;    sidtab_destroy(&newsidtab);    policydb_destroy(&newpolicydb);    return rc;}/** * security_pirq_sid - Obtain the SID for a physical irq. * @pirq: physical irq * @out_sid: security identifier */int security_pirq_sid(int pirq, u32 *out_sid){    int rc = 0;    struct ocontext *c;    POLICY_RDLOCK;    c = policydb.ocontexts[OCON_PIRQ];        while ( c )    {        if ( c->u.pirq == pirq )            break;        c = c->next;    }    if ( c )    {        if ( !c->sid[0] )        {            rc = sidtab_context_to_sid(&sidtab, &c->context[0], &c->sid[0]);            if ( rc )                goto out;        }        *out_sid = c->sid[0];    }    else    {        *out_sid = SECINITSID_PIRQ;    }out:    POLICY_RDUNLOCK;    return rc;}/** * security_iomem_sid - Obtain the SID for a page of iomem. * @mfn: iomem mfn * @out_sid: security identifier */int security_iomem_sid(unsigned long mfn, u32 *out_sid){    struct ocontext *c;    int rc = 0;    POLICY_RDLOCK;    c = policydb.ocontexts[OCON_IOMEM];    while ( c )    {        if ( c->u.iomem == mfn )            break;        c = c->next;    }    if ( c )    {        if ( !c->sid[0] )        {            rc = sidtab_context_to_sid(&sidtab, &c->context[0], &c->sid[0]);            if ( rc )                goto out;        }        *out_sid = c->sid[0];    }    else    {        *out_sid = SECINITSID_IOMEM;    }out:    POLICY_RDUNLOCK;    return rc;}/** * security_ioport_sid - Obtain the SID for an ioport. * @ioport: ioport * @out_sid: security identifier */int security_ioport_sid(u32 ioport, u32 *out_sid){    struct ocontext *c;    int rc = 0;    POLICY_RDLOCK;    c = policydb.ocontexts[OCON_IOPORT];    while ( c )    {        if ( c->u.ioport == ioport )            break;        c = c->next;    }    if ( c )    {        if ( !c->sid[0] )        {            rc = sidtab_context_to_sid(&sidtab, &c->context[0], &c->sid[0]);            if ( rc )                goto out;        }        *out_sid = c->sid[0];    }    else    {        *out_sid = SECINITSID_IOPORT;    }out:    POLICY_RDUNLOCK;    return rc;}#define SIDS_NEL 25/** * security_get_user_sids - Obtain reachable SIDs for a user. * @fromsid: starting SID * @username: username * @sids: array of reachable SIDs for user * @nel: number of elements in @sids * * Generate the set of SIDs for legal security contexts * for a given user that can be reached by @fromsid. * Set *@sids to point to a dynamically allocated * array containing the set of SIDs.  Set *@nel to the * number of elements in the array. */int security_get_user_sids(u32 fromsid, char *username, u32 **sids, u32 *nel){    struct context *fromcon, usercon;    u32 *mysids, *mysids2, sid;    u32 mynel = 0, maxnel = SIDS_NEL;    struct user_datum *user;    struct role_datum *role;    struct av_decision avd;    struct ebitmap_node *rnode, *tnode;    int rc = 0, i, j;    if ( !ss_initialized )    {        *sids = NULL;        *nel = 0;        goto out;    }    POLICY_RDLOCK;    fromcon = sidtab_search(&sidtab, fromsid);    if ( !fromcon )    {        rc = -EINVAL;        goto out_unlock;    }    user = hashtab_search(policydb.p_users.table, username);    if ( !user )    {        rc = -EINVAL;        goto out_unlock;    }    usercon.user = user->value;    mysids = xmalloc_array(u32, maxnel);    if ( !mysids )    {        rc = -ENOMEM;        goto out_unlock;    }    memset(mysids, 0, maxnel*sizeof(*mysids));    ebitmap_for_each_bit(&user->roles, rnode, i)    {        if ( !ebitmap_node_get_bit(rnode, i) )            continue;        role = policydb.role_val_to_struct[i];        usercon.role = i+1;        ebitmap_for_each_bit(&role->types, tnode, j) {            if ( !ebitmap_node_get_bit(tnode, j) )                continue;            usercon.type = j+1;            if ( mls_setup_user_range(fromcon, user, &usercon) )                continue;            rc = context_struct_compute_av(fromcon, &usercon,                               SECCLASS_DOMAIN,                               DOMAIN__TRANSITION,                               &avd);            if ( rc ||  !(avd.allowed & DOMAIN__TRANSITION) )                continue;            rc = sidtab_context_to_sid(&sidtab, &usercon, &sid);            if ( rc )            {                xfree(mysids);                goto out_unlock;            }            if ( mynel < maxnel )            {                mysids[mynel++] = sid;            }            else            {                maxnel += SIDS_NEL;                mysids2 = xmalloc_array(u32, maxnel);                if ( !mysids2 )                {                    rc = -ENOMEM;                    xfree(mysids);                    goto out_unlock;                }                memset(mysids2, 0, maxnel*sizeof(*mysids2));                memcpy(mysids2, mysids, mynel * sizeof(*mysids2));                xfree(mysids);                mysids = mysids2;                mysids[mynel++] = sid;            }        }    }    *sids = mysids;    *nel = mynel;out_unlock:    POLICY_RDUNLOCK;out:    return rc;}int security_get_bools(int *len, char ***names, int **values){    int i, rc = -ENOMEM;    POLICY_RDLOCK;    *names = NULL;    *values = NULL;    *len = policydb.p_bools.nprim;    if ( !*len )    {        rc = 0;        goto out;    }    *names = (char**)xmalloc_array(char*, *len);    if ( !*names )        goto err;    memset(*names, 0, sizeof(char*) * *len);    *values = (int*)xmalloc_array(int, *len);    if ( !*values )        goto err;    for ( i = 0; i < *len; i++ )    {        size_t name_len;        (*values)[i] = policydb.bool_val_to_struct[i]->state;        name_len = strlen(policydb.p_bool_val_to_name[i]) + 1;        (*names)[i] = (char*)xmalloc_array(char, name_len);        if ( !(*names)[i] )            goto err;        strlcpy((*names)[i], policydb.p_bool_val_to_name[i], name_len);        (*names)[i][name_len - 1] = 0;    }    rc = 0;out:    POLICY_RDUNLOCK;    return rc;err:    if ( *names )    {        for ( i = 0; i < *len; i++ )            xfree((*names)[i]);    }    xfree(*values);    goto out;}int security_set_bools(int len, int *values){    int i, rc = 0;    int lenp, seqno = 0;    struct cond_node *cur;    POLICY_WRLOCK;    lenp = policydb.p_bools.nprim;    if ( len != lenp )    {        rc = -EFAULT;        goto out;    }    printk(KERN_INFO "security: committed booleans { ");    for ( i = 0; i < len; i++ )    {        if ( values[i] )        {            policydb.bool_val_to_struct[i]->state = 1;        }        else        {            policydb.bool_val_to_struct[i]->state = 0;        }        if ( i != 0 )            printk(", ");        printk("%s:%d", policydb.p_bool_val_to_name[i],               policydb.bool_val_to_struct[i]->state);    }    printk(" }\n");    for ( cur = policydb.cond_list; cur != NULL; cur = cur->next )    {        rc = evaluate_cond_node(&policydb, cur);        if ( rc )            goto out;    }    seqno = ++latest_granting;out:    POLICY_WRUNLOCK;    if ( !rc )    {        avc_ss_reset(seqno);    }    return rc;}int security_get_bool_value(int bool){    int rc = 0;    int len;    POLICY_RDLOCK;    len = policydb.p_bools.nprim;    if ( bool >= len )    {        rc = -EFAULT;        goto out;    }    rc = policydb.bool_val_to_struct[bool]->state;out:    POLICY_RDUNLOCK;    return rc;}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品一区二区三区乱码| 亚洲福利视频一区二区| 日韩欧美不卡在线观看视频| 制服.丝袜.亚洲.中文.综合| 欧美在线|欧美| 欧美午夜不卡在线观看免费| 欧美午夜精品久久久久久超碰| 欧洲亚洲国产日韩| 精品视频在线免费| 欧美日韩国产美| 日韩视频123| 久久老女人爱爱| 国产亚洲成aⅴ人片在线观看| 精品国产区一区| 国产女人18毛片水真多成人如厕| 亚洲天堂久久久久久久| 亚洲国产精品麻豆| 美女网站色91| 国产+成+人+亚洲欧洲自线| 91在线免费视频观看| 欧美日韩第一区日日骚| 精品毛片乱码1区2区3区| 欧美激情一区三区| 一区二区三区日韩| 日韩激情一区二区| 成人综合婷婷国产精品久久 | 一本色道久久加勒比精品| 色综合久久综合| 欧美一级二级三级乱码| 中文在线资源观看网站视频免费不卡 | 一区二区日韩av| 男女性色大片免费观看一区二区| 国产麻豆欧美日韩一区| 一本色道久久综合亚洲aⅴ蜜桃| 7777精品伊人久久久大香线蕉 | 亚洲免费视频成人| 青青草原综合久久大伊人精品优势| 国产伦精品一区二区三区视频青涩 | 欧美一级片在线看| 中文字幕免费观看一区| 三级欧美在线一区| 99久久精品情趣| 亚洲精品一区二区在线观看| 一区二区三区欧美日| 免费成人你懂的| 色婷婷综合久色| 国产欧美日韩视频一区二区| 日日摸夜夜添夜夜添国产精品| 成人精品一区二区三区中文字幕| 欧美福利电影网| 亚洲乱码中文字幕| 成人手机在线视频| 欧美电视剧免费全集观看| 亚洲自拍偷拍欧美| yourporn久久国产精品| 久久久亚洲国产美女国产盗摄| 天天爽夜夜爽夜夜爽精品视频| 99久久99久久精品免费看蜜桃 | 久久精品亚洲精品国产欧美| 日韩主播视频在线| av中文字幕不卡| 国产欧美一区二区精品忘忧草| 日本成人在线网站| 欧美群妇大交群的观看方式| 亚洲女女做受ⅹxx高潮| 99久久精品99国产精品| 国产精品久久久久毛片软件| 国产丶欧美丶日本不卡视频| 久久亚洲精精品中文字幕早川悠里 | 中文字幕一区日韩精品欧美| 国产精品91xxx| 国产无一区二区| 国产不卡视频在线观看| 国产嫩草影院久久久久| 国产精品1024| 国产日韩欧美精品电影三级在线 | 中文字幕乱码亚洲精品一区| 国产精品性做久久久久久| 久久夜色精品国产欧美乱极品| 美国十次了思思久久精品导航| 91精品国产色综合久久久蜜香臀| 丝袜诱惑亚洲看片| 欧美一级理论片| 欧美午夜免费电影| 亚洲精品视频观看| 91麻豆精东视频| 亚洲国产成人91porn| 欧美日本一区二区| 秋霞午夜av一区二区三区| 欧美一卡二卡三卡四卡| 国内精品久久久久影院薰衣草| 久久综合给合久久狠狠狠97色69| 国产99精品国产| 亚洲三级久久久| 欧美日韩美少妇| 国产一区二区三区不卡在线观看| 久久久久久夜精品精品免费| av毛片久久久久**hd| 亚洲第一在线综合网站| 精品卡一卡二卡三卡四在线| 成人av在线播放网站| 亚洲精品成人悠悠色影视| 欧美精品777| 成人午夜激情影院| 亚洲二区视频在线| 久久久国产一区二区三区四区小说| 成人动漫中文字幕| 三级欧美韩日大片在线看| 中文字幕av资源一区| 精品视频在线视频| 成人av影视在线观看| 午夜视频一区在线观看| 国产无遮挡一区二区三区毛片日本| 日本电影欧美片| 国产成人在线视频网站| 亚洲国产精品一区二区www| 337p日本欧洲亚洲大胆精品| 日本韩国欧美在线| 国产成人亚洲综合a∨猫咪| 亚洲大片精品永久免费| 中文字幕不卡在线| 精品日本一线二线三线不卡| 欧美性色黄大片手机版| 东方欧美亚洲色图在线| 蜜桃视频在线一区| 亚洲一区在线观看免费| 国产精品毛片无遮挡高清| 欧美成人精品高清在线播放| 欧美美女喷水视频| 91丨九色丨蝌蚪丨老版| 国产成人在线影院| 精品一区二区在线视频| 婷婷六月综合网| 一区二区成人在线观看| 国产精品无圣光一区二区| 精品国产乱码91久久久久久网站| 欧美日韩国产精选| 在线亚洲高清视频| 91浏览器打开| 91麻豆国产在线观看| 高清不卡在线观看| 国产精品一区不卡| 国产美女一区二区三区| 黄色日韩三级电影| 韩国一区二区三区| 狠狠色丁香久久婷婷综合丁香| 日本亚洲欧美天堂免费| 亚洲www啪成人一区二区麻豆| 亚洲综合久久久久| 亚洲成av人在线观看| 亚洲成人免费在线| 亚洲午夜久久久久| 亚洲mv大片欧洲mv大片精品| 亚洲成a人v欧美综合天堂下载| 亚洲图片欧美色图| 午夜不卡在线视频| 免费高清在线一区| 国产米奇在线777精品观看| 国产乱国产乱300精品| 国产成人免费高清| 99综合影院在线| 在线区一区二视频| 7777精品久久久大香线蕉| 欧美一区二区观看视频| 亚洲精品一区在线观看| 国产精品国产三级国产aⅴ中文| 亚洲日本在线视频观看| 一区二区三区产品免费精品久久75| 一区二区三区高清不卡| 日本中文在线一区| 国产一区二区精品在线观看| av毛片久久久久**hd| 欧美精品自拍偷拍动漫精品| 欧美电视剧在线观看完整版| 亚洲国产精品精华液ab| 成人激情图片网| 欧美在线免费视屏| 日韩欧美在线网站| 国产精品欧美一区喷水| 亚洲午夜久久久| 国产一区二区三区美女| 色综合视频在线观看| 日韩欧美在线影院| 亚洲女人的天堂| 乱中年女人伦av一区二区| 成人白浆超碰人人人人| 欧美日韩不卡视频| 日本一区二区视频在线| 亚洲一区二区视频在线观看| 久久精品国产999大香线蕉| 91网上在线视频| 精品福利av导航| 亚洲国产一区二区在线播放| 韩国欧美国产1区| 欧美综合亚洲图片综合区| 久久久99久久| 丝袜美腿高跟呻吟高潮一区| 成人av电影在线观看| 精品久久久久久久久久久久久久久 | 一区二区三区不卡视频|