From 0df000749a3b9423b72f5338630c3092e2cf74be Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michal=20=C5=BDidek?= <mzidek@redhat.com>
Date: Fri, 1 Jul 2016 09:58:41 +0200
Subject: [PATCH] config: Fix filename matching regex

Configuration file snippets must end with suffix
.conf. We wrongly allowed any suffixes that begin
with .conf (for example .conf.back).
---
 src/util/sss_ini.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/sss_ini.c b/src/util/sss_ini.c
index b4dbb07..4438f8c 100644
--- a/src/util/sss_ini.c
+++ b/src/util/sss_ini.c
@@ -211,7 +211,7 @@ int sss_ini_get_config(struct sss_ini_initdata *init_data,
     int ret;
 #ifdef HAVE_LIBINI_CONFIG_V1
 #ifdef HAVE_LIBINI_CONFIG_V1_3
-    const char *patterns[] = { "^[^\\.].*\\.conf", NULL };
+    const char *patterns[] = { "^[^\\.].*\\.conf$", NULL };
     const char *sections[] = { ".*", NULL };
     uint32_t i = 0;
     char *msg = NULL;
-- 
2.5.0

