From b096321a5a02dda0b6b71ba0f9c4d8feacd979e4 Mon Sep 17 00:00:00 2001 From: Michal Zidek Date: Wed, 22 Aug 2012 15:16:26 +0200 Subject: Fix: IPv6 address with square brackets doesn't work. https://fedorahosted.org/sssd/ticket/1365 --- src/util/util.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/util/util.h') diff --git a/src/util/util.h b/src/util/util.h index 7ff91af5..685702fc 100644 --- a/src/util/util.h +++ b/src/util/util.h @@ -516,6 +516,15 @@ errno_t sss_filter_sanitize(TALLOC_CTX *mem_ctx, char * sss_escape_ip_address(TALLOC_CTX *mem_ctx, int family, const char *addr); +/* This function only removes first and last + * character if the first character was '['. + * + * NOTE: This means, that ipv6addr must NOT be followed + * by port number. + */ +errno_t +remove_ipv6_brackets(char *ipv6addr); + /* from sss_tc_utf8.c */ char * sss_tc_utf8_str_tolower(TALLOC_CTX *mem_ctx, const char *s); -- cgit