geom_gate userland utility improvements
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

47 lines
1.6 KiB

  1. .\"
  2. .\" Copyright (c) 2009 by Daniel Stenberg
  3. .\"
  4. .TH libssh2_knownhost_writeline 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
  5. .SH NAME
  6. libssh2_knownhost_writeline - convert a known host to a line for storage
  7. .SH SYNOPSIS
  8. #include <libssh2.h>
  9. libssh2_knownhost_writeline(LIBSSH2_KNOWNHOSTS *hosts,
  10. struct libssh2_knownhost *known,
  11. char *buffer, size_t buflen,
  12. size_t *outlen,
  13. int type);
  14. .SH DESCRIPTION
  15. Converts a single known host to a single line of output for storage, using
  16. the 'type' output format.
  17. \fIknown\fP identifies which particular known host
  18. \fIbuffer\fP points to an allocated buffer
  19. \fIbuflen\fP is the size of the \fIbuffer\fP. See RETURN VALUE about the size.
  20. \fIoutlen\fP must be a pointer to a size_t variable that will get the output
  21. length of the stored data chunk. The number does not included the trailing
  22. zero!
  23. \fItype\fP specifies what file type it is, and
  24. \fILIBSSH2_KNOWNHOST_FILE_OPENSSH\fP is the only currently supported
  25. format.
  26. .SH RETURN VALUE
  27. Returns a regular libssh2 error code, where negative values are error codes
  28. and 0 indicates success.
  29. If the provided buffer is deemed too small to fit the data libssh2 wants to
  30. store in it, LIBSSH2_ERROR_BUFFER_TOO_SMALL will be returned. The application
  31. is then advised to call the function again with a larger buffer. The
  32. \fIoutlen\fP size will then hold the requested size.
  33. .SH AVAILABILITY
  34. Added in libssh2 1.2
  35. .SH SEE ALSO
  36. .BR libssh2_knownhost_get(3)
  37. .BR libssh2_knownhost_readline(3)
  38. .BR libssh2_knownhost_writefile(3)