Lines Matching refs:rule

90 static void create_rule_attrs(struct sysdb_attrs *rule, int i)
94 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_CN,
98 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_HOST,
102 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_RUNASUSER,
106 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_USER,
111 static void create_rule_attrs_multiple_sudoUser(struct sysdb_attrs *rule)
115 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_CN,
119 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_HOST,
123 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_RUNASUSER,
128 ret = sysdb_attrs_add_string_safe(rule, SYSDB_SUDO_CACHE_AT_USER,
249 struct sysdb_attrs *rule;
253 rule = sysdb_new_attrs(test_ctx);
254 assert_non_null(rule);
255 create_rule_attrs(rule, 0);
257 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
288 talloc_zfree(rule);
304 struct sysdb_attrs *rule;
309 rule = sysdb_new_attrs(test_ctx);
310 assert_non_null(rule);
311 create_rule_attrs_multiple_sudoUser(rule);
315 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
361 talloc_zfree(rule);
377 struct sysdb_attrs *rule;
382 rule = sysdb_new_attrs(test_ctx);
383 assert_non_null(rule);
384 create_rule_attrs_multiple_sudoUser(rule);
388 ret = sysdb_attrs_add_lower_case_string(rule, false,
393 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
430 talloc_zfree(rule);
438 struct sysdb_attrs *rule;
443 rule = sysdb_new_attrs(test_ctx);
444 assert_non_null(rule);
445 create_rule_attrs(rule, 0);
447 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
458 talloc_zfree(rule);
465 struct sysdb_attrs *rule;
469 rule = sysdb_new_attrs(test_ctx);
470 assert_non_null(rule);
471 create_rule_attrs(rule, 0);
473 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
477 ret = sysdb_sudo_purge(test_ctx->tctx->dom, NULL, &rule, 1);
481 talloc_zfree(rule);
650 struct sysdb_attrs *rule;
661 rule = sysdb_new_attrs(test_ctx);
662 assert_non_null(rule);
663 create_rule_attrs(rule, 0);
665 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
696 talloc_zfree(rule);
705 struct sysdb_attrs *rule;
715 rule = sysdb_new_attrs(test_ctx);
716 assert_non_null(rule);
717 create_rule_attrs(rule, 0);
719 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
748 talloc_zfree(rule);
757 struct sysdb_attrs *rule;
768 rule = sysdb_new_attrs(test_ctx);
769 assert_non_null(rule);
770 create_rule_attrs(rule, 0);
772 ret = sysdb_sudo_store(test_ctx->tctx->dom, &rule, 1);
803 talloc_zfree(rule);