All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH libibverbs v2 00/11] make read_config() more robust
@ 2013-08-08 19:40 Yann Droneaud
       [not found] ` <cover.1375952089.git.ydroneaud-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 14+ messages in thread
From: Yann Droneaud @ 2013-08-08 19:40 UTC (permalink / raw)
  To: linux-rdma-u79uwXL29TY76Z2rM5mHXA; +Cc: Yann Droneaud

Hi,

Please find patches to protect libibverbs from using invalid,
unsecure configuration files.

Thoses configurations files are usually located in
/etc/libibverbs.d/ and contains the name of a shared library
to dlopen().

Only legitimate shared libraries should be loaded by libibverbs,
so it must be careful on the configuration files used.

Changes from v1:

- rewrote the way files are accessed to use openat()
- made the ownership/permissions checking allow access to user owned files.
- reject symlinks

Yann Droneaud (11):
  read_config(): ignore files beginning with '.'
  read_config(): ignore directory entry with backup suffix (~)
  read_config(): open configuration directory with open()
  read_config(): move file type check in read_config_file()
  read_config_file(): use the directory file descriptor to open
    configuration file
  read_config_file(): check opened file
  read_config(): check opened directory
  read_config(): refuse to open IBV_CONFIG_DIR if it's not a directory
  Check owner/permissions of config directory/files
  read_config(): reject symlinks
  read_config_file(): refuse to open configuration file if it's symlink

 configure.ac |  12 ++++++
 src/init.c   | 135 ++++++++++++++++++++++++++++++++++++++++++++++++-----------
 2 files changed, 123 insertions(+), 24 deletions(-)

-- 
1.8.3.1
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2013-08-12 19:29 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-08 19:40 [PATCH libibverbs v2 00/11] make read_config() more robust Yann Droneaud
     [not found] ` <cover.1375952089.git.ydroneaud-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>
2013-08-08 19:40   ` [PATCH libibverbs v2 01/11] read_config(): ignore files beginning with '.' Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 02/11] read_config(): ignore directory entry with backup suffix (~) Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 03/11] read_config(): open configuration directory with open() Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 04/11] read_config(): move file type check in read_config_file() Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 05/11] read_config_file(): use the directory file descriptor to open configuration file Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 06/11] read_config_file(): check opened file Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 07/11] read_config(): check opened directory Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 08/11] read_config(): refuse to open IBV_CONFIG_DIR if it's not a directory Yann Droneaud
     [not found]     ` <64fd9c35244a9d3ed56f77b049accb00b9ec95e9.1375952089.git.ydroneaud-RlY5vtjFyJ3QT0dZR+AlfA@public.gmane.org>
2013-08-12 19:29       ` Jason Gunthorpe
2013-08-08 19:40   ` [PATCH libibverbs v2 09/11] Check owner/permissions of config directory/files Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 10/11] read_config(): reject symlinks Yann Droneaud
2013-08-08 19:40   ` [PATCH libibverbs v2 11/11] read_config_file(): refuse to open configuration file if it's symlink Yann Droneaud
2013-08-12 19:26   ` [PATCH libibverbs v2 00/11] make read_config() more robust Jason Gunthorpe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.