123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704 |
- * Copyright (c) 2015 Patrick Monnerat, D+H <[email protected]>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms,
- * with or without modification, are permitted provided
- * that the following conditions are met:
- *
- * Redistributions of source code must retain the above
- * copyright notice, this list of conditions and the
- * following disclaimer.
- *
- * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following
- * disclaimer in the documentation and/or other materials
- * provided with the distribution.
- *
- * Neither the name of the copyright holder nor the names
- * of any other contributors may be used to endorse or
- * promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
- * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
- * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
- * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
- * OF SUCH DAMAGE.
- /if not defined(LIBSSH2_H_)
- /define LIBSSH2_H_
- d LIBSSH2_COPYRIGHT...
- d c '2004-2015 The libssh2 project and +
- d its contributors.'
- * We use underscore instead of dash when appending DEV in dev versions
- * just to make the BANNER define (used by src/session.c) be a valid SSH
- * banner. Release versions have no appended strings and may of course not
- * have dashes either.
- d LIBSSH2_VERSION...
- d c '@LIBSSH2_VERSION@'
- * The numeric version number is also available "in parts" by using these
- * defines:
- d LIBSSH2_VERSION_MAJOR...
- d c @LIBSSH2_VERSION_MAJOR@
- d LIBSSH2_VERSION_MINOR...
- d c @LIBSSH2_VERSION_MINOR@
- d LIBSSH2_VERSION_PATCH...
- d c @LIBSSH2_VERSION_PATCH@
- * This is the numeric version of the libssh2 version number, meant for
- * easier parsing and comparions by programs. The LIBSSH2_VERSION_NUM
- * define will always follow this syntax:
- *
- * X'XXYYZZ'
- *
- * Where XX, YY and ZZ are the main version, release and patch numbers in
- * hexadecimal (using 8 bits each). All three numbers are always
- * represented using two digits. 1.2 would appear as "0x010200" while
- * version 9.11.7 appears as X'090b07'.
- *
- * This 6-digit (24 bits) hexadecimal number does not show pre-release
- * number, and it is always a greater number in a more recent release. It
- * makes comparisons with greater than and less than work.
- d LIBSSH2_VERSION_NUM...
- d c X'@LIBSSH2_VERSION_NUM@'
- * This is the date and time when the full source package was created. The
- * timestamp is not stored in the source code repo, as the timestamp is
- * properly set in the tarballs by the maketgz script.
- *
- * The format of the date should follow this template:
- *
- * "Mon Feb 12 11:35:33 UTC 2007"
- d LIBSSH2_TIMESTAMP...
- d c '@LIBSSH2_TIMESTAMP@'
- d libssh2_Cchar s 3i 0 based(######typedef######)
- d libssh2_Cuchar s 3u 0 based(######typedef######)
- d libssh2_Cshort s 5i 0 based(######typedef######)
- d libssh2_Cushort...
- d s 5u 0 based(######typedef######)
- d libssh2_Cint s 10i 0 based(######typedef######)
- d libssh2_CuInt s 10u 0 based(######typedef######)
- d libssh2_Clong s 10i 0 based(######typedef######)
- d libssh2_Culong s 10u 0 based(######typedef######)
- d libssh2_Clonglong...
- d s 20i 0 based(######typedef######)
- d libssh2_Culonglong...
- d s 20u 0 based(######typedef######)
- d libssh2_Cenum s 10i 0 based(######typedef######)
- d libssh2_Cssize_t...
- d s 10i 0 based(######typedef######)
- d libssh2_Csize_t...
- d s 10u 0 based(######typedef######)
- d libssh2_Cfloat s 4f based(######typedef######)
- d libssh2_Cdouble...
- d s 8f based(######typedef######)
- d libssh2_uint8_t...
- d s 3u 0 based(######typedef######)
- d libssh2_uint32_t...
- d s 10u 0 based(######typedef######)
- d libssh2_uint64_t...
- d s 20u 0 based(######typedef######)
- d libssh2_int64_t...
- d s 20i 0 based(######typedef######)
- d libssh2_socket_t...
- d s 10i 0 based(######typedef######)
- d LIBSSH2_INVALID_SOCKET...
- d c -1
- d libssh2_mode_t s 10u 0 based(######typedef######)
- d libssh2_ino_t s 10u 0 based(######typedef######)
- d libssh2_uid_t s 10u 0 based(######typedef######)
- d libssh2_gid_t s 10u 0 based(######typedef######)
- d libssh2_dev_t s 10u 0 based(######typedef######)
- d libssh2_off_t s 20i 0 based(######typedef######) Use *IFS64IO
- d libssh2_time_t s 10i 0 based(######typedef######)
- d libssh2_nlink_t...
- d s 5u 0 based(######typedef######)
- d libssh2_qp0l_objtype_t... AS400 object type
- d s 11
- d libssh2_struct_stat_size...
- d s based(######typedef######)
- d like(libssh2_off_t)
- d libssh2_struct_stat...
- d ds based(######typedef######)
- d align qualified
- d st_mode like(libssh2_mode_t) Mode flags
- d st_ino like(libssh2_ino_t) File serial number
- d st_nlink like(libssh2_nlink_t) Number of links
- d st_uid like(libssh2_uid_t) Owner ID
- d st_gid like(libssh2_gid_t) Group ID
- d st_size like(libssh2_off_t) File size
- d st_atime like(libssh2_time_t) Last access time
- d st_mtime like(libssh2_time_t) Last update time
- d st_ctime like(libssh2_time_t) Creation time
- d st_dev like(libssh2_dev_t) File root device
- d st_blksize like(libssh2_Csize_t) Block size
- d st_allocsize like(libssh2_Culong) Allocation size
- d st_objtype like(libssh2_qp0l_objtype_t) AS400 object type
- d st_codepage like(libssh2_Cushort) Object data codepage
- d 62 Reserved
- d st_ino_gen_id like(libssh2_Cuint) File SN gen. ID
- d LIBSSH2_STRUCT_STAT_SIZE_FORMAT...
- d c '%lld'
- * Part of every banner, user specified or not.
- d LIBSSH2_SSH_BANNER...
- d c 'SSH-2.0-libssh2_1.6.1_DEV'
- d LIBSSH2_SSH_DEFAULT_BANNER...
- d c 'SSH-2.0-libssh2_1.6.1_DEV'
- * Default generate and safe prime sizes for
- * diffie-hellman-group-exchange-sha1.
- d LIBSSH2_DH_GEX_MINGROUP...
- d c 1024
- d LIBSSH2_DH_GEX_OPTGROUP...
- d c 1536
- d LIBSSH2_DH_GEX_MAXGROUP...
- d c 2048
- * Defaults for pty requests.
- d LIBSSH2_TERM_WIDTH...
- d c 80
- d LIBSSH2_TERM_HEIGHT...
- d c 24
- d LIBSSH2_TERM_WIDTH_PX...
- d c 0
- d LIBSSH2_TERM_HEIGHT_PX...
- d c 0
- * 1/4 second.
- d LIBSSH2_SOCKET_POLL_UDELAY...
- d c 250000
- * 0.25 * 120 == 30 seconds.
- d LIBSSH2_SOCKET_POLL_MAXLOOPS...
- d c 120
- * Maximum size to allow a payload to compress to, plays it safe by
- * falling short of spec limits.
- d LIBSSH2_PACKET_MAXCOMP...
- d c 32000
- * Maximum size to allow a payload to deccompress to, plays it safe by
- * allowing more than spec requires.
- d LIBSSH2_PACKET_MAXDECOMP...
- d c 40000
- * Maximum size for an inbound compressed payload, plays it safe by
- * overshooting spec limits.
- d LIBSSH2_PACKET_MAXPAYLOAD...
- d c 40000
- d LIBSSH2_USERAUTH_KBDINT_PROMPT...
- d ds based(######typedef######)
- d align qualified
- d text * char *
- d length like(libssh2_Cuint)
- d echo like(libssh2_Cuchar)
- d LIBSSH2_USERAUTH_KBDINT_RESPONSE...
- d ds based(######typedef######)
- d align qualified
- d text * char *
- d length like(libssh2_Cuint)
- * libssh2_session_callback_set() constants.
- d LIBSSH2_CALLBACK_IGNORE...
- d c 0
- d LIBSSH2_CALLBACK_DEBUG...
- d c 1
- d LIBSSH2_CALLBACK_DISCONNECT...
- d c 2
- d LIBSSH2_CALLBACK_MACERROR...
- d c 3
- d LIBSSH2_CALLBACK_X11...
- d c 4
- d LIBSSH2_CALLBACK_SEND...
- d c 5
- d LIBSSH2_CALLBACK_RECV...
- d c 6
- * libssh2_session_method_pref() constants.
- d LIBSSH2_METHOD_KEX...
- d c 0
- d LIBSSH2_METHOD_HOSTKEY...
- d c 1
- d LIBSSH2_METHOD_CRYPT_CS...
- d c 2
- d LIBSSH2_METHOD_CRYPT_SC...
- d c 3
- d LIBSSH2_METHOD_MAC_CS...
- d c 4
- d LIBSSH2_METHOD_MAC_SC...
- d c 5
- d LIBSSH2_METHOD_COMP_CS...
- d c 6
- d LIBSSH2_METHOD_COMP_SC...
- d c 7
- d LIBSSH2_METHOD_LANG_CS...
- d c 8
- d LIBSSH2_METHOD_LANG_SC...
- d c 9
- * flags.
- d LIBSSH2_FLAG_SIGPIPE...
- d c X'0001'
- d LIBSSH2_FLAG_COMPRESS...
- d c X'0002'
- d LIBSSH2_POLLFD ds based(######typedef######)
- d align qualified
- d type like(libssh2_Cuchar)
- d fd * Union
- d socket overlay(fd) like(libssh2_socket_t)
- d channel * overlay(fd) LIBSSH2_CHANNEL *
- d listener * overlay(fd) LIBSSH2_LISTENER *
- d events like(libssh2_Culong)
- d revents like(libssh2_Culong)
- * Poll FD Descriptor Types.
- d LIBSSH2_POLLFD_SOCKET...
- d c 1
- d LIBSSH2_POLLFD_CHANNEL...
- d c 2
- d LIBSSH2_POLLFD_LISTENER...
- d c 3
- * Poll FD events/revents -- Match sys/poll.h where possible.
- d LIBSSH2_POLLFD_POLLIN... Input data ready or
- d c X'0001' connection available
- d LIBSSH2_POLLFD_POLLPRI... Prio data ready to
- d c X'0002' be read. Socket only
- d LIBSSH2_POLLFD_POLLEXT... Ext data ready to be
- d c X'0002' read. Channel only
- d LIBSSH2_POLLFD_POLLOUT... Can may be written:
- d c X'0004' Socket/Channel
- * revents only.
- d LIBSSH2_POLLFD_POLLERR... Error Condition:
- d c X'0008' Socket
- d LIBSSH2_POLLFD_POLLHUP... HangUp/EOF
- d c X'0010' Socket
- d LIBSSH2_POLLFD_SESSION_CLOSED... Session Disconnect
- d c X'0010'
- d LIBSSH2_POLLFD_POLLNVAL... Invalid request
- d c X'0020' Socket
- d LIBSSH2_POLLFD_POLLEX... Exception Condition
- d c X'0040' Socket/Win32
- d LIBSSH2_POLLFD_CHANNEL_CLOSED... Channel Disconnect
- d c X'0080'
- d LIBSSH2_POLLFD_LISTENER_CLOSED... Listener Disconnect
- d c X'0080'
- /define HAVE_LIBSSH2_SESSION_BLOCK_DIRECTION
- * Block Direction Types.
- d LIBSSH2_SESSION_BLOCK_INBOUND...
- d c X'0001'
- d LIBSSH2_SESSION_BLOCK_OUTBOUND...
- d c X'0002'
- * Hash Types.
- d LIBSSH2_HOSTKEY_HASH_MD5...
- d c 1
- d LIBSSH2_HOSTKEY_HASH_SHA1...
- d c 2
- * Hostkey Types.
- d LIBSSH2_HOSTKEY_TYPE_UNKNOWN...
- d c 0
- d LIBSSH2_HOSTKEY_TYPE_RSA...
- d c 1
- d LIBSSH2_HOSTKEY_TYPE_DSS...
- d c 2
- * Disconnect Codes (defined by SSH protocol).
- d SSH_DISCONNECT_HOST_NOT_ALLOWED_TO_CONNECT...
- d c 1
- d SSH_DISCONNECT_PROTOCOL_ERROR...
- d c 2
- d SSH_DISCONNECT_KEY_EXCHANGE_FAILED...
- d c 3
- d SSH_DISCONNECT_RESERVED...
- d c 4
- d SSH_DISCONNECT_MAC_ERROR...
- d c 5
- d SSH_DISCONNECT_COMPRESSION_ERROR...
- d c 6
- d SSH_DISCONNECT_SERVICE_NOT_AVAILABLE...
- d c 7
- d SSH_DISCONNECT_PROTOCOL_VERSION_NOT_SUPPORTED...
- d c 8
- d SSH_DISCONNECT_HOST_KEY_NOT_VERIFIABLE...
- d c 9
- d SSH_DISCONNECT_CONNECTION_LOST...
- d c 10
- d SSH_DISCONNECT_BY_APPLICATION...
- d c 11
- d SSH_DISCONNECT_TOO_MANY_CONNECTIONS...
- d c 12
- d SSH_DISCONNECT_AUTH_CANCELLED_BY_USER...
- d c 13
- d SSH_DISCONNECT_NO_MORE_AUTH_METHODS_AVAILABLE...
- d c 14
- d SSH_DISCONNECT_ILLEGAL_USER_NAME...
- d c 15
- * Error Codes (defined by libssh2).
- d LIBSSH2_ERROR_NONE...
- d c 0
- * The library once used -1 as a generic error return value on numerous
- * places through the code, which subsequently was converted to
- * LIBSSH2_ERROR_SOCKET_NONE uses over time. As this is a generic error
- * code, the goal is to never ever return this code but instead make sure
- * that a more accurate and descriptive error code is used.
- d LIBSSH2_ERROR_SOCKET_NONE...
- d c -1
- d LIBSSH2_ERROR_BANNER_RECV...
- d c -2
- d LIBSSH2_ERROR_BANNER_SEND...
- d c -3
- d LIBSSH2_ERROR_INVALID_MAC...
- d c -4
- d LIBSSH2_ERROR_KEX_FAILURE...
- d c -5
- d LIBSSH2_ERROR_ALLOC...
- d c -6
- d LIBSSH2_ERROR_SOCKET_SEND...
- d c -7
- d LIBSSH2_ERROR_KEY_EXCHANGE_FAILURE...
- d c -8
- d LIBSSH2_ERROR_TIMEOUT...
- d c -9
- d LIBSSH2_ERROR_HOSTKEY_INIT...
- d c -10
- d LIBSSH2_ERROR_HOSTKEY_SIGN...
- d c -11
- d LIBSSH2_ERROR_DECRYPT...
- d c -12
- d LIBSSH2_ERROR_SOCKET_DISCONNECT...
- d c -13
- d LIBSSH2_ERROR_PROTO...
- d c -14
- d LIBSSH2_ERROR_PASSWORD_EXPIRED...
- d c -15
- d LIBSSH2_ERROR_FILE...
- d c -16
- d LIBSSH2_ERROR_METHOD_NONE...
- d c -17
- d LIBSSH2_ERROR_AUTHENTICATION_FAILED...
- d c -18
- d LIBSSH2_ERROR_PUBLICKEY_UNRECOGNIZED...
- d c -18
- d LIBSSH2_ERROR_PUBLICKEY_UNVERIFIED...
- d c -19
- d LIBSSH2_ERROR_CHANNEL_OUTOFORDER...
- d c -20
- d LIBSSH2_ERROR_CHANNEL_FAILURE...
- d c -21
- d LIBSSH2_ERROR_CHANNEL_REQUEST_DENIED...
- d c -22
- d LIBSSH2_ERROR_CHANNEL_UNKNOWN...
- d c -23
- d LIBSSH2_ERROR_CHANNEL_WINDOW_EXCEEDED...
- d c -24
- d LIBSSH2_ERROR_CHANNEL_PACKET_EXCEEDED...
- d c -25
- d LIBSSH2_ERROR_CHANNEL_CLOSED...
- d c -26
- d LIBSSH2_ERROR_CHANNEL_EOF_SENT...
- d c -27
- d LIBSSH2_ERROR_SCP_PROTOCOL...
- d c -28
- d LIBSSH2_ERROR_ZLIB...
- d c -29
- d LIBSSH2_ERROR_SOCKET_TIMEOUT...
- d c -30
- d LIBSSH2_ERROR_SFTP_PROTOCOL...
- d c -31
- d LIBSSH2_ERROR_REQUEST_DENIED...
- d c -32
- d LIBSSH2_ERROR_METHOD_NOT_SUPPORTED...
- d c -33
- d LIBSSH2_ERROR_INVAL...
- d c -34
- d LIBSSH2_ERROR_INVALID_POLL_TYPE...
- d c -35
- d LIBSSH2_ERROR_PUBLICKEY_PROTOCOL...
- d c -36
- d LIBSSH2_ERROR_EAGAIN...
- d c -37
- d LIBSSH2_ERROR_BUFFER_TOO_SMALL...
- d c -38
- d LIBSSH2_ERROR_BAD_USE...
- d c -39
- d LIBSSH2_ERROR_COMPRESS...
- d c -40
- d LIBSSH2_ERROR_OUT_OF_BOUNDARY...
- d c -41
- d LIBSSH2_ERROR_AGENT_PROTOCOL...
- d c -42
- d LIBSSH2_ERROR_SOCKET_RECV...
- d c -43
- d LIBSSH2_ERROR_ENCRYPT...
- d c -44
- d LIBSSH2_ERROR_BAD_SOCKET...
- d c -45
- d LIBSSH2_ERROR_KNOWN_HOSTS...
- d c -46
- * this is a define to provide the old (<= 1.2.7) name.
- d LIBSSH2_ERROR_BANNER_NONE...
- d c -2
- * Global API.
- d LIBSSH2_INIT_NO_CRYPTO...
- d c X'0001'
- * libssh2_init()
- *
- * Initialize the libssh2 functions. This typically initialize the
- * crypto library. It uses a global state, and is not thread safe --
- * you must make sure this function is not called concurrently.
- *
- * Flags can be:
- * 0: Normal initialize
- * LIBSSH2_INIT_NO_CRYPTO: Do not initialize the crypto library
- * (ie. OPENSSL_add_cipher_algorithms() for
- * OpenSSL)
- *
- * Returns 0 if succeeded, or a negative value for error.
- d libssh2_init pr extproc('libssh2_init')
- d like(libssh2_Cint)
- d flags value like(libssh2_Cint)
- * libssh2_exit()
- *
- * Exit the libssh2 functions and free's all memory used internal.
- d libssh2_exit pr extproc('libssh2_exit')
- * libssh2_free()
- *
- * Deallocate memory allocated by earlier call to libssh2 functions.
- d libssh2_free pr extproc('libssh2_free')
- d session * value LIBSSH2_SESSION *
- d ptr * value void *
- * libssh2_session_supported_algs()
- *
- * Fills algs with a list of supported cryptographic algorithms. Returns a
- * non-negative number (number of supported algorithms) on success or a
- * negative number (an eror code) on failure.
- *
- * NOTE: on success, algs must be deallocated (by calling libssh2_free)
- * when not needed anymore
- d libssh2_session_supported_algs...
- d pr extproc(
- d 'libssh2_session_supported_algs')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d method_type value like(libssh2_Cint)
- d algs * const char **(*)
- * Session API.
- d libssh2_session_init_ex...
- d pr * extproc('libssh2_session_init_ex') LIBSSH2_SESSION *
- d my_alloc * value procptr
- d my_free * value procptr
- d my_realloc * value procptr
- d abstract * value void *
- * Implementation of C macro.
- d libssh2_session_init...
- d pr * extproc('libssh2_session_init') LIBSSH2_SESSION *
- d libssh2_session_abstract...
- d pr * extproc('libssh2_session_abstract') void * *
- d session * value LIBSSH2_SESSION *
- d libssh2_session_callback_set...
- d pr * extproc( void *
- d 'libssh2_session_callback_set')
- d session * value LIBSSH2_SESSION *
- d cbtype value like(libssh2_Cint)
- d callback * value void *
- d libssh2_session_banner_set...
- d pr extproc('libssh2_session_banner_set')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d banner * value options(*string) const char *
- d libssh2_banner_set...
- d pr extproc('libssh2_banner_set')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d banner * value options(*string) const char *
- d libssh2_session_startup...
- d pr extproc('libssh2_session_startup')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d sock value like(libssh2_Cint)
- d libssh2_session_handshake...
- d pr extproc('libssh2_session_handshake')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d sock value like(libssh2_socket_t)
- d libssh2_session_disconnect_ex...
- d pr extproc(
- d 'libssh2_session_disconnect_ex')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d reason value like(libssh2_Cint)
- d description * value options(*string) const char *
- d lang * value options(*string) const char *
- * Implementation of C macro.
- d libssh2_session_disconnect...
- d pr extproc('libssh2_session_disconnect')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d description * value options(*string) const char *
- d libssh2_session_free...
- d pr extproc('libssh2_session_free')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d libssh2_hostkey_hash...
- d pr * extproc('libssh2_hostkey_hash') const char *
- d session * value LIBSSH2_SESSION *
- d hash_type value like(libssh2_Cint)
- d libssh2_session_hostkey...
- d pr * extproc('libssh2_session_hostkey') const char *
- d session * value LIBSSH2_SESSION *
- d len like(libssh2_Csize_t)
- d type like(libssh2_Cint)
- d libssh2_session_method_pref...
- d pr extproc(
- d 'libssh2_session_method_pref')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d method_type value like(libssh2_Cint)
- d prefs * value options(*string) const char *
- d libssh2_session_methods...
- d pr * extproc('libssh2_session_methods') const char *
- d session * value LIBSSH2_SESSION *
- d method_type value like(libssh2_Cint)
- d libssh2_session_last_error...
- d pr extproc('libssh2_session_last_error')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d errmsg * char *(*)
- d errmsg_len like(libssh2_Cint)
- d want_buf value like(libssh2_Cint)
- d libssh2_session_last_errno...
- d pr extproc('libssh2_session_last_errno')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d libssh2_session_set_last_error...
- d pr extproc(
- d 'libssh2_session_set_last_error')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d errcode value like(libssh2_Cint)
- d errmsg * value options(*string) const char *
- d libssh2_session_block_directions...
- d pr extproc(
- d 'libssh2_session_block_directions')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d libssh2_session_flag...
- d pr extproc('libssh2_session_flag')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d flag value like(libssh2_Cint)
- d value value like(libssh2_Cint)
- d libssh2_session_banner_get...
- d pr * extproc('libssh2_session_banner_get') const char *
- d session * value LIBSSH2_SESSION *
- * Userauth API.
- d libssh2_userauth_list...
- d pr * extproc('libssh2_userauth_list') char *
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Cuint)
- d libssh2_userauth_authenticated...
- d pr extproc(
- d 'libssh2_userauth_authenticated')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d libssh2_userauth_password_ex...
- d pr extproc(
- d 'libssh2_userauth_password_ex')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Cuint)
- d password * value options(*string) const char *
- d password_len value like(libssh2_Cuint)
- d passwd_change_cb...
- d * value procptr
- * Implementation of C macro.
- d libssh2_userauth_password...
- d pr extproc('libssh2_userauth_password')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d password * value options(*string) const char *
- d libssh2_userauth_publickey_fromfile_ex...
- d pr extproc('libssh2_userauth_publickey_-
- d fromfile_ex')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Cuint)
- d publickey * value options(*string) const char *
- d privatekey * value options(*string) const char *
- d passphrase * value options(*string) const char *
- * Implementation of C macro.
- d libssh2_userauth_publickey_fromfile...
- d pr extproc(
- d 'libssh2_userauth_publickey_fromfile'
- d )
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d publickey * value options(*string) const char *
- d privatekey * value options(*string) const char *
- d passphrase * value options(*string) const char *
- d libssh2_userauth_publickey...
- d pr extproc('libssh2_userauth_publickey')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d pubkeydata * value options(*string) const unsigned char*
- d pubkeydata_len...
- d value like(libssh2_Csize_t)
- d sign_callback * value procptr
- d abstract * void *(*)
- d libssh2_userauth_hostbased_fromfile_ex...
- d pr extproc('libssh2_userauth_hostbased_-
- d fromfile_ex')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Cuint)
- d publickey * value options(*string) const char *
- d privatekey * value options(*string) const char *
- d passphrase * value options(*string) const char *
- d hostname * value options(*string) const char *
- d hostname_len value like(libssh2_Cuint)
- d local_username...
- d * value options(*string) const char *
- d local_username_len...
- d value like(libssh2_Cuint)
- * C macro implementation.
- d libssh2_userauth_hostbased_fromfile...
- d pr extproc(
- d 'libssh2_userauth_hostbased_fromfile'
- d )
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d publickey * value options(*string) const char *
- d privatekey * value options(*string) const char *
- d passphrase * value options(*string) const char *
- d hostname * value options(*string) const char *
- d libssh2_userauth_publickey_frommemory...
- d pr extproc('libssh2_userauth_publickey_-
- d frommemory')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Csize_t)
- d publickeyfiledata...
- d * value options(*string) const char *
- d publickeyfiledata_len...
- d value like(libssh2_Csize_t)
- d privatekeyfiledata...
- d * value options(*string) const char *
- d privatekeyfiledata_len...
- d value like(libssh2_Csize_t)
- d passphrase * value options(*string) const char *
- * response_callback is provided with filled by library prompts array,
- * but client must allocate and fill individual responses. Responses
- * array is already allocated. Responses data will be freed by libssh2
- * after callback return, but before subsequent callback invokation.
- d libssh2_userauth_keyboard_interactive_ex...
- d pr extproc('libssh2_userauth_keyboard_i-
- d nteractive_ex')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d username_len value like(libssh2_Cuint)
- d response_callback...
- d * value procptr
- * C macro implementation.
- d libssh2_userauth_keyboard_interactive...
- d pr extproc('libssh2_userauth_keyboard_i-
- d nteractive')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d username * value options(*string) const char *
- d response_callback...
- d * value procptr
- d libssh2_poll pr extproc('libssh2_poll')
- d like(libssh2_Cint)
- d fds * value LIBSSH2_POLLFD *
- d nfds value like(libssh2_Cuint)
- d timeout value like(libssh2_Clong)
- * Channel API.
- d LIBSSH2_CHANNEL_WINDOW_DEFAULT...
- d c X'00200000'
- d LIBSSH2_CHANNEL_PACKET_DEFAULT...
- d c 32768
- d LIBSSH2_CHANNEL_MINADJUST...
- d c 1024
- * Extended Data Handling.
- d LIBSSH2_CHANNEL_EXTENDED_DATA_NORMAL...
- d c 0
- d LIBSSH2_CHANNEL_EXTENDED_DATA_IGNORE...
- d c 1
- d LIBSSH2_CHANNEL_EXTENDED_DATA_MERGE...
- d c 2
- d SSH_EXTENDED_DATA_STDERR...
- d c 1
- * Returned by any function that would block during a read/write
- * operation.
- d LIBSSH2CHANNEL_EAGAIN... LIBSSH2_ERROR_EAGAIN
- d c -37
- d libssh2_channel_open_ex...
- d pr * extproc('libssh2_channel_open_ex') LIBSSH2_CHANNEL *
- d session * value LIBSSH2_SESSION *
- d channel_type * value options(*string) const char *
- d channel_type_len...
- d value like(libssh2_Cuint)
- d window_size value like(libssh2_Cuint)
- d packet_size value like(libssh2_Cuint)
- d message * value options(*string) const char *
- d message_len value like(libssh2_Cuint)
- * C macro implementation.
- d libssh2_channel_open_session...
- d pr * extproc( LIBSSH2_CHANNEL *
- d 'libssh2_channel_open_session')
- d session * value LIBSSH2_SESSION *
- d libssh2_channel_direct_tcpip_ex...
- d pr * extproc( LIBSSH2_CHANNEL *
- d 'libssh2_channel_direct_tcpip_ex')
- d session * value LIBSSH2_SESSION *
- d host * value options(*string) const char *
- d port value like(libssh2_Cint)
- d shost * value options(*string) const char *
- d sport value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_direct_tcpip...
- d pr * extproc( LIBSSH2_CHANNEL *
- d 'libssh2_channel_direct_tcpip')
- d session * value LIBSSH2_SESSION *
- d host * value options(*string) const char *
- d port value like(libssh2_Cint)
- d libssh2_channel_forward_listen_ex...
- d pr * extproc( LIBSSH2_LISTENER *
- d 'libssh2_channel_forward_listen_ex')
- d session * value LIBSSH2_SESSION *
- d host * value options(*string) const char *
- d port value like(libssh2_Cint)
- d bound_port like(libssh2_Cint)
- d queue_maxsize value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_forward_listen...
- d pr * extproc( LIBSSH2_LISTENER *
- d 'libssh2_channel_forward_listen')
- d session * value LIBSSH2_SESSION *
- d port value like(libssh2_Cint)
- d libssh2_channel_forward_cancel...
- d pr extproc(
- d 'libssh2_channel_forward_cancel')
- d like(libssh2_Cint)
- d listener * value LIBSSH2_LISTENER *
- d libssh2_channel_forward_accept...
- d pr * extproc( LIBSSH2_CHANNEL *
- d 'libssh2_channel_forward_accept')
- d listener * value LIBSSH2_LISTENER *
- d libssh2_channel_setenv_ex...
- d pr extproc('libssh2_channel_setenv_ex')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d varname * value options(*string) const char *
- d varname_len value like(libssh2_Cuint)
- d value * value options(*string) const char *
- d value_len value like(libssh2_Cuint)
- * C macro implementation.
- d libssh2_channel_setenv...
- d pr extproc('libssh2_channel_setenv')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d varname * value options(*string) const char *
- d value * value options(*string) const char *
- d libssh2_channel_request_pty_ex...
- d pr extproc(
- d 'libssh2_channel_request_pty_ex')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d term * value options(*string) const char *
- d term_len value like(libssh2_Cuint)
- d modes * value options(*string) const char *
- d modes_len value like(libssh2_Cuint)
- d width value like(libssh2_Cint)
- d height value like(libssh2_Cint)
- d width_px value like(libssh2_Cint)
- d height_px value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_request_pty...
- d pr extproc(
- d 'libssh2_channel_request_pty')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d term * value options(*string) const char *
- d libssh2_channel_request_pty_size_ex...
- d pr extproc(
- d 'libssh2_channel_request_pty_size_ex'
- d )
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d width value like(libssh2_Cint)
- d height value like(libssh2_Cint)
- d width_px value like(libssh2_Cint)
- d height_px value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_request_pty_size...
- d pr extproc(
- d 'libssh2_channel_request_pty_size')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d width value like(libssh2_Cint)
- d height value like(libssh2_Cint)
- d libssh2_channel_x11_req_ex...
- d pr extproc('libssh2_channel_x11_req_ex')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d single_connection...
- d value like(libssh2_Cint)
- d auth_proto * value options(*string) const char *
- d auth_cookie * value options(*string) const char *
- d screen_number value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_x11_req...
- d pr extproc('libssh2_channel_x11_req')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d screen_number value like(libssh2_Cint)
- d libssh2_channel_process_startup...
- d pr extproc(
- d 'libssh2_channel_process_startup')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d request * value options(*string) const char *
- d request_len value like(libssh2_Cuint)
- d message * value options(*string) const char *
- d message_len value like(libssh2_Cuint)
- * C macro implementation.
- d libssh2_channel_shell...
- d pr extproc('libssh2_channel_shell')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- * C macro implementation.
- d libssh2_channel_exec...
- d pr extproc('libssh2_channel_exec')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d command * value options(*string) const char *
- * C macro implementation.
- d libssh2_channel_subsystem...
- d pr extproc('libssh2_channel_subsystem')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d subsystem * value options(*string) const char *
- d libssh2_channel_read_ex...
- d pr extproc('libssh2_channel_read_ex')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d stream_id value like(libssh2_Cint)
- d buf * value char *
- d buflen value like(libssh2_Csize_t)
- * C macro implementation.
- d libssh2_channel_read...
- d pr extproc('libssh2_channel_read')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d buf * value char *
- d buflen value like(libssh2_Csize_t)
- * C macro implementation.
- d libssh2_channel_read_stderr...
- d pr extproc(
- d 'libssh2_channel_read_stderr')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d buf * value char *
- d buflen value like(libssh2_Csize_t)
- d libssh2_poll_channel_read...
- d pr extproc('libssh2_poll_channel_read')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d extended value like(libssh2_Cint)
- d libssh2_channel_window_read_ex...
- d pr extproc(
- d 'libssh2_channel_window_read_ex')
- d like(libssh2_Culong)
- d channel * value LIBSSH2_CHANNEL *
- d read_avail like(libssh2_Culong)
- d window_size_initial...
- d like(libssh2_Culong)
- * C macro implementation.
- d libssh2_channel_window_read...
- d pr extproc(
- d 'libssh2_channel_window_read')
- d like(libssh2_Culong)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_receive_window_adjust2...
- d pr extproc('libssh2_channel_receive_win-
- d dow_adjust2')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d adjustment value like(libssh2_Culong)
- d force value like(libssh2_Cuchar)
- d storewindow like(libssh2_Cuint)
- d libssh2_channel_write_ex...
- d pr extproc('libssh2_channel_write_ex')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d stream_id value like(libssh2_Cint)
- d buf * value options(*string) const char *
- d buflen value like(libssh2_Csize_t)
- * C macro implementation.
- d libssh2_channel_write...
- d pr extproc('libssh2_channel_write')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d buf * value options(*string) const char *
- d buflen value like(libssh2_Csize_t)
- * C macro implementation.
- d libssh2_channel_write_stderr...
- d pr extproc(
- d 'libssh2_channel_write_stderr')
- d like(libssh2_Cssize_t)
- d channel * value LIBSSH2_CHANNEL *
- d buf * value options(*string) const char *
- d buflen value like(libssh2_Csize_t)
- d libssh2_channel_window_write_ex...
- d pr extproc(
- d 'libssh2_channel_window_write_ex')
- d like(libssh2_Culong)
- d channel * value LIBSSH2_CHANNEL *
- d window_size_initial...
- d like(libssh2_Culong)
- * C macro implementation.
- d libssh2_channel_window_write...
- d pr extproc(
- d 'libssh2_channel_window_write')
- d like(libssh2_Culong)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_session_set_blocking...
- d pr extproc(
- d 'libssh2_session_set_blocking')
- d session * value LIBSSH2_SESSION *
- d blocking value like(libssh2_Cint)
- d libssh2_session_get_blocking...
- d pr extproc(
- d 'libssh2_session_get_blocking')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d libssh2_channel_set_blocking...
- d pr extproc(
- d 'libssh2_channel_set_blocking')
- d channel * value LIBSSH2_CHANNEL *
- d blocking value like(libssh2_Cint)
- d libssh2_session_set_timeout...
- d pr extproc(
- d 'libssh2_session_set_timeout')
- d session * value LIBSSH2_SESSION *
- d timeout value like(libssh2_Clong)
- d libssh2_session_get_timeout...
- d pr extproc(
- d 'libssh2_session_get_timeout')
- d like(libssh2_Clong)
- d session * value LIBSSH2_SESSION *
- d libssh2_channel_handle_extended_data2...
- d pr extproc('libssh2_channel_handle_exte-
- d nded_data2')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d ignore_mode value like(libssh2_Cint)
- * libssh2_channel_ignore_extended_data() is defined below for BC with
- * version 0.1.
- d LIBSSH2_CHANNEL_FLUSH_EXTENDED_DATA...
- d c -1
- d LIBSSH2_CHANNEL_FLUSH_ALL...
- d c -2
- d libssh2_channel_flush_ex...
- d pr extproc('libssh2_channel_flush_ex')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d streamid value like(libssh2_Cint)
- * C macro implementation.
- d libssh2_channel_flush...
- d pr extproc('libssh2_channel_flush')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- * C macro implementation.
- d libssh2_channel_flush_stderr...
- d pr extproc(
- d 'libssh2_channel_flush_stderr')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_get_exit_status...
- d pr extproc(
- d 'libssh2_channel_get_exit_status')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_get_exit_signal...
- d pr extproc(
- d 'libssh2_channel_get_exit_signal')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d exitsignal * char *(*)
- d exitsignal_len...
- d like(libssh2_Csize_t)
- d errmsg * char *(*)
- d errmsg_len like(libssh2_Csize_t)
- d langtag * char *(*)
- d langtag_len like(libssh2_Csize_t)
- d libssh2_channel_send_eof...
- d pr extproc('libssh2_channel_send_eof')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_eof...
- d pr extproc('libssh2_channel_eof')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_wait_eof...
- d pr extproc('libssh2_channel_wait_eof')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_close...
- d pr extproc('libssh2_channel_close')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_wait_closed...
- d pr extproc(
- d 'libssh2_channel_wait_closed')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- d libssh2_channel_free...
- d pr extproc('libssh2_channel_free')
- d like(libssh2_Cint)
- d channel * value LIBSSH2_CHANNEL *
- * Use libssh2_scp_recv2 for large (> 2GB) file support.
- d libssh2_scp_recv2...
- d pr * extproc('libssh2_scp_recv2') LIBSSH2_CHANNEL *
- d session * value LIBSSH2_SESSION *
- d path * value options(*string) const char *
- d sb likeds(libssh2_struct_stat)
- d libssh2_scp_send_ex...
- d pr * extproc('libssh2_scp_send_ex') LIBSSH2_CHANNEL *
- d session * value LIBSSH2_SESSION *
- d path * value options(*string) const char *
- d mode value like(libssh2_Cint)
- d size value like(libssh2_Csize_t)
- d mtime value like(libssh2_Clong)
- d atime value like(libssh2_Clong)
- d libssh2_scp_send64...
- d pr * extproc('libssh2_scp_send64') LIBSSH2_CHANNEL *
- d session * value LIBSSH2_SESSION *
- d path * value options(*string) const char *
- d mode value like(libssh2_Cint)
- d size value like(libssh2_int64_t)
- d mtime value like(libssh2_time_t)
- d atime value like(libssh2_time_t)
- * C macro implementation.
- d libssh2_scp_send...
- d pr * extproc('libssh2_scp_send') LIBSSH2_CHANNEL *
- d session * value LIBSSH2_SESSION *
- d path * value options(*string) const char *
- d mode value like(libssh2_Cint)
- d size value like(libssh2_int64_t)
- d libssh2_base64_decode...
- d pr extproc('libssh2_base64_decode')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d dest * value char * *
- d dest_len * value unsigned int *
- d src * value options(*string) const char *
- d src_len value like(libssh2_Cuint)
- * Procedure libssh2_version renamed to avoid upper/lower case name clash.
- d libssh2_get_version...
- d pr * extproc('libssh2_version') const char *
- d req_version_num...
- d value like(libssh2_Cint)
- d HAVE_LIBSSH2_KNOWNHOST_API... since 1.1.1
- d c X'010101'
- d HAVE_LIBSSH2_VERSION_API... since 1.1
- d c X'010100'
- d libssh2_knownhost...
- d ds based(######typedef######)
- d align qualified
- d magic like(libssh2_Cuint)
- d node * void *
- d name * char *
- d key * char *
- d typemask like(libssh2_Cint)
- * libssh2_knownhost_init
- *
- * Init a collection of known hosts. Returns the pointer to a collection.
- d libssh2_knownhost_init...
- d pr * extproc('libssh2_knownhost_init') LIBSSH2_KNOWNHOSTS *
- d session * value LIBSSH2_SESSION *
- * libssh2_knownhost_add
- *
- * Add a host and its associated key to the collection of known hosts.
- *
- * The 'type' argument specifies on what format the given host and
- * keys are:
- *
- * plain - ascii "hostname.domain.tld"
- * sha1 - SHA1(<salt> <host>) base64-encoded!
- * custom - another hash
- *
- * If 'sha1' is selected as type, the salt must be provided to the salt
- * argument. This too base64 encoded.
- *
- * The SHA-1 hash is what OpenSSH can be told to use in known_hosts files.
- * If a custom type is used, salt is ignored and you must provide the host
- * pre-hashed when checking for it in the libssh2_knownhost_check()
- * function.
- *
- * The keylen parameter may be omitted (zero) if the key is provided as a
- * NULL-terminated base64-encoded string.
- * host format (2 bits).
- d LIBSSH2_KNOWNHOST_TYPE_MASK...
- d c X'FFFF'
- d LIBSSH2_KNOWNHOST_TYPE_PLAIN...
- d c 1
- d LIBSSH2_KNOWNHOST_TYPE_SHA1... always base64 ncoded
- d c 2
- d LIBSSH2_KNOWNHOST_TYPE_CUSTOM...
- d c 3
- * key format (2 bits).
- d LIBSSH2_KNOWNHOST_KEYENC_MASK...
- d c X'00030000'
- d LIBSSH2_KNOWNHOST_KEYENC_RAW...
- d c X'00010000'
- d LIBSSH2_KNOWNHOST_KEYENC_BASE64...
- d c X'00020000'
- * type of key (3 bits).
- d LIBSSH2_KNOWNHOST_KEY_MASK...
- d c X'001C0000'
- d LIBSSH2_KNOWNHOST_KEY_SHIFT...
- d c 18
- d LIBSSH2_KNOWNHOST_KEY_RSA1...
- d c X'00040000'
- d LIBSSH2_KNOWNHOST_KEY_SSHRSA...
- d c X'00080000'
- d LIBSSH2_KNOWNHOST_KEY_SSHDSS...
- d c X'000C0000'
- d LIBSSH2_KNOWNHOST_KEY_UNKNOWN...
- d c X'001C0000'
- d libssh2_knownhost_add...
- d pr extproc('libssh2_knownhost_add')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d host * value options(*string) const char *
- d salt * value options(*string) const char *
- d key * value options(*string) const char *
- d keylen value like(libssh2_Csize_t)
- d typemask value like(libssh2_Cint)
- d store * libssh2_knownhost *
- * libssh2_knownhost_addc
- *
- * Add a host and its associated key to the collection of known hosts.
- *
- * Takes a comment argument that may be NULL. A NULL comment indicates
- * there is no comment and the entry will end directly after the key
- * when written out to a file. An empty string "" comment will indicate an
- * empty comment which will cause a single space to be written after the
- * key.
- *
- * The 'type' argument specifies on what format the given host and keys
- * are:
- *
- * plain - ascii "hostname.domain.tld"
- * sha1 - SHA1(<salt> <host>) base64-encoded!
- * custom - another hash
- *
- * If 'sha1' is selected as type, the salt must be provided to the salt
- * argument. This too base64 encoded.
- *
- * The SHA-1 hash is what OpenSSH can be told to use in known_hosts files.
- * If a custom type is used, salt is ignored and you must provide the host
- * pre-hashed when checking for it in the libssh2_knownhost_check()
- * function.
- *
- * The keylen parameter may be omitted (zero) if the key is provided as a
- * NULL-terminated base64-encoded string.
- d libssh2_knownhost_addc...
- d pr extproc('libssh2_knownhost_addc')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d host * value options(*string) const char *
- d salt * value options(*string) const char *
- d key * value options(*string) const char *
- d keylen value like(libssh2_Csize_t)
- d comment * value options(*string) const char *
- d commentlen value like(libssh2_Csize_t)
- d typemask value like(libssh2_Cint)
- d store * libssh2_knownhost *
- * libssh2_knownhost_check
- *
- * Check a host and its associated key against the collection of known
- * hosts.
- *
- * The type is the type/format of the given host name.
- *
- * plain - ascii "hostname.domain.tld"
- * custom - prehashed base64 encoded. Note that this cannot use any salts.
- *
- *
- * 'knownhost' may be set to NULL if you don't care about that info.
- *
- * Returns:
- *
- * LIBSSH2_KNOWNHOST_CHECK_* values, see below.
- d LIBSSH2_KNOWNHOST_CHECK_MATCH...
- d c 0
- d LIBSSH2_KNOWNHOST_CHECK_MISMATCH...
- d c 1
- d LIBSSH2_KNOWNHOST_CHECK_NOTFOUND...
- d c 2
- d LIBSSH2_KNOWNHOST_CHECK_FAILURE...
- d c 3
- d libssh2_knownhost_check...
- d pr extproc('libssh2_knownhost_check')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d host * value options(*string) const char *
- d key * value options(*string) const char *
- d keylen value like(libssh2_Csize_t)
- d typemask value like(libssh2_Cint)
- d knownhost * libssh2_knownhost *
- * this function is identital to the above one, but also takes a port
- * argument that allows libssh2 to do a better check.
- d libssh2_knownhost_checkp...
- d pr extproc('libssh2_knownhost_checkp')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d host * value options(*string) const char *
- d port value like(libssh2_Cint)
- d key * value options(*string) const char *
- d keylen value like(libssh2_Csize_t)
- d typemask value like(libssh2_Cint)
- d knownhost * libssh2_knownhost *
- * libssh2_knownhost_del
- *
- * Remove a host from the collection of known hosts. The 'entry' struct is
- * retrieved by a call to libssh2_knownhost_check().
- d libssh2_knownhost_del...
- d pr extproc('libssh2_knownhost_del')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d entry likeds(libssh2_knownhost)
- * libssh2_knownhost_free
- *
- * Free an entire collection of known hosts.
- d libssh2_knownhost_free...
- d pr extproc('libssh2_knownhost_free')
- d hosts * value LIBSSH2_KNOWNHOSTS *
- * libssh2_knownhost_readline()
- *
- * Pass in a line of a file of 'type'. It makes libssh2 read this line.
- *
- * LIBSSH2_KNOWNHOST_FILE_OPENSSH is the only supported type.
- d libssh2_knownhost_readline...
- d pr extproc('libssh2_knownhost_readline')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d line * value options(*string) const char *
- d len value like(libssh2_Csize_t)
- d type value like(libssh2_Cint)
- * libssh2_knownhost_readfile
- *
- * Add hosts+key pairs from a given file.
- *
- * Returns a negative value for error or number of successfully added
- * hosts.
- *
- * This implementation currently only knows one 'type' (openssh), all
- * others are reserved for future use.
- d LIBSSH2_KNOWNHOST_FILE_OPENSSH...
- d c 1
- d libssh2_knownhost_readfile...
- d pr extproc('libssh2_knownhost_readfile')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d filename * value options(*string) const char *
- d type value like(libssh2_Cint)
- * libssh2_knownhost_writeline()
- *
- * Ask libssh2 to convert a known host to an output line for storage.
- *
- * Note that this function returns LIBSSH2_ERROR_BUFFER_TOO_SMALL if the
- * given output buffer is too small to hold the desired output.
- *
- * This implementation currently only knows one 'type' (openssh), all
- * others are reserved for future use.
- d libssh2_knownhost_writeline...
- d pr extproc(
- d 'libssh2_knownhost_writeline')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d known likeds(libssh2_knownhost)
- d buffer * value options(*string) char *
- d buflen value like(libssh2_Csize_t)
- d outlen like(libssh2_Csize_t) Written data amount
- d type value like(libssh2_Cint)
- * libssh2_knownhost_writefile
- *
- * Write hosts+key pairs to a given file.
- *
- * This implementation currently only knows one 'type' (openssh), all
- * others are reserved for future use.
- d libssh2_knownhost_writefile...
- d pr extproc(
- d 'libssh2_knownhost_writefile')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d filename * value options(*string) const char *
- d type value like(libssh2_Cint)
- * libssh2_knownhost_get()
- *
- * Traverse the internal list of known hosts. Pass NULL to 'prev' to get
- * the first one. Or pass a poiner to the previously returned one to
- * get the next.
- *
- * Returns:
- * 0 if a fine host was stored in 'store'
- * 1 if end of hosts
- * [negative] on errors
- d libssh2_knownhost_get...
- d pr extproc('libssh2_knownhost_get')
- d like(libssh2_Cint)
- d hosts * value LIBSSH2_KNOWNHOSTS *
- d store * libssh2_knownhost *
- d prev likeds(libssh2_knownhost)
- d HAVE_LIBSSH2_AGENT_API... since 1.2.2
- d c X'010202'
- d libssh2_agent_publickey...
- d ds based(######typedef######)
- d align qualified
- d magic like(libssh2_Cuint)
- d node * void *
- d blob * unsigned char *
- d blob_len like(libssh2_Csize_t)
- d comment * char *
- * libssh2_agent_init
- *
- * Init an ssh-agent handle. Returns the pointer to the handle.
- d libssh2_agent_init...
- d pr * extproc('libssh2_agent_init') LIBSSH2_AGENT *
- d session * value LIBSSH2_SESSION *
- * libssh2_agent_connect()
- *
- * Connect to an ssh-agent.
- *
- * Returns 0 if succeeded, or a negative value for error.
- d libssh2_agent_connect...
- d pr extproc('libssh2_agent_connect')
- d like(libssh2_Cint)
- d agent * value LIBSSH2_AGENT *
- * libssh2_agent_list_identities()
- *
- * Request an ssh-agent to list identities.
- *
- * Returns 0 if succeeded, or a negative value for error.
- d libssh2_agent_list_identities...
- d pr extproc(
- d 'libssh2_agent_list_identities')
- d like(libssh2_Cint)
- d agent * value LIBSSH2_AGENT *
- * libssh2_agent_get_identity()
- *
- * Traverse the internal list of public keys. Pass NULL to 'prev' to get
- * the first one. Or pass a poiner to the previously returned one to
- * get the next.
- *
- * Returns:
- * 0 if a fine public key was stored in 'store'
- * 1 if end of public keys
- * [negative] on errors
- d libssh2_agent_get_identity...
- d pr extproc('libssh2_agent_get_identity')
- d like(libssh2_Cint)
- d agent * value LIBSSH2_AGENT *
- d store * libssh2_agent_...
- d publickey *(*)
- d prev likeds(libssh2_agent_publickey)
- * libssh2_agent_userauth()
- *
- * Do publickey user authentication with the help of ssh-agent.
- *
- * Returns 0 if succeeded, or a negative value for error.
- d libssh2_agent_userauth...
- d pr extproc('libssh2_agent_userauth')
- d like(libssh2_Cint)
- d agent * value LIBSSH2_AGENT *
- d username * value options(*string) const char *
- d identity likeds(libssh2_agent_publickey)
- * libssh2_agent_disconnect()
- *
- * Close a connection to an ssh-agent.
- *
- * Returns 0 if succeeded, or a negative value for error.
- d libssh2_agent_disconnect...
- d pr extproc('libssh2_agent_disconnect')
- d like(libssh2_Cint)
- d agent * value LIBSSH2_AGENT *
- * libssh2_agent_free()
- *
- * Free an ssh-agent handle. This function also frees the internal
- * collection of public keys.
- d libssh2_agent_free...
- d pr extproc('libssh2_agent_free')
- d agent * value LIBSSH2_AGENT *
- * libssh2_keepalive_config()
- *
- * Set how often keepalive messages should be sent. WANT_REPLY
- * indicates whether the keepalive messages should request a response
- * from the server. INTERVAL is number of seconds that can pass
- * without any I/O, use 0 (the default) to disable keepalives. To
- * avoid some busy-loop corner-cases, if you specify an interval of 1
- * it will be treated as 2.
- *
- * Note that non-blocking applications are responsible for sending the
- * keepalive messages using libssh2_keepalive_send().
- d libssh2_keepalive_config...
- d pr extproc('libssh2_keepalive_config')
- d session * value LIBSSH2_SESSION *
- d want_reply value like(libssh2_Cint)
- d interval value like(libssh2_Cuint)
- * libssh2_keepalive_send()
- *
- * Send a keepalive message if needed. SECONDS_TO_NEXT indicates how
- * many seconds you can sleep after this call before you need to call
- * it again. Returns 0 on success, or LIBSSH2_ERROR_SOCKET_SEND on
- * I/O errors.
- d libssh2_keepalive_send...
- d pr extproc('libssh2_keepalive_send')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d seconds_to_next...
- d like(libssh2_Cint)
- * NOTE NOTE NOTE
- * libssh2_trace() has no function in builds that aren't built with debug
- * enabled.
- d libssh2_trace pr extproc('libssh2_trace')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d bitmask value like(libssh2_Cint)
- d LIBSSH2_TRACE_TRANS...
- d c X'0002'
- d LIBSSH2_TRACE_KEX...
- d c X'0004'
- d LIBSSH2_TRACE_AUTH...
- d c X'0008'
- d LIBSSH2_TRACE_CONN...
- d c X'0010'
- d LIBSSH2_TRACE_SCP...
- d c X'0020'
- d LIBSSH2_TRACE_SFTP...
- d c X'0040'
- d LIBSSH2_TRACE_ERROR...
- d c X'0080'
- d LIBSSH2_TRACE_PUBLICKEY...
- d c X'0100'
- d LIBSSH2_TRACE_SOCKET...
- d c X'0200'
- d libssh2_trace_handler_func...
- d s * based(######typedef######) procptr
- d libssh2_trace_sethandler...
- d pr extproc('libssh2_trace_sethandler')
- d like(libssh2_Cint)
- d session * value LIBSSH2_SESSION *
- d context * value void *
- d callback value
- d like(libssh2_trace_handler_func)
- /endif LIBSSH2_H_
|