|
|
b2d430 |
From 2e027e43f0adb1b7c80e51d5613fca5a497ca331 Mon Sep 17 00:00:00 2001
|
|
|
b2d430 |
From: Jakub Hrozek <jhrozek@redhat.com>
|
|
|
b2d430 |
Date: Wed, 3 Aug 2016 18:03:59 +0200
|
|
|
b2d430 |
Subject: [PATCH 76/82] IPA: Check the return value of
|
|
|
b2d430 |
sss_parse_internal_fqname
|
|
|
b2d430 |
MIME-Version: 1.0
|
|
|
b2d430 |
Content-Type: text/plain; charset=UTF-8
|
|
|
b2d430 |
Content-Transfer-Encoding: 8bit
|
|
|
b2d430 |
|
|
|
b2d430 |
We should fail the request if sss_parse_internal_fqname() fails.
|
|
|
b2d430 |
|
|
|
b2d430 |
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
|
|
|
b2d430 |
---
|
|
|
b2d430 |
src/providers/ipa/ipa_subdomains_id.c | 8 ++++++++
|
|
|
b2d430 |
1 file changed, 8 insertions(+)
|
|
|
b2d430 |
|
|
|
b2d430 |
diff --git a/src/providers/ipa/ipa_subdomains_id.c b/src/providers/ipa/ipa_subdomains_id.c
|
|
|
b2d430 |
index 002857699b65c86a6ed0c912a2a7ae06a8f9e507..2299523d0c52e3277db6d1061c79b320e78c8f72 100644
|
|
|
b2d430 |
--- a/src/providers/ipa/ipa_subdomains_id.c
|
|
|
b2d430 |
+++ b/src/providers/ipa/ipa_subdomains_id.c
|
|
|
b2d430 |
@@ -509,6 +509,14 @@ static void ipa_get_subdom_acct_connected(struct tevent_req *subreq)
|
|
|
b2d430 |
} else {
|
|
|
b2d430 |
ret = sss_parse_internal_fqname(req_input, state->filter,
|
|
|
b2d430 |
&shortname, NULL);
|
|
|
b2d430 |
+ if (ret != EOK) {
|
|
|
b2d430 |
+ DEBUG(SSSDBG_CRIT_FAILURE,
|
|
|
b2d430 |
+ "Cannot parse internal name [%s]: %d\n",
|
|
|
b2d430 |
+ state->filter, ret);
|
|
|
b2d430 |
+ tevent_req_error(req, ret);
|
|
|
b2d430 |
+ return;
|
|
|
b2d430 |
+ }
|
|
|
b2d430 |
+
|
|
|
b2d430 |
req_input->inp.name = talloc_steal(req_input, shortname);
|
|
|
b2d430 |
}
|
|
|
b2d430 |
if (req_input->inp.name == NULL) {
|
|
|
b2d430 |
--
|
|
|
b2d430 |
2.4.11
|
|
|
b2d430 |
|