diff options
author | Stef Walter <stefw@redhat.com> | 2014-01-07 14:49:01 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2014-01-12 15:24:26 +0100 |
commit | c86904baad32fbf9e66bf1cdc667aa5e683b48ba (patch) | |
tree | f2582020bb75518f4f18942f0e555b2848eb1dd6 /src/tests/safe-format-tests.c | |
parent | b9d8c6172e48a2633ebe196b2e88bebdf9523c20 (diff) | |
download | sssd-c86904baad32fbf9e66bf1cdc667aa5e683b48ba.tar.gz sssd-c86904baad32fbf9e66bf1cdc667aa5e683b48ba.tar.xz sssd-c86904baad32fbf9e66bf1cdc667aa5e683b48ba.zip |
NSS: Don't use printf(3) on user provided strings.
This also fixes several corner cases and crashers.
It's not prudent to pass user input to (even admin) input as a
format string to printf, and various distros now check for this.
This can cause accessing memory incorrectly, and various also
various libc abort()'s.
In addition various assumptions were made about full_name_format
that aren't necessarily the case if the user uses a more complex
format.
Use safe-printf.c implementation for formatting full_name_format.
Adapt the NSS resolver so it doesn't barf on formatted strings that
are shorter than expected given a full_name_format.
Tests added and updated appropriately.
Diffstat (limited to 'src/tests/safe-format-tests.c')
0 files changed, 0 insertions, 0 deletions