virtfs-proxy-helper.texi 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. @example
  2. @c man begin SYNOPSIS
  3. @command{virtfs-proxy-helper} @var{options}
  4. @c man end
  5. @end example
  6. @c man begin DESCRIPTION
  7. @table @description
  8. Pass-through security model in QEMU 9p server needs root privilege to do
  9. few file operations (like chown, chmod to any mode/uid:gid). There are two
  10. issues in pass-through security model
  11. 1) TOCTTOU vulnerability: Following symbolic links in the server could
  12. provide access to files beyond 9p export path.
  13. 2) Running QEMU with root privilege could be a security issue.
  14. To overcome above issues, following approach is used: A new filesystem
  15. type 'proxy' is introduced. Proxy FS uses chroot + socket combination
  16. for securing the vulnerability known with following symbolic links.
  17. Intention of adding a new filesystem type is to allow qemu to run
  18. in non-root mode, but doing privileged operations using socket IO.
  19. Proxy helper(a stand alone binary part of qemu) is invoked with
  20. root privileges. Proxy helper chroots into 9p export path and creates
  21. a socket pair or a named socket based on the command line parameter.
  22. QEMU and proxy helper communicate using this socket. QEMU proxy fs
  23. driver sends filesystem request to proxy helper and receives the
  24. response from it.
  25. The proxy helper is designed so that it can drop root privileges except
  26. for the capabilities needed for doing filesystem operations.
  27. @end table
  28. @c man end
  29. @c man begin OPTIONS
  30. The following options are supported:
  31. @table @option
  32. @item -h
  33. @findex -h
  34. Display help and exit
  35. @item -p|--path path
  36. Path to export for proxy filesystem driver
  37. @item -f|--fd socket-id
  38. Use given file descriptor as socket descriptor for communicating with
  39. qemu proxy fs drier. Usually a helper like libvirt will create
  40. socketpair and pass one of the fds as parameter to -f|--fd
  41. @item -s|--socket socket-file
  42. Creates named socket file for communicating with qemu proxy fs driver
  43. @item -u|--uid uid -g|--gid gid
  44. uid:gid combination to give access to named socket file
  45. @item -n|--nodaemon
  46. Run as a normal program. By default program will run in daemon mode
  47. @end table
  48. @c man end
  49. @setfilename virtfs-proxy-helper
  50. @settitle QEMU 9p virtfs proxy filesystem helper
  51. @c man begin AUTHOR
  52. M. Mohan Kumar
  53. @c man end