-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Fixes https://fedorahosted.org/sssd/ticket/233

The previous patch had the check in the wrong location. It needs to be
in confdb_get_domains() so it happens before the monitor daemonizes.
- -- 
Stephen Gallagher
RHCE 804006346421761

Delivering value year after year.
Red Hat ranks #1 in value among software vendors.
http://www.redhat.com/promo/vendor/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAksfsQIACgkQeiVVYja6o6Oe+gCfQcy9B5jCR9MU7E7hP7JZnlab
yjgAoKzYi7RoVXnYI9yLKOuSXogL1cC3
=Dh7u
-----END PGP SIGNATURE-----
From 1ca9b0f273b83798931a3fe71bee991e2398b811 Mon Sep 17 00:00:00 2001
From: Stephen Gallagher <[email protected]>
Date: Wed, 9 Dec 2009 09:13:24 -0500
Subject: [PATCH] Properly deny id_provider=files

---
 server/confdb/confdb.c   |    7 +++++++
 server/monitor/monitor.c |    6 ------
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/server/confdb/confdb.c b/server/confdb/confdb.c
index 07d776c..ad354e5 100644
--- a/server/confdb/confdb.c
+++ b/server/confdb/confdb.c
@@ -810,6 +810,13 @@ static int confdb_get_domain_internal(struct confdb_ctx *cdb,
         goto done;
     }
 
+    if (strcasecmp(domain->provider, "files") == 0) {
+        /* The files provider is not valid anymore */
+        DEBUG(0, ("The \"files\" provider is invalid\n"));
+        ret = EINVAL;
+        goto done;
+    }
+
     if (strcasecmp(domain->provider, "local") == 0) {
         /* If this is the local provider, we need to ensure that
          * no other provider was specified for other types, since
diff --git a/server/monitor/monitor.c b/server/monitor/monitor.c
index f5909f6..d47b3a8 100644
--- a/server/monitor/monitor.c
+++ b/server/monitor/monitor.c
@@ -1182,12 +1182,6 @@ static int add_new_provider(struct mt_ctx *ctx, const char *name)
         return ret;
     }
 
-    if (strcasecmp(svc->provider, "files") == 0) {
-        /* The files provider is not valid anymore */
-        DEBUG(0, ("The \"files\" provider is invalid\n"));
-        return EINVAL;
-    }
-
     if (strcasecmp(svc->provider, "local") == 0) {
         /* The LOCAL provider requires no back-end currently
          * We'll add it to the service list, but we don't need
-- 
1.6.5.2

Attachment: 0001-Properly-deny-id_provider-files.patch.sig
Description: PGP signature

_______________________________________________
sssd-devel mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/sssd-devel

Reply via email to