[Bug 206740] There is no check for iconv* functions in the dynamically loaded libiconv library

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Jan 29 17:42:10 UTC 2016


            Bug ID: 206740
           Summary: There is no check for iconv* functions in the
                    dynamically loaded libiconv library
           Product: Base System
           Version: 9.3-STABLE
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: fbsd at any.com.ru

Created attachment 166274
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=166274&action=edit
fixup using iconv* functions from library loaded by dlopen.

When the world is compiled without iconv support in libc, some code in the base
system tries to use the iconv* functions from the external library (usually
converters/libiconv port). For now, the code in libkiconv and libsmb doesn't
check the presence of iconv* functions in the loaded library. Starting with
libiconv-1.14_9 iconv* rymbols are not exported from libiconv.so. As a result,
there is a segmentation faults in the code that uses libkiconv and libsmb.

A set of patches for libkiconv, libsmb and csh fixes some issues when use
iconv* functions from libiconv loaded by dlopen(3):
1. allows to load alternative libiconv library using LIBICONV environment
2. tries fallback to iconv_open, iconv and iconv_close functions when
libiconv_open, libiconv and libiconv_close symbols are not exported from loaded
3. an error will be returned when any functions are missing in the library.

This should fix at least
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=205256 and segfaults in

You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-bugs mailing list