io: add QIOChannelTLS class

Add a QIOChannel subclass that can run the TLS protocol over
the top of another QIOChannel instance. The object provides a
simplified API to perform the handshake when starting the TLS
session. The layering of TLS over the underlying channel does
not have to be setup immediately. It is possible to take an
existing QIOChannel that has done some handshake and then swap
in the QIOChannelTLS layer. This allows for use with protocols
which start TLS right away, and those which start plain text
and then negotiate TLS.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
7 files changed
tree: 4332e40f84a3272e2fe8d424354f11c890f9b0c0
  1. audio/
  2. backends/
  3. block/
  4. bsd-user/
  5. contrib/
  6. crypto/
  7. default-configs/
  8. disas/
  9. docs/
  10. fpu/
  11. fsdev/
  12. gdb-xml/
  13. hw/
  14. include/
  15. io/
  16. libdecnumber/
  17. linux-headers/
  18. linux-user/
  19. migration/
  20. net/
  21. pc-bios/
  22. po/
  23. qapi/
  24. qga/
  25. qobject/
  26. qom/
  27. replay/
  28. roms/
  29. scripts/
  30. slirp/
  31. stubs/
  32. target-alpha/
  33. target-arm/
  34. target-cris/
  35. target-i386/
  36. target-lm32/
  37. target-m68k/
  38. target-microblaze/
  39. target-mips/
  40. target-moxie/
  41. target-openrisc/
  42. target-ppc/
  43. target-s390x/
  44. target-sh4/
  45. target-sparc/
  46. target-tilegx/
  47. target-tricore/
  48. target-unicore32/
  49. target-xtensa/
  50. tcg/
  51. tests/
  52. trace/
  53. ui/
  54. util/
  55. .dir-locals.el
  56. .exrc
  57. .gitignore
  58. .gitmodules
  59. .mailmap
  60. .travis.yml
  61. accel.c
  62. aio-posix.c
  63. aio-win32.c
  64. arch_init.c
  65. async.c
  66. balloon.c
  67. block.c
  68. blockdev-nbd.c
  69. blockdev.c
  70. blockjob.c
  71. bootdevice.c
  72. bt-host.c
  73. bt-vhci.c
  74. Changelog
  75. CODING_STYLE
  76. configure
  77. COPYING
  78. COPYING.LIB
  79. cpu-exec-common.c
  80. cpu-exec.c
  81. cpus.c
  82. cputlb.c
  83. device-hotplug.c
  84. device_tree.c
  85. disas.c
  86. dma-helpers.c
  87. dump.c
  88. exec.c
  89. gdbstub.c
  90. HACKING
  91. hmp-commands-info.hx
  92. hmp-commands.hx
  93. hmp.c
  94. hmp.h
  95. iohandler.c
  96. ioport.c
  97. iothread.c
  98. kvm-all.c
  99. kvm-stub.c
  100. LICENSE
  101. main-loop.c
  102. MAINTAINERS
  103. Makefile
  104. Makefile.objs
  105. Makefile.target
  106. memory.c
  107. memory_mapping.c
  108. module-common.c
  109. monitor.c
  110. nbd.c
  111. numa.c
  112. os-posix.c
  113. os-win32.c
  114. page_cache.c
  115. qapi-schema.json
  116. qdev-monitor.c
  117. qdict-test-data.txt
  118. qemu-bridge-helper.c
  119. qemu-char.c
  120. qemu-doc.texi
  121. qemu-ga.texi
  122. qemu-img-cmds.hx
  123. qemu-img.c
  124. qemu-img.texi
  125. qemu-io-cmds.c
  126. qemu-io.c
  127. qemu-log.c
  128. qemu-nbd.c
  129. qemu-nbd.texi
  130. qemu-options-wrapper.h
  131. qemu-options.h
  132. qemu-options.hx
  133. qemu-seccomp.c
  134. qemu-tech.texi
  135. qemu-timer.c
  136. qemu.nsi
  137. qemu.sasl
  138. qjson.c
  139. qmp-commands.hx
  140. qmp.c
  141. qtest.c
  142. README
  143. rules.mak
  144. softmmu_template.h
  145. spice-qemu-char.c
  146. tcg-runtime.c
  147. tci.c
  148. thread-pool.c
  149. thunk.c
  150. tpm.c
  151. trace-events
  152. translate-all.c
  153. translate-all.h
  154. translate-common.c
  155. user-exec.c
  156. VERSION
  157. version.rc
  158. vl.c
  159. xen-common-stub.c
  160. xen-common.c
  161. xen-hvm-stub.c
  162. xen-hvm.c
  163. xen-mapcache.c