Compare commits
549 Commits
libssh2-1.
...
libssh2-1.
Author | SHA1 | Date | |
---|---|---|---|
![]() |
5633bb4a3b | ||
![]() |
fabf1a45ee | ||
![]() |
2e352d3085 | ||
![]() |
8c9571b7ba | ||
![]() |
527c1b2def | ||
![]() |
ec934f6dab | ||
![]() |
516fa7fdd9 | ||
![]() |
3ce2628140 | ||
![]() |
ad88325b3f | ||
![]() |
2db4863e6e | ||
![]() |
691cabc048 | ||
![]() |
90b4b4073f | ||
![]() |
8ce9a66ccf | ||
![]() |
7015488150 | ||
![]() |
164838c7dd | ||
![]() |
f9b1b95059 | ||
![]() |
59207291fc | ||
![]() |
0da37e0924 | ||
![]() |
4552c73cd5 | ||
![]() |
306929ee80 | ||
![]() |
326f741a52 | ||
![]() |
aa4f861643 | ||
![]() |
fd691deb17 | ||
![]() |
20da09932e | ||
![]() |
3ab7af095a | ||
![]() |
5b1a7ec2f1 | ||
![]() |
5ee38702a0 | ||
![]() |
2165ceacd3 | ||
![]() |
121237ce2f | ||
![]() |
b3e832172b | ||
![]() |
3faa8bc940 | ||
![]() |
2f0c0cef76 | ||
![]() |
75909e05a9 | ||
![]() |
47b4e62780 | ||
![]() |
1b1ff333e4 | ||
![]() |
c1683ae92c | ||
![]() |
1b65c6ae26 | ||
![]() |
92ea3bda60 | ||
![]() |
811cce09b5 | ||
![]() |
6875285b71 | ||
![]() |
0cc14be09d | ||
![]() |
499b989d46 | ||
![]() |
fa07d9fefc | ||
![]() |
b0c32a85fc | ||
![]() |
7ed7dad3b4 | ||
![]() |
b215ec0af5 | ||
![]() |
ac6d0fb706 | ||
![]() |
e87293d480 | ||
![]() |
a3ce1073c4 | ||
![]() |
97a1881749 | ||
![]() |
80f7508d55 | ||
![]() |
e8c44e789f | ||
![]() |
ca2e81eb1f | ||
![]() |
aff9c825c8 | ||
![]() |
7899d28ecb | ||
![]() |
2f5a2ff8e6 | ||
![]() |
160453cee4 | ||
![]() |
82fa5d2167 | ||
![]() |
1c3e1c4d25 | ||
![]() |
1d2a5b8456 | ||
![]() |
1d11d02aa9 | ||
![]() |
f4ad3e0120 | ||
![]() |
772564650d | ||
![]() |
05ba8db8aa | ||
![]() |
1964ccb557 | ||
![]() |
bef0ce5392 | ||
![]() |
fb6afd01a1 | ||
![]() |
a302428335 | ||
![]() |
7ad152a6b2 | ||
![]() |
075ff19574 | ||
![]() |
16f46c1cfc | ||
![]() |
aa2fdb3e7e | ||
![]() |
8f10da89c5 | ||
![]() |
2dfa5d38cb | ||
![]() |
095e9e7b3e | ||
![]() |
588c8946fc | ||
![]() |
a6fc9aeec9 | ||
![]() |
7603c0f854 | ||
![]() |
8974dc05ae | ||
![]() |
6395a738fd | ||
![]() |
73be9fab04 | ||
![]() |
753e55ef23 | ||
![]() |
4760e4d051 | ||
![]() |
57af0da9f7 | ||
![]() |
024b5d29f5 | ||
![]() |
a0dd0c5992 | ||
![]() |
92d308c157 | ||
![]() |
4ae71b4838 | ||
![]() |
ba190d34c6 | ||
![]() |
b84f69c960 | ||
![]() |
a7aee34522 | ||
![]() |
1dc366109d | ||
![]() |
e1ea2eb7c2 | ||
![]() |
610a8ab919 | ||
![]() |
8ec21e0afe | ||
![]() |
8e0983347b | ||
![]() |
95db6cc62c | ||
![]() |
727043074a | ||
![]() |
5b4ed2717b | ||
![]() |
59f74de157 | ||
![]() |
d87562976a | ||
![]() |
a94886f157 | ||
![]() |
dec0ea9e70 | ||
![]() |
030b2d9b60 | ||
![]() |
c48840ba88 | ||
![]() |
d9cdd8c0a7 | ||
![]() |
c49061e708 | ||
![]() |
d674b1a09a | ||
![]() |
5ede32a826 | ||
![]() |
3a391f6cf2 | ||
![]() |
64063d5f0b | ||
![]() |
784db8e987 | ||
![]() |
84efbf788f | ||
![]() |
f805c2db2a | ||
![]() |
08ce6425f6 | ||
![]() |
fac9412a74 | ||
![]() |
4d15e0c9d1 | ||
![]() |
6140ec2de3 | ||
![]() |
70d6bd6c6f | ||
![]() |
98e38c4f3a | ||
![]() |
cd6d41b806 | ||
![]() |
c36f379b88 | ||
![]() |
77a9335515 | ||
![]() |
59636cc11e | ||
![]() |
0d58af6aec | ||
![]() |
c34e1d8735 | ||
![]() |
861fc75fa3 | ||
![]() |
f4d302fdfe | ||
![]() |
4faf67d3e9 | ||
![]() |
76a30f2c6f | ||
![]() |
bcd7eee1d2 | ||
![]() |
046ad88d88 | ||
![]() |
9887c01103 | ||
![]() |
822f9e8689 | ||
![]() |
3ee2aabd7a | ||
![]() |
7c49c8be58 | ||
![]() |
665d9ee885 | ||
![]() |
b3d6c6567d | ||
![]() |
7dd574c353 | ||
![]() |
018602cb34 | ||
![]() |
eec7f2fb63 | ||
![]() |
c32b0d164e | ||
![]() |
835c03e076 | ||
![]() |
6c6c43f92c | ||
![]() |
5af87e8c80 | ||
![]() |
10a65fda01 | ||
![]() |
8d9d3e0d7a | ||
![]() |
c46abb2663 | ||
![]() |
0a34fa79f0 | ||
![]() |
43001570d6 | ||
![]() |
4b878e7cf8 | ||
![]() |
ac709e0d4f | ||
![]() |
56d0877f07 | ||
![]() |
51a8335486 | ||
![]() |
2bd9418ac7 | ||
![]() |
4b8013a8a7 | ||
![]() |
697b4e8ed7 | ||
![]() |
2afa5b2dc2 | ||
![]() |
992aff7aca | ||
![]() |
ef4c8718c2 | ||
![]() |
c375e5e5ad | ||
![]() |
46be03f92b | ||
![]() |
1d83b520b4 | ||
![]() |
f9c0a4a95a | ||
![]() |
7861ae8e4e | ||
![]() |
0f0652a309 | ||
![]() |
2cc4a629ac | ||
![]() |
04f90b2265 | ||
![]() |
7dc2bfac94 | ||
![]() |
35cf08e130 | ||
![]() |
32bd0df992 | ||
![]() |
38940f45d2 | ||
![]() |
537a00ee4b | ||
![]() |
6ddcc493e8 | ||
![]() |
3496e1c2a2 | ||
![]() |
49ddf447ff | ||
![]() |
04d4bbb66b | ||
![]() |
897f8463d8 | ||
![]() |
2fd044fdf5 | ||
![]() |
20e969d2e0 | ||
![]() |
33e2bc8785 | ||
![]() |
d7e6f9cf27 | ||
![]() |
be7cee1b3e | ||
![]() |
518d25eba1 | ||
![]() |
1785d0d6f3 | ||
![]() |
31d71a94f2 | ||
![]() |
22a2de7347 | ||
![]() |
4cf935abab | ||
![]() |
cce6ebbee7 | ||
![]() |
18605cb81f | ||
![]() |
3490b3fe10 | ||
![]() |
c87a48ae4c | ||
![]() |
ab8ee8abf3 | ||
![]() |
6e40af7bea | ||
![]() |
5e46c864dc | ||
![]() |
a4fdf0de01 | ||
![]() |
2c1c751ad1 | ||
![]() |
f682684fdd | ||
![]() |
0ad1a52a09 | ||
![]() |
4e10882e06 | ||
![]() |
eeeebd02e7 | ||
![]() |
f285438022 | ||
![]() |
81912f67e7 | ||
![]() |
2996e02482 | ||
![]() |
2683fddcca | ||
![]() |
fa5d6c705d | ||
![]() |
b6c6470e7e | ||
![]() |
dceb3d1452 | ||
![]() |
86c935317c | ||
![]() |
aad74b7fa6 | ||
![]() |
0b593c8a9d | ||
![]() |
8ff3f62786 | ||
![]() |
4d7b2950d9 | ||
![]() |
18569d76de | ||
![]() |
7a088a8ab7 | ||
![]() |
d15663477b | ||
![]() |
8145f9e79c | ||
![]() |
dc747fb221 | ||
![]() |
76fd96e63e | ||
![]() |
ed526a0e24 | ||
![]() |
667f4acda6 | ||
![]() |
f3208b99ca | ||
![]() |
b702441242 | ||
![]() |
396dcedc56 | ||
![]() |
798a808a2b | ||
![]() |
c8df661129 | ||
![]() |
b3ed8e064a | ||
![]() |
ffb55aa2a3 | ||
![]() |
9251642ef3 | ||
![]() |
79b97c67c7 | ||
![]() |
b23ae2bf22 | ||
![]() |
a3f3347c12 | ||
![]() |
5184aec461 | ||
![]() |
358aa3e24b | ||
![]() |
7bbefe0660 | ||
![]() |
204100e636 | ||
![]() |
6c85370428 | ||
![]() |
23f02aad11 | ||
![]() |
eb7581e72e | ||
![]() |
a16d67e250 | ||
![]() |
ab81b75a8e | ||
![]() |
0c918ef72a | ||
![]() |
6c3f2ec815 | ||
![]() |
f1df0b7fbc | ||
![]() |
6f895e3298 | ||
![]() |
45210d8376 | ||
![]() |
6a44eff0b5 | ||
![]() |
0862a1a39a | ||
![]() |
514f4d9305 | ||
![]() |
d5d80d296a | ||
![]() |
568060d266 | ||
![]() |
6e2a0e603a | ||
![]() |
d811478071 | ||
![]() |
b979af1eee | ||
![]() |
37624b61e3 | ||
![]() |
4c26a46362 | ||
![]() |
77efca961d | ||
![]() |
c28fa65424 | ||
![]() |
03815483be | ||
![]() |
67de62d650 | ||
![]() |
cb42be1a9c | ||
![]() |
c511177d39 | ||
![]() |
d4edb0b9c3 | ||
![]() |
71fb9cc93e | ||
![]() |
5163e4ecb8 | ||
![]() |
000b0f73d0 | ||
![]() |
c5602fac58 | ||
![]() |
046ff03c3f | ||
![]() |
d06f983c9c | ||
![]() |
8620cc03f8 | ||
![]() |
21f55d0006 | ||
![]() |
88ac2dd43c | ||
![]() |
26d1698320 | ||
![]() |
7dfeadef97 | ||
![]() |
5804444936 | ||
![]() |
ee5dd3561d | ||
![]() |
ad1ec1c9e4 | ||
![]() |
28ef62be20 | ||
![]() |
1acca6e3ee | ||
![]() |
d3a0f2932b | ||
![]() |
7adc23a628 | ||
![]() |
fca949ea55 | ||
![]() |
f8b42cab86 | ||
![]() |
fea133f8d6 | ||
![]() |
9ba30d888e | ||
![]() |
5d37cd44aa | ||
![]() |
be9ee7095e | ||
![]() |
9209309bc3 | ||
![]() |
2a069503be | ||
![]() |
182108ac91 | ||
![]() |
21a01c96f8 | ||
![]() |
100059989f | ||
![]() |
13caffa00e | ||
![]() |
c3bcdd88a4 | ||
![]() |
81e63b3657 | ||
![]() |
1adcb5234f | ||
![]() |
9cc824e27b | ||
![]() |
2f9c105ec2 | ||
![]() |
8ab009c0b0 | ||
![]() |
e22cdcea77 | ||
![]() |
7f740368f4 | ||
![]() |
8b63dc9e59 | ||
![]() |
77fa740674 | ||
![]() |
32cf14b512 | ||
![]() |
44cd934fa2 | ||
![]() |
339ad5ccd3 | ||
![]() |
0ecd0eb37c | ||
![]() |
f514bcac53 | ||
![]() |
79ee2f339e | ||
![]() |
12fd204ae4 | ||
![]() |
2386a5a21c | ||
![]() |
8b7e22cb33 | ||
![]() |
1d49f1bc21 | ||
![]() |
1711917c2c | ||
![]() |
b6ed60d2cc | ||
![]() |
79acf60ae6 | ||
![]() |
7810656564 | ||
![]() |
4bc10aa728 | ||
![]() |
5512d0d593 | ||
![]() |
05f9fb878e | ||
![]() |
f314f3b5fd | ||
![]() |
eb4407975c | ||
![]() |
6d253324be | ||
![]() |
aebcc45a37 | ||
![]() |
1decccbb52 | ||
![]() |
4c09324b02 | ||
![]() |
6d4b1bbb45 | ||
![]() |
5456163507 | ||
![]() |
7301036421 | ||
![]() |
fa4017c613 | ||
![]() |
2e3f380ff2 | ||
![]() |
6c3c3e1b49 | ||
![]() |
55ede3b41b | ||
![]() |
d00283927f | ||
![]() |
9ea5b0625e | ||
![]() |
1b1b4ac387 | ||
![]() |
9abf81de97 | ||
![]() |
c585828d2b | ||
![]() |
e54786cf2e | ||
![]() |
4cfeade243 | ||
![]() |
60ff0a2ade | ||
![]() |
64c97765a5 | ||
![]() |
ab66ff488b | ||
![]() |
0d331aade1 | ||
![]() |
69520e1564 | ||
![]() |
f87f4ab836 | ||
![]() |
b3556c2e0c | ||
![]() |
1f406feaa4 | ||
![]() |
c0436fc602 | ||
![]() |
0034a83e4c | ||
![]() |
f0f4ba92f0 | ||
![]() |
c29ba827e4 | ||
![]() |
a03e1b0457 | ||
![]() |
d4a768af4e | ||
![]() |
d377c3065a | ||
![]() |
51fcb11d60 | ||
![]() |
8bbc109e52 | ||
![]() |
0ef84144ac | ||
![]() |
ef27023eb9 | ||
![]() |
a9621548f8 | ||
![]() |
a925bdd5bb | ||
![]() |
3420e9858c | ||
![]() |
2de339b2f7 | ||
![]() |
c46cbd46e2 | ||
![]() |
16af813b81 | ||
![]() |
a2157c8391 | ||
![]() |
942a40b482 | ||
![]() |
ef096220ce | ||
![]() |
e4232e531b | ||
![]() |
cdc1366b2c | ||
![]() |
3e1a95392e | ||
![]() |
b4f12e153a | ||
![]() |
bd5519c7a2 | ||
![]() |
05b1bb3cd3 | ||
![]() |
dea503df73 | ||
![]() |
c5609acb17 | ||
![]() |
37c08983a3 | ||
![]() |
72ae0866cb | ||
![]() |
2149244cfe | ||
![]() |
a491017f5a | ||
![]() |
ec699ef684 | ||
![]() |
514104b37d | ||
![]() |
4d13c6e59b | ||
![]() |
72a28f6b16 | ||
![]() |
c889058cb3 | ||
![]() |
69c876e210 | ||
![]() |
10f5c70ac0 | ||
![]() |
ea914c8b72 | ||
![]() |
64a6c255ec | ||
![]() |
e09d6ac653 | ||
![]() |
91841731af | ||
![]() |
a190437c4a | ||
![]() |
68a900d27a | ||
![]() |
e4b7baa885 | ||
![]() |
2622bbaf33 | ||
![]() |
d3dbe4c81e | ||
![]() |
095ccbf825 | ||
![]() |
8eafded280 | ||
![]() |
6df87e64b7 | ||
![]() |
3ddac8ac66 | ||
![]() |
6c543545fe | ||
![]() |
abd9bd0bbe | ||
![]() |
5dd4005ace | ||
![]() |
8f102b8f56 | ||
![]() |
7d71f92a9c | ||
![]() |
f6fab0d9ea | ||
![]() |
cc7f90f1d4 | ||
![]() |
6d55714ab5 | ||
![]() |
6b23f640f8 | ||
![]() |
2cb8866f0a | ||
![]() |
3b3e13366e | ||
![]() |
9f4292433a | ||
![]() |
f077984394 | ||
![]() |
44eba0c993 | ||
![]() |
474e38119b | ||
![]() |
7f27b0822d | ||
![]() |
e3d8c1cfed | ||
![]() |
11a114ee7c | ||
![]() |
e48907ee05 | ||
![]() |
3f6bc287f9 | ||
![]() |
e84fe88526 | ||
![]() |
73e37b3b49 | ||
![]() |
7926c9cfaa | ||
![]() |
63457dfa6c | ||
![]() |
d00e97a7f1 | ||
![]() |
8436e45ea6 | ||
![]() |
0b6e37872d | ||
![]() |
1b3b7b2214 | ||
![]() |
6a249d7b6c | ||
![]() |
87e32272f9 | ||
![]() |
bd0505d6b9 | ||
![]() |
f70dbfa3e6 | ||
![]() |
a2452d7eee | ||
![]() |
bbb2f29037 | ||
![]() |
3138b5891f | ||
![]() |
c573af83de | ||
![]() |
ea8babf6d1 | ||
![]() |
db26c4eace | ||
![]() |
7b351eed36 | ||
![]() |
58abc7e30b | ||
![]() |
0a3b350012 | ||
![]() |
b5e358618b | ||
![]() |
dd81bda112 | ||
![]() |
12433b4511 | ||
![]() |
39cbd17e19 | ||
![]() |
1f91ab049f | ||
![]() |
f2e5b49904 | ||
![]() |
b4c0821332 | ||
![]() |
70b199f476 | ||
![]() |
d142f385da | ||
![]() |
1a491c6f00 | ||
![]() |
1256c61815 | ||
![]() |
95f559a926 | ||
![]() |
052a68db30 | ||
![]() |
1aba38cd7d | ||
![]() |
7317edab61 | ||
![]() |
e642e2c202 | ||
![]() |
f07cf3afd3 | ||
![]() |
1e350754f6 | ||
![]() |
55031fa320 | ||
![]() |
355fbf4d5b | ||
![]() |
74c63852d7 | ||
![]() |
ebbd7c879b | ||
![]() |
b78f854d8b | ||
![]() |
1f0d47fa92 | ||
![]() |
463e09e55f | ||
![]() |
82bf39dbfa | ||
![]() |
e5f170bae2 | ||
![]() |
fc60563840 | ||
![]() |
b38b4fb859 | ||
![]() |
3182045c2d | ||
![]() |
60d73d5663 | ||
![]() |
1e80194b97 | ||
![]() |
0c13f7beda | ||
![]() |
b859f4d9d2 | ||
![]() |
13092c5a5e | ||
![]() |
22b73235d3 | ||
![]() |
55034294e8 | ||
![]() |
5e80055d22 | ||
![]() |
11ca8d5583 | ||
![]() |
9162fd7e61 | ||
![]() |
7208e8d0d9 | ||
![]() |
e1bb074287 | ||
![]() |
e887ffca4c | ||
![]() |
65d1cb8107 | ||
![]() |
4ed82f0e78 | ||
![]() |
3cc2f143c1 | ||
![]() |
683aa0f6b5 | ||
![]() |
7a9d36903a | ||
![]() |
c2375dbfa4 | ||
![]() |
906a7d8866 | ||
![]() |
1418993a0f | ||
![]() |
c4b7f0394b | ||
![]() |
9e84b999a5 | ||
![]() |
3fda91d725 | ||
![]() |
7c32c84d0e | ||
![]() |
766127ad57 | ||
![]() |
a9e7f87e31 | ||
![]() |
a04a0b6c69 | ||
![]() |
1f8d58a4ce | ||
![]() |
4b482eddbe | ||
![]() |
05eb612f8e | ||
![]() |
d48ee98ecf | ||
![]() |
536443246e | ||
![]() |
b728b1018f | ||
![]() |
3f5a6662d0 | ||
![]() |
33f4e0f250 | ||
![]() |
8dabb1c5eb | ||
![]() |
0d6aaa1f56 | ||
![]() |
00fac145ba | ||
![]() |
f65f71a156 | ||
![]() |
3142e8df7e | ||
![]() |
bffefb12ea | ||
![]() |
feadd5f321 | ||
![]() |
7c139633a1 | ||
![]() |
692401633a | ||
![]() |
5bb1fb5cbc | ||
![]() |
5e5ead00b4 | ||
![]() |
06278728e2 | ||
![]() |
0357befa42 | ||
![]() |
85198c1cdb | ||
![]() |
face4750ca | ||
![]() |
a1365916c7 | ||
![]() |
f64a84a909 | ||
![]() |
fba3877ed8 | ||
![]() |
f1e010f5d4 | ||
![]() |
9e96acf86e | ||
![]() |
1a157d27cc | ||
![]() |
b3418bb1eb | ||
![]() |
08be841b4d | ||
![]() |
e39128df52 | ||
![]() |
5c6b8166c7 | ||
![]() |
dcb9625473 | ||
![]() |
c1b687c9e4 | ||
![]() |
13e920d4ef | ||
![]() |
314e61e545 | ||
![]() |
13c16db3bc | ||
![]() |
82c3f0ba72 | ||
![]() |
9e099fb88a | ||
![]() |
415efe10ac | ||
![]() |
4b1cb4e95e | ||
![]() |
d8b6f3c7b8 | ||
![]() |
a871f0b214 | ||
![]() |
08cad8e14c | ||
![]() |
46178378f2 | ||
![]() |
28b179ecf2 | ||
![]() |
7b4d6b2868 | ||
![]() |
fbe4737719 | ||
![]() |
ce4ad0d086 |
28
.cvsignore
28
.cvsignore
@@ -1,28 +0,0 @@
|
|||||||
.deps
|
|
||||||
.libs
|
|
||||||
*.lib
|
|
||||||
*.pdb
|
|
||||||
*.dll
|
|
||||||
*.exe
|
|
||||||
*.obj
|
|
||||||
.*.swp
|
|
||||||
Debug
|
|
||||||
Release
|
|
||||||
*.exp
|
|
||||||
Makefile
|
|
||||||
Makefile.in
|
|
||||||
aclocal.m4
|
|
||||||
autom4te.cache
|
|
||||||
config.guess
|
|
||||||
config.log
|
|
||||||
config.status
|
|
||||||
config.sub
|
|
||||||
configure
|
|
||||||
depcomp
|
|
||||||
libtool
|
|
||||||
ltmain.sh
|
|
||||||
missing
|
|
||||||
ssh2_sample
|
|
||||||
libssh2-*.tar.gz
|
|
||||||
INSTALL
|
|
||||||
install-sh
|
|
11
.cvsusers
11
.cvsusers
@@ -1,11 +0,0 @@
|
|||||||
jas4711:Simon Josefsson <simon@josefsson.org>
|
|
||||||
bagder:Daniel Stenberg
|
|
||||||
sarag:Sara Golemon <pollita@libssh2.org>
|
|
||||||
gusarov:Mikhail Gusarov <dottedmag@dottedmag.net>
|
|
||||||
wez:Wez Furlong
|
|
||||||
edink:Edink Kadribasic
|
|
||||||
jehousley: James Housley
|
|
||||||
gknauf: Guenter Knauf
|
|
||||||
dfandrich: Dan Fandrich
|
|
||||||
yangtse: Yang Tse
|
|
||||||
thomaspu: Paul Thomas
|
|
2
.gitattribute
Normal file
2
.gitattribute
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
win32/msvcproj.head -crlf
|
||||||
|
win32/msvcproj.foot -crlf
|
3
.gitignore
vendored
3
.gitignore
vendored
@@ -30,3 +30,6 @@ install-sh
|
|||||||
*.lo
|
*.lo
|
||||||
*.la
|
*.la
|
||||||
mkinstalldirs
|
mkinstalldirs
|
||||||
|
tags
|
||||||
|
libssh2.pc
|
||||||
|
TAGS
|
||||||
|
7
AUTHORS
7
AUTHORS
@@ -6,6 +6,7 @@
|
|||||||
Adam Gobiowski
|
Adam Gobiowski
|
||||||
Alexander Holyapin
|
Alexander Holyapin
|
||||||
Alexander Lamaison
|
Alexander Lamaison
|
||||||
|
Ben Kibbey
|
||||||
Bjorn Stenborg
|
Bjorn Stenborg
|
||||||
Carlo Bramini
|
Carlo Bramini
|
||||||
Dan Casey
|
Dan Casey
|
||||||
@@ -15,15 +16,19 @@ David J Sullivan
|
|||||||
David Robins
|
David Robins
|
||||||
Edink Kadribasic
|
Edink Kadribasic
|
||||||
Erik Brossler
|
Erik Brossler
|
||||||
|
Francois Dupoux
|
||||||
Guenter Knauf
|
Guenter Knauf
|
||||||
Heiner Steven
|
Heiner Steven
|
||||||
James Housleys
|
James Housleys
|
||||||
Jean-Louis Charton
|
Jean-Louis Charton
|
||||||
|
Jussi Mononen
|
||||||
|
Mark McPherson
|
||||||
Markus Moeller
|
Markus Moeller
|
||||||
Mike Protts
|
Mike Protts
|
||||||
Mikhail Gusarov
|
Mikhail Gusarov
|
||||||
Neil Gierman
|
Neil Gierman
|
||||||
Olivier Hervieu
|
Olivier Hervieu
|
||||||
|
Paul Veldkamp
|
||||||
Peter O'Gorman
|
Peter O'Gorman
|
||||||
Peter Stuge
|
Peter Stuge
|
||||||
Romain Bondue
|
Romain Bondue
|
||||||
@@ -34,6 +39,8 @@ Selcuk Gueney
|
|||||||
Simon Hart
|
Simon Hart
|
||||||
Simon Josefsson
|
Simon Josefsson
|
||||||
Steven Ayre
|
Steven Ayre
|
||||||
|
Steven Van Ingelgem
|
||||||
|
Tor Arntsen
|
||||||
Vincent Jaulin
|
Vincent Jaulin
|
||||||
Vlad Grachov
|
Vlad Grachov
|
||||||
Wez Furlong
|
Wez Furlong
|
||||||
|
3
COPYING
3
COPYING
@@ -1,6 +1,9 @@
|
|||||||
/* Copyright (c) 2004-2007 Sara Golemon <sarag@libssh2.org>
|
/* Copyright (c) 2004-2007 Sara Golemon <sarag@libssh2.org>
|
||||||
|
* Copyright (c) 2005,2006 Mikhail Gusarov <dottedmag@dottedmag.net>
|
||||||
* Copyright (c) 2006-2007 The Written Word, Inc.
|
* Copyright (c) 2006-2007 The Written Word, Inc.
|
||||||
|
* Copyright (c) 2007 Eli Fant <elifantu@mail.ru>
|
||||||
* Copyright (c) 2009 Daniel Stenberg
|
* Copyright (c) 2009 Daniel Stenberg
|
||||||
|
* Copyright (C) 2008, 2009 Simon Josefsson
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms,
|
* Redistribution and use in source and binary forms,
|
||||||
|
11
HACKING
11
HACKING
@@ -9,14 +9,5 @@ libssh2 source code style guide:
|
|||||||
go_nuts();
|
go_nuts();
|
||||||
}
|
}
|
||||||
|
|
||||||
- write both braces on the else line:
|
|
||||||
|
|
||||||
if (banana) {
|
|
||||||
go_nuts();
|
|
||||||
} else {
|
|
||||||
stay_calm();
|
|
||||||
}
|
|
||||||
|
|
||||||
- use braces even for single-statement blocks
|
|
||||||
|
|
||||||
- keep source lines shorter than 80 columns
|
- keep source lines shorter than 80 columns
|
||||||
|
- See libssh2-style.el for how to achieve this within Emacs
|
||||||
|
103
Makefile.am
103
Makefile.am
@@ -2,6 +2,9 @@ AUTOMAKE_OPTIONS = foreign nostdinc
|
|||||||
|
|
||||||
SUBDIRS = src example tests docs
|
SUBDIRS = src example tests docs
|
||||||
|
|
||||||
|
pkgconfigdir = $(libdir)/pkgconfig
|
||||||
|
pkgconfig_DATA = libssh2.pc
|
||||||
|
|
||||||
include_HEADERS = \
|
include_HEADERS = \
|
||||||
include/libssh2.h \
|
include/libssh2.h \
|
||||||
include/libssh2_publickey.h \
|
include/libssh2_publickey.h \
|
||||||
@@ -16,23 +19,28 @@ NETWAREFILES = nw/keepscreen.c \
|
|||||||
DSP = win32/libssh2.dsp
|
DSP = win32/libssh2.dsp
|
||||||
VCPROJ = win32/libssh2.vcproj
|
VCPROJ = win32/libssh2.vcproj
|
||||||
|
|
||||||
#Need to include $(VCPROJ) to CLEANFILES and WIN32FILES when I get a proper vc8proj.head|foot
|
DISTCLEANFILES = $(DSP)
|
||||||
CLEANFILES = $(DSP)
|
|
||||||
|
VMSFILES = vms/libssh2_make_example.dcl vms/libssh2_make_help.dcl \
|
||||||
|
vms/libssh2_make_kit.dcl vms/libssh2_make_lib.dcl vms/man2help.c \
|
||||||
|
vms/readme.vms vms/libssh2_config.h
|
||||||
|
|
||||||
|
|
||||||
WIN32FILES = win32/Makefile.win32 win32/libssh2.dsw \
|
WIN32FILES = win32/Makefile.win32 win32/libssh2.dsw \
|
||||||
win32/config.mk win32/Makefile win32/test/Makefile.win32 \
|
win32/config.mk win32/Makefile win32/test/Makefile.win32 \
|
||||||
win32/libssh2_config.h win32/tests.dsp win32/rules.mk $(DSP) \
|
win32/libssh2_config.h win32/tests.dsp win32/rules.mk $(DSP) \
|
||||||
win32/msvcproj.head win32/msvcproj.foot
|
win32/msvcproj.head win32/msvcproj.foot win32/libssh2.rc \
|
||||||
|
win32/Makefile.Watcom
|
||||||
|
|
||||||
EXTRA_DIST = $(WIN32FILES) buildconf $(NETWAREFILES) get_ver.awk HACKING \
|
EXTRA_DIST = $(WIN32FILES) buildconf $(NETWAREFILES) get_ver.awk HACKING \
|
||||||
maketgz NMakefile TODO RELEASE-NOTES
|
maketgz NMakefile TODO RELEASE-NOTES libssh2.pc.in $(VMSFILES)
|
||||||
|
|
||||||
ACLOCAL_AMFLAGS = -I m4
|
ACLOCAL_AMFLAGS = -I m4
|
||||||
|
|
||||||
.PHONY: ChangeLog
|
.PHONY: ChangeLog
|
||||||
ChangeLog:
|
ChangeLog:
|
||||||
echo "see NEWS" > ./ChangeLog
|
echo "see NEWS" > ./ChangeLog
|
||||||
CLEANFILES += ChangeLog
|
DISTCLEANFILES += ChangeLog
|
||||||
|
|
||||||
dist-hook:
|
dist-hook:
|
||||||
rm -rf $(top_builddir)/tests/log
|
rm -rf $(top_builddir)/tests/log
|
||||||
@@ -73,55 +81,54 @@ include Makefile.inc
|
|||||||
WIN32SOURCES = $(CSOURCES)
|
WIN32SOURCES = $(CSOURCES)
|
||||||
WIN32HEADERS = $(HHEADERS) libssh2_config.h
|
WIN32HEADERS = $(HHEADERS) libssh2_config.h
|
||||||
|
|
||||||
DSPOUT = | awk '{printf("%s\r\n", $$0)}' >> $(DSP)
|
|
||||||
VCPROJOUT = | awk '{printf("%s\r\n", $$0)}' >> $(VCPROJ)
|
|
||||||
|
|
||||||
$(DSP): win32/msvcproj.head win32/msvcproj.foot Makefile.am
|
$(DSP): win32/msvcproj.head win32/msvcproj.foot Makefile.am
|
||||||
echo "creating $(DSP)"
|
echo "creating $(DSP)"
|
||||||
@(cp $(srcdir)/win32/msvcproj.head $(DSP); \
|
@( (cat $(srcdir)/win32/msvcproj.head; \
|
||||||
echo "# Begin Group \"Source Files\"" $(DSPOUT); \
|
echo "# Begin Group \"Source Files\""; \
|
||||||
echo "" $(DSPOUT); \
|
echo ""; \
|
||||||
echo "# PROP Default_Filter \"cpp;c;cxx\"" $(DSPOUT); \
|
echo "# PROP Default_Filter \"cpp;c;cxx\""; \
|
||||||
win32_srcs='$(WIN32SOURCES)'; \
|
win32_srcs='$(WIN32SOURCES)'; \
|
||||||
sorted_srcs=`for file in $$win32_srcs; do echo $$file; done | sort`; \
|
sorted_srcs=`for file in $$win32_srcs; do echo $$file; done | sort`; \
|
||||||
for file in $$sorted_srcs; do \
|
for file in $$sorted_srcs; do \
|
||||||
echo "# Begin Source File" $(DSPOUT); \
|
echo "# Begin Source File"; \
|
||||||
echo "" $(DSPOUT); \
|
echo ""; \
|
||||||
echo "SOURCE=..\\src\\"$$file $(DSPOUT); \
|
echo "SOURCE=..\\src\\"$$file; \
|
||||||
echo "# End Source File" $(DSPOUT); \
|
echo "# End Source File"; \
|
||||||
done; \
|
done; \
|
||||||
echo "# End Group" $(DSPOUT); \
|
echo "# End Group"; \
|
||||||
echo "# Begin Group \"Header Files\"" $(DSPOUT); \
|
echo "# Begin Group \"Header Files\""; \
|
||||||
echo "" $(DSPOUT); \
|
echo ""; \
|
||||||
echo "# PROP Default_Filter \"h;hpp;hxx\"" $(DSPOUT); \
|
echo "# PROP Default_Filter \"h;hpp;hxx\""; \
|
||||||
win32_hdrs='$(WIN32HEADERS)'; \
|
win32_hdrs='$(WIN32HEADERS)'; \
|
||||||
sorted_hdrs=`for file in $$win32_hdrs; do echo $$file; done | sort`; \
|
sorted_hdrs=`for file in $$win32_hdrs; do echo $$file; done | sort`; \
|
||||||
for file in $$sorted_hdrs; do \
|
for file in $$sorted_hdrs; do \
|
||||||
echo "# Begin Source File" $(DSPOUT); \
|
echo "# Begin Source File"; \
|
||||||
echo "" $(DSPOUT); \
|
echo ""; \
|
||||||
if [ "$$file" == "libssh2_config.h" ]; \
|
if [ "$$file" == "libssh2_config.h" ]; \
|
||||||
then \
|
then \
|
||||||
echo "SOURCE=.\\"$$file $(DSPOUT); \
|
echo "SOURCE=.\\"$$file; \
|
||||||
else \
|
else \
|
||||||
echo "SOURCE=..\\src\\"$$file $(DSPOUT); \
|
echo "SOURCE=..\\src\\"$$file; \
|
||||||
fi; \
|
fi; \
|
||||||
echo "# End Source File" $(DSPOUT); \
|
echo "# End Source File"; \
|
||||||
done; \
|
done; \
|
||||||
echo "# End Group" $(DSPOUT); \
|
echo "# End Group"; \
|
||||||
cat $(srcdir)/win32/msvcproj.foot $(DSPOUT) )
|
cat $(srcdir)/win32/msvcproj.foot) | \
|
||||||
|
awk '{printf("%s\r\n", gensub("\r", "", "g"))}' > $@ )
|
||||||
|
|
||||||
$(VCPROJ): win32/vc8proj.head win32/vc8proj.foot Makefile.am
|
$(VCPROJ): win32/vc8proj.head win32/vc8proj.foot Makefile.am
|
||||||
echo "creating $(VCPROJ)"
|
echo "creating $(VCPROJ)"
|
||||||
@(cp $(srcdir)/vc8proj.head $(VCPROJ); \
|
@( (cat $(srcdir)/vc8proj.head; \
|
||||||
win32_srcs='$(WIN32SOURCES)'; \
|
win32_srcs='$(WIN32SOURCES)'; \
|
||||||
sorted_srcs=`for file in $$win32_srcs; do echo $$file; done | sort`; \
|
sorted_srcs=`for file in $$win32_srcs; do echo $$file; done | sort`; \
|
||||||
for file in $$sorted_srcs; do \
|
for file in $$sorted_srcs; do \
|
||||||
echo "<File RelativePath=\""..\src\$$file"\"></File>" $(VCPROJOUT); \
|
echo "<File RelativePath=\""..\src\$$file"\"></File>"; \
|
||||||
done; \
|
done; \
|
||||||
echo "</Filter><Filter Name=\"Header Files\">" $(VCPROJOUT); \
|
echo "</Filter><Filter Name=\"Header Files\">"; \
|
||||||
win32_hdrs='$(WIN32HEADERS)'; \
|
win32_hdrs='$(WIN32HEADERS)'; \
|
||||||
sorted_hdrs=`for file in $$win32_hdrs; do echo $$file; done | sort`; \
|
sorted_hdrs=`for file in $$win32_hdrs; do echo $$file; done | sort`; \
|
||||||
for file in $$sorted_hdrs; do \
|
for file in $$sorted_hdrs; do \
|
||||||
echo "<File RelativePath=\""..\src\$$file"\"></File>" $(VCPROJOUT); \
|
echo "<File RelativePath=\""..\src\$$file"\"></File>"; \
|
||||||
done; \
|
done; \
|
||||||
cat $(srcdir)/vc8proj.foot $(VCPROJOUT) )
|
cat $(srcdir)/vc8proj.foot) | \
|
||||||
|
awk '{printf("%s\r\n", gensub("\r", "", "g"))}' > $@ )
|
||||||
|
12
Makefile.inc
12
Makefile.inc
@@ -1,11 +1,7 @@
|
|||||||
CSOURCES = channel.c comp.c crypt.c hostkey.c kex.c mac.c misc.c \
|
CSOURCES = channel.c comp.c crypt.c hostkey.c kex.c mac.c misc.c \
|
||||||
packet.c publickey.c scp.c session.c sftp.c userauth.c transport.c \
|
packet.c publickey.c scp.c session.c sftp.c userauth.c transport.c \
|
||||||
version.c knownhost.c
|
version.c knownhost.c agent.c openssl.c libgcrypt.c pem.c keepalive.c \
|
||||||
|
global.c
|
||||||
|
|
||||||
if LIBGCRYPT
|
HHEADERS = libssh2_priv.h openssl.h libgcrypt.h transport.h channel.h \
|
||||||
CSOURCES += libgcrypt.c pem.c
|
comp.h mac.h misc.h packet.h userauth.h session.h sftp.h crypto.h
|
||||||
else
|
|
||||||
CSOURCES += openssl.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
HHEADERS = libssh2_priv.h openssl.h libgcrypt.h transport.h channel.h comp.h mac.h misc.h
|
|
||||||
|
613
NEWS
613
NEWS
@@ -1,612 +1,3 @@
|
|||||||
Version 1.2 (August 10, 2009)
|
The old NEWS file.
|
||||||
-----------------------------
|
|
||||||
|
|
||||||
* (August 02 2009) Alexander Lamaison:
|
NEWS is now generated from git and put into the release tarballs.
|
||||||
|
|
||||||
- changed _libssh2_rsa_new_private and _libssh2_rsa_new_private so that they
|
|
||||||
no longer use the OpenSSL functions that take a FILE* argument. Passing
|
|
||||||
CRT-created objects across a DLL boundary causes crashes on Windows of the
|
|
||||||
DLL and the client aren't linked to the exact same verison of the CRT. Now
|
|
||||||
we pass the keys as strings to avoid this issue.
|
|
||||||
|
|
||||||
* (May 29 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
- Updated the knownhost API and there are now 9 functions, and all of them
|
|
||||||
have man pages. The libssh2.h now defines HAVE_LIBSSH2_KNOWNHOST_API to
|
|
||||||
ease things for applications to check for the correct release before trying
|
|
||||||
to use it.
|
|
||||||
|
|
||||||
* (May 23 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
- Anonymous bug report #2795816 revealed that doing subsequent
|
|
||||||
libssh2_sftp_init() calls on the same session failed.
|
|
||||||
|
|
||||||
* (May 20 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
- made libssh2_sftp_write() properly deal with huge/any sized input buffers.
|
|
||||||
|
|
||||||
- fixed libssh2_channel_write_ex() to return the correct return code, and
|
|
||||||
deal with sending off huge buffers better
|
|
||||||
|
|
||||||
* (May 7 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
- linked list code. I got a bit tired of the fact that we don't have any
|
|
||||||
generic linked-list functions within libssh2 so I wrote up the first embryo
|
|
||||||
for one that I use for this new functionality. The plan would then be to
|
|
||||||
move all existing code that uses linked lists to use this new set.
|
|
||||||
|
|
||||||
- base64 encode. I had to add a base64 encoding function which was missing
|
|
||||||
in the code base so it helps to "bloat" my patch.
|
|
||||||
|
|
||||||
- The knownhost API is currently:
|
|
||||||
|
|
||||||
_init() - init a bundle of known hosts
|
|
||||||
_add() - add a known host
|
|
||||||
_del() - delete a known host
|
|
||||||
_free() - free an entire bundle of known hosts
|
|
||||||
_check() - check if a host+key is present in the bundle
|
|
||||||
|
|
||||||
The convenience function:
|
|
||||||
|
|
||||||
_parsefile() - reads a ~/.ssh/known_hosts file and add all entries to the
|
|
||||||
given bundle
|
|
||||||
|
|
||||||
- there's no docs other than some comments in the code/headers yet
|
|
||||||
|
|
||||||
- the patch includes changes to example/simple/ssh2_exec.c that makes use of
|
|
||||||
a few of these functions. Using that I've verified that the functions in
|
|
||||||
fact can verify my localhost's key agains my ~/.ssh/known_hosts file
|
|
||||||
|
|
||||||
* (Apr 30 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
Markus posted a bug report about a bad 0-return from libssh2_channel_read:
|
|
||||||
http://libssh2.haxx.se/mail/libssh2-devel-archive-2009-04/0076.shtml
|
|
||||||
|
|
||||||
And it was indeed a bad loop that terminated too early due to a receveived
|
|
||||||
close packet.
|
|
||||||
|
|
||||||
* (Apr 14 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
libssh2_poll() and libssh2_poll_channel_read() are now considered and
|
|
||||||
documented deprecated and they will be removed at next soname bump. It also
|
|
||||||
saves us from fixing some rather quirky bugs in libssh2_poll()...
|
|
||||||
|
|
||||||
|
|
||||||
Version 1.1 (April 2, 2009)
|
|
||||||
---------------------------
|
|
||||||
|
|
||||||
- (Mar 28 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
Jean-Louis Charton found a memory leak in
|
|
||||||
libssh2_userauth_hostbased_fromfile_ex()
|
|
||||||
|
|
||||||
- (Mar 25 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
* Renamed the functions in src/transport.c to be _libssh2_transport_ prefixed
|
|
||||||
and introduced a transport.h header.
|
|
||||||
|
|
||||||
* Fixed the blocking mode to only change behavior not the actual underlying
|
|
||||||
socket mode so we now always work with non-blocking sockets. This also
|
|
||||||
introduces a new rule of thumb in libssh2 code: we don't call the
|
|
||||||
external function calls internally. We use the internal (non-blocking)
|
|
||||||
ones!
|
|
||||||
|
|
||||||
* libssh2_channel_receive_window_adjust2 was added and
|
|
||||||
libssh2_channel_receive_window_adjust is now deprecated
|
|
||||||
|
|
||||||
* Introduced "local" header files with prototypes etc for different parts
|
|
||||||
instead of cramming everything into libssh2_priv.h. channel.h is the
|
|
||||||
first.
|
|
||||||
|
|
||||||
- (Mar 19 2009) Daniel Stenberg: based on a patch by "E L" we now use errno
|
|
||||||
properly after recv() and send() calls (that internally are now known as
|
|
||||||
_libssh2_recv() and _libssh2_send()) so that the API and more works fine on
|
|
||||||
windows too!
|
|
||||||
|
|
||||||
- (Mar 17 2009) Simon Josefsson:
|
|
||||||
|
|
||||||
Added a Libtool -export-symbols-regex flag to reduce the number of
|
|
||||||
exported symbols in shared libraries. Reported by Mikhail Gusarov.
|
|
||||||
|
|
||||||
- (Mar 16 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
I renamed a few man pages to match the exact name of the functions they
|
|
||||||
describe. I also added template versions for the 13 functions that
|
|
||||||
previously lacked man pages. While these don't contain any docs just yet, it
|
|
||||||
will now be easier to add the info as the foundation is there!
|
|
||||||
|
|
||||||
- (Mar 15 2009) Daniel Stenberg:
|
|
||||||
|
|
||||||
* libssh2_channel_read_ex() was simplified and enhanced. It now adjusts the
|
|
||||||
window less frequent and uses much larger window that now allows MUCH
|
|
||||||
faster transfers.
|
|
||||||
|
|
||||||
* SCP send/recv now allow file names with whitespaces etc, thanks to a patch
|
|
||||||
by Heiner Steven
|
|
||||||
|
|
||||||
- (Mar 13 2009) Daniel Stenberg: Cleanups, that do seem to have boosted SFTP
|
|
||||||
download performance up to 300% in some tests:
|
|
||||||
|
|
||||||
* cut off "_ex" from several internal function names
|
|
||||||
|
|
||||||
* corrected some log outputs
|
|
||||||
|
|
||||||
* simplified libssh2_channel_read_ex() and made it much faster in the process
|
|
||||||
|
|
||||||
* cut out {{{ and }}} comments that were incorrect anyway
|
|
||||||
|
|
||||||
* fixed sftp_packet_ask() to return the correct packet by using memcmp() and
|
|
||||||
not strncmp()
|
|
||||||
|
|
||||||
* fixed mkdir()'s wait for packet to use the correct request_id - it
|
|
||||||
semi-worked previously because strncmp() in sftp_packet_ask() made it
|
|
||||||
match far too easily.
|
|
||||||
|
|
||||||
* took away the polling functionality from sftp_packet_ask() since it wasn't
|
|
||||||
used
|
|
||||||
|
|
||||||
- (Mar 7 2009) Olivier Hervieu pointed out a flaw in the
|
|
||||||
libssh2_channel_x11_req_ex() function that made it produce a crappy random
|
|
||||||
chunk of data. Peter Stuge improved the fix to not do out-of-boundary
|
|
||||||
writes. I (Daniel Stenberg) replaced the snprintf() with a plain sprintf()
|
|
||||||
since the size argument wasn't adding anything anyway.
|
|
||||||
|
|
||||||
- (Feb 23 2009) Added libssh2_version()
|
|
||||||
|
|
||||||
- (Feb 20 2009) libssh2_channel_direct_tcpip_ex() bug #1902169 fixed, which
|
|
||||||
caused it to fail when called a second time.
|
|
||||||
|
|
||||||
- (Feb 12 2009) Romain Bondue extended Markus Moeller fix from Feb 8, based on
|
|
||||||
a previous (uncommitted) patch by Erik Brossler. It improves
|
|
||||||
libssh2_channel_write_ex in blocking situations when the socket is set non-
|
|
||||||
blocking.
|
|
||||||
|
|
||||||
- (Feb 8 2009) Markus Moeller fixed a flaw in libssh2_channel_write_ex() that
|
|
||||||
would occur on EAGAIN situations.
|
|
||||||
|
|
||||||
Version 1.0 (December 26 2008)
|
|
||||||
------------------------------
|
|
||||||
|
|
||||||
- (Dec 20 2008) Based on Alexander Lamaison's patch, there's now a new
|
|
||||||
function called libssh2_sftp_tell64() that returns the 64 bit file offset,
|
|
||||||
as the existing libssh2_sftp_tell() only returns a size_t.
|
|
||||||
|
|
||||||
- (Dec 18 2008) Markus Moeller fixed the issue also reported by Alexander
|
|
||||||
Lamaison which caused SFTP reads with large buffers to fail.
|
|
||||||
|
|
||||||
- Several flaws were fixed that prevented at least SFTP to work reliably
|
|
||||||
|
|
||||||
- Vlad Grachov brought the new function called
|
|
||||||
libssh2_session_block_directions() which returns a bitmask for what
|
|
||||||
directions the connection blocks. It is to be used applications that use
|
|
||||||
non-blocking sockets and when a libssh2 function returns
|
|
||||||
LIBSSH2_ERROR_EAGAIN this function can be used to figure out in which
|
|
||||||
direction the socket would block and thus it can wait for the socket to
|
|
||||||
again be ready for communication in that direction before it calls libssh2
|
|
||||||
again.
|
|
||||||
|
|
||||||
- Vincent Jaulin brought the new libssh2_channel_request_pty_size_ex()
|
|
||||||
function.
|
|
||||||
|
|
||||||
- Carlo Bramini fixed the build for msys+mingw. Bug #1943976.
|
|
||||||
|
|
||||||
- Neil Gierman provided improved Visual Studio 2008 code in bug #1946268
|
|
||||||
|
|
||||||
- Bug #1862727 fixed libssh2_poll() to work on windows (by defining
|
|
||||||
HAVE_SELECT).
|
|
||||||
|
|
||||||
- Based on bug #1815692, we introduce libssh2_sftp_seek64() that allows
|
|
||||||
seeking beyond the 2GB margin even on 32bit machines.
|
|
||||||
|
|
||||||
- Based on a patch in bug #1878059 by Steven Ayre libssh2 now parses >2GB file
|
|
||||||
sizes when downloading SCP files.
|
|
||||||
|
|
||||||
- Bug #2064371 pointed out that the SSH2 banner may not use dash
|
|
||||||
('-'). Reported by Bjorn Stenborg.
|
|
||||||
|
|
||||||
- Sean Peterson fixed a key re-exchange bug:
|
|
||||||
http://daniel.haxx.se/projects/libssh2/mail/libssh2-devel-archive-2008-06/0002.shtml
|
|
||||||
|
|
||||||
- Mike Protts filed the bug report #1908724 that identified and fixed a problem
|
|
||||||
with SFTP stat on files >4GB in size. Previously it used 32bit math only.
|
|
||||||
|
|
||||||
- Removed a stderr debug message that was accidentally left in (bug #1863153)
|
|
||||||
|
|
||||||
- OpenSSL and libz detection changed to make cross-compiling to Mingw
|
|
||||||
work. See README for parameters to use if the auto-detection does
|
|
||||||
not work for you. From Simon Josefsson.
|
|
||||||
|
|
||||||
- Simon Josefsson added a self-test that uses libssh2 to connect to a
|
|
||||||
local sshd (only enabled if if OpenSSH is installed).
|
|
||||||
|
|
||||||
Version 0.18 (November 11 2007)
|
|
||||||
-------------------------------
|
|
||||||
|
|
||||||
- Various changes that improve non-blocking operations and prevent stalls.
|
|
||||||
Especially noticable on Windows since libssh2 just didn't work properly
|
|
||||||
non-blocking on Windows before.
|
|
||||||
|
|
||||||
- Peter O'Gorman reported how a SCP transfer would hang for him, and it was
|
|
||||||
fairly easy reproducable. One bug was in the transport layer, ignoring to
|
|
||||||
read more data while there was data left even though it couldn't decrypt the
|
|
||||||
data that was left due to it being too little... The other bug was in the
|
|
||||||
channel layer, where the libssh2_channel_receive_window_adjust() function
|
|
||||||
missed to set the state variables at times and thus this function would
|
|
||||||
misbehave on repeated invokes.
|
|
||||||
|
|
||||||
- Changed the signature of libssh2_channel_setenv_ex to add const to the
|
|
||||||
"varname" parameter (Dan Fandrich)
|
|
||||||
|
|
||||||
- Satish Mittal and David J Sullivan fixed an infinit recv() loop in
|
|
||||||
libssh2_banner_receive()
|
|
||||||
|
|
||||||
Version 0.17 (August 6 2007)
|
|
||||||
----------------------------
|
|
||||||
Changes since previous version include:
|
|
||||||
|
|
||||||
o Re-indented the source code with this GNU indent setup:
|
|
||||||
|
|
||||||
--braces-on-if-line
|
|
||||||
--braces-after-struct-decl-line
|
|
||||||
--space-after-cast
|
|
||||||
--line-length 79
|
|
||||||
--comment-line-length 79
|
|
||||||
--cuddle-else
|
|
||||||
--no-tabs
|
|
||||||
--tab-size 8
|
|
||||||
--indent-level 4
|
|
||||||
--no-space-after-for
|
|
||||||
--space-after-if
|
|
||||||
--space-after-while
|
|
||||||
--no-space-after-function-call-names
|
|
||||||
|
|
||||||
Version 0.16 (August 6 2007)
|
|
||||||
----------------------------
|
|
||||||
Changes since previous version include:
|
|
||||||
|
|
||||||
o CRLF stripping fix for PEM reading
|
|
||||||
o libssh2_scp_recv() error message fix
|
|
||||||
o added HACKING as an initial attempt to describe our source code format
|
|
||||||
o new public defines in include/libssh2.h to allow applictions to figure out
|
|
||||||
version number etc
|
|
||||||
o new script (maketgz) to build releases with
|
|
||||||
o updated files for building with MSVC and mingw
|
|
||||||
o keyboard-interactive would always fail due to claimed memory problem
|
|
||||||
o a few minor memory leaks fixed
|
|
||||||
o libssh2_poll() no longer relies on C99 features
|
|
||||||
o AIX 4 and 5 now supports non-blocking sockets
|
|
||||||
o large file magic checks in configure
|
|
||||||
o LIBSSH2_APINO was removed from the public header file
|
|
||||||
|
|
||||||
This release would not have been possible without these friendly contributors:
|
|
||||||
|
|
||||||
James Housley, Simon Josefsson, Dan Fandrich, Guenter Knauf and I too did
|
|
||||||
some poking. (Sorry if I forgot anyone I should've mentioned here.)
|
|
||||||
|
|
||||||
Of course we would have nothing without the great work by Sara Golemon that
|
|
||||||
we're extending and building upon.
|
|
||||||
|
|
||||||
Version 0.15 (June 15 2007)
|
|
||||||
---------------------------
|
|
||||||
Added libssh2_sftp_readdir_ex() and updated LIBSSH2_APINO to
|
|
||||||
200706151200 (James Housley)
|
|
||||||
|
|
||||||
Converted all of the libssh2 code to be able to work in non-blocking
|
|
||||||
mode. This included some public API changes, listed below (James Housley)
|
|
||||||
Changed function return values:
|
|
||||||
int libssh2_session_free()
|
|
||||||
int libssh2_publickey_shutdown()
|
|
||||||
ssize_t libssh2_channel_read_ex()
|
|
||||||
ssize_t libssh2_channel_write_ex()
|
|
||||||
|
|
||||||
Added functions:
|
|
||||||
libssh2_session_last_errno(), libssh2_channel_handle_extended_data2(),
|
|
||||||
libssh2_channel_wait_closed(), libssh2_channel_wait_eof(),
|
|
||||||
libssh2_session_set_blocking()
|
|
||||||
|
|
||||||
Removed functions:
|
|
||||||
libssh2_channel_readnb_ex(), libssh2_channel_writenb_ex(),
|
|
||||||
libssh2_sftp_readnb(), libssh2_sftp_writenb(),
|
|
||||||
libssh2_sftp_mkdirnb_ex()
|
|
||||||
|
|
||||||
Added the following functions for non-blocking operations: (Daniel Stenberg)
|
|
||||||
libssh2_channel_readnb_ex()
|
|
||||||
libssh2_channel_writenb_ex()
|
|
||||||
libssh2_sftp_readnb()
|
|
||||||
libssh2_sftp_writenb()
|
|
||||||
|
|
||||||
Size parameter changed from 'int' to 'unsigned int' in several
|
|
||||||
public APIs.
|
|
||||||
|
|
||||||
Added (a few) man pages in docs/. (Daniel Stenberg)
|
|
||||||
|
|
||||||
Maximum SSH packet size is now some 35000 bytes.
|
|
||||||
|
|
||||||
Private include files are now in src/ and only public headers are in
|
|
||||||
include/. (Daniel Stenberg)
|
|
||||||
|
|
||||||
Automake and libtool are being used (increased portability). (Daniel
|
|
||||||
Stenberg)
|
|
||||||
|
|
||||||
Fixed OpenSSL detection using pkg-config. (Daniel Stenberg)
|
|
||||||
|
|
||||||
Simple self test added to tests/. (Simon Josefsson)
|
|
||||||
|
|
||||||
Libgcrypt can now be used instead of OpenSSL if you specify
|
|
||||||
--with-libgcrypt. (Simon Josefsson)
|
|
||||||
|
|
||||||
Fixed a memory leak in the packet handling, and better handle out of
|
|
||||||
memory situations. (Dan Fandrich)
|
|
||||||
|
|
||||||
Made libssh2 build with OpenSSL 0.9.6. (Dan Fandrich)
|
|
||||||
|
|
||||||
Improved portability to Solaris related to -lsocket and
|
|
||||||
-lnsl. (Simon Josefsson)
|
|
||||||
|
|
||||||
Clean up of README, INSTALL, NEWS, added ChangeLog. (Simon
|
|
||||||
Josefsson)
|
|
||||||
|
|
||||||
Improve debugging code. Avoids many #ifdef's.
|
|
||||||
|
|
||||||
Improved session closing to avoid potentially truncated files on
|
|
||||||
OpenSSH servers (Dan Fandrich)
|
|
||||||
|
|
||||||
Made some function parameters in the API const (Dan Fandrich)
|
|
||||||
|
|
||||||
Version 0.14
|
|
||||||
------------
|
|
||||||
|
|
||||||
Plug leaks in EVP cipher init/shutdown. (Selcuk Gueney)
|
|
||||||
|
|
||||||
Allow socket_fd == 0 in libssh2_session_startup(). (puudeli)
|
|
||||||
|
|
||||||
Swap ordering of packet_add/packet-inspection to avoid inspect after
|
|
||||||
free. (Selcuk)
|
|
||||||
|
|
||||||
Swap KEX_INIT ordering, send our KEX_INIT first.
|
|
||||||
|
|
||||||
Add check for oportunistic KEX_INIT packets. Burn bad guess if necessary.
|
|
||||||
|
|
||||||
Fix OpenSSL detection using pkg-config. (Dan Casey)
|
|
||||||
|
|
||||||
Version 0.13
|
|
||||||
------------
|
|
||||||
|
|
||||||
Fixed channel not being marked closed when CHANNEL_CLOSE package cannot be
|
|
||||||
sent. (David Robins)
|
|
||||||
|
|
||||||
Fixed payload packet allocation bug when invalid packet length
|
|
||||||
received. (David Robins)
|
|
||||||
|
|
||||||
Fixed `make install' target for MacOSX.
|
|
||||||
|
|
||||||
Add terminating NULL character to readlink()/realpath() results.
|
|
||||||
|
|
||||||
BugFix#1436593: Apply build options for HPUX targets.
|
|
||||||
|
|
||||||
Version 0.12
|
|
||||||
------------
|
|
||||||
|
|
||||||
Added support for publickey subsytem (not the same as publickey auth).
|
|
||||||
|
|
||||||
Fix x11_req. Multiple packet_len issues and error handling logic.
|
|
||||||
(Thanks Simon Hart)
|
|
||||||
|
|
||||||
Fix generation of 'e' portion of Diffie-Hellman keyset.
|
|
||||||
|
|
||||||
Use appropriate order for BN_rand() rather than fixed group1-specific value.
|
|
||||||
|
|
||||||
Re-fixed libssh2_sftp_rename_ex()
|
|
||||||
|
|
||||||
Transport had right packet_len, but sftp layer still had extra 4 bytes.
|
|
||||||
|
|
||||||
Fixed build with newer OpenSSL headers.
|
|
||||||
|
|
||||||
Added extern "C" declarations to libssh2_sftp.h for C++ compatability.
|
|
||||||
|
|
||||||
Version 0.11
|
|
||||||
------------
|
|
||||||
|
|
||||||
Added libssh2_chnnale_get_exit_status() -- Mikhail
|
|
||||||
|
|
||||||
Added libssh2_channel_wait_closed() -- Mikhail
|
|
||||||
|
|
||||||
Added libssh2_userauth_keyboard_interactive_ex() -- Mikhail
|
|
||||||
|
|
||||||
Added libssh2_channel_receive_window_adjust() to be able to increase the
|
|
||||||
size of the receive window.
|
|
||||||
|
|
||||||
Added queueing for small window_adjust packets to avoid unnecessary packet
|
|
||||||
conversation.
|
|
||||||
|
|
||||||
Fixed libssh2_sftp_rename_ex() to only send flags parameter if version >= 5
|
|
||||||
negotiated (not currently possible, but will be and might as well keep the
|
|
||||||
API consistent).
|
|
||||||
|
|
||||||
Version 0.10
|
|
||||||
------------
|
|
||||||
|
|
||||||
Added developer debugging hooks. See --enable-debug-* options to ./configure
|
|
||||||
|
|
||||||
Ignore extended data in the SFTP layer. With no other mechanism to deal
|
|
||||||
with that data it'd just fill up and get stuck.
|
|
||||||
|
|
||||||
(Re)Fixed channel_write() to provide an opportunity for window space to
|
|
||||||
become available again.
|
|
||||||
|
|
||||||
(Re)Fixed SFTP INIT to send the correct SFTP packet length.
|
|
||||||
|
|
||||||
Fixed segfault when client and host can't agree on a hostkey/crypt/mac/comp
|
|
||||||
method. (Thanks puudeli)
|
|
||||||
|
|
||||||
Fixed major issue with sftp packet buffering mechanism. Using wrong
|
|
||||||
blocking semantics. (No puudeli, YOU the man)
|
|
||||||
|
|
||||||
Reduced busy-looping of libssh2_sftp_packet_requirev.
|
|
||||||
|
|
||||||
Version 0.9
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Changed blocking_read to only block as much as necessary and not an
|
|
||||||
arbitrary length of time. (Thanks Felix)
|
|
||||||
|
|
||||||
Fixed SFTP INIT/VERSION to exclude request_id and send correct maximum
|
|
||||||
version number.
|
|
||||||
|
|
||||||
Fixed SFTP to be properly BC with version 1 and 2 servers.
|
|
||||||
|
|
||||||
Fixed libssh2_poll() to recognized closed sessions/channels.
|
|
||||||
|
|
||||||
Fixed libssh2_channel_write_ex() to fully block when set to blocking mode.
|
|
||||||
Return actual bytes written as well. (Thanks deadem)
|
|
||||||
|
|
||||||
Added tests for -lm and -lsocket and add them when necessary.
|
|
||||||
|
|
||||||
Added libssh2_channel_window_read_ex() and libssh2_channel_window_write_ex()
|
|
||||||
for examining the ssh transport windowing states.
|
|
||||||
|
|
||||||
Version 0.8
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Fix potential segfault in compression/decompression.
|
|
||||||
|
|
||||||
Fix compatability with older versions of OpenSSL
|
|
||||||
|
|
||||||
Swapped order of none,zlib compression modes to prefer no compression by
|
|
||||||
default.
|
|
||||||
|
|
||||||
Added sys/uio.h for platforms (FBSD) which need it in order to define struct
|
|
||||||
iovec.
|
|
||||||
|
|
||||||
Added libssh2_poll() to check status of sockets/channels/listeners.
|
|
||||||
|
|
||||||
Removed unnecessary inclusion of stdio.h (holdover from debugging)
|
|
||||||
|
|
||||||
Version 0.7
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Added libssh2_userauth_hostbased_fromfile_ex() for authenticating from hostkey.
|
|
||||||
|
|
||||||
Added configure recognition for MacOSX (Darwin) (Thanks Gabe)
|
|
||||||
|
|
||||||
Fixed extended data identification in libssh2_channel_read().
|
|
||||||
|
|
||||||
Fixed window adjust code. Hadn't acknowledged adjustments correctly.
|
|
||||||
|
|
||||||
Removed initial_window_size requirement for sending window adjust packet.
|
|
||||||
|
|
||||||
|
|
||||||
Version 0.6
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Added LIBSSH2_FLAG_SIGPIPE to enable/disable SIGPIPE generated by
|
|
||||||
send()/recv() calls. Default off.
|
|
||||||
|
|
||||||
Added libssh2_session_flag() to set optional session flags.
|
|
||||||
|
|
||||||
Collapsed exchanging_keys/newkeys/authenticated flags into single state
|
|
||||||
attribute.
|
|
||||||
|
|
||||||
Fix zlib compression issue when internal buffer state misses partial sync.
|
|
||||||
|
|
||||||
Fix segfault when libssh2_session_methods() is called prior to
|
|
||||||
session_startup().
|
|
||||||
|
|
||||||
Fixed client to server channel windowing. Pervent send queue overruns.
|
|
||||||
|
|
||||||
Swapped banner send/receive order (send first, then wait for response).
|
|
||||||
|
|
||||||
Version 0.5
|
|
||||||
-----------
|
|
||||||
|
|
||||||
*** BC Break ***
|
|
||||||
Reimplemented libssh2_session_methods() to match
|
|
||||||
libssh2_session_method_pref() style
|
|
||||||
|
|
||||||
Fixed libssh2_attr2bin() (effects any setstat style call).
|
|
||||||
|
|
||||||
Fixed authenticating with encrypted private key.
|
|
||||||
|
|
||||||
Fixed authenticating via ssh-dss public key.
|
|
||||||
|
|
||||||
Fixed KEX_INIT cookie and packet padding to use actual random data
|
|
||||||
|
|
||||||
Added DESTDIR support to makefiles (Adam Go<47><6F>biowski -- I hope that
|
|
||||||
character set translates right)
|
|
||||||
|
|
||||||
Added libssh2_channel_forward_listen_ex(), libssh2_channel_forward_cancel(),
|
|
||||||
and libssh2_channel_forward_accept().
|
|
||||||
|
|
||||||
Added ./configure option '--disable-gex-new' to allow using the older
|
|
||||||
group-exchange format
|
|
||||||
|
|
||||||
Added MAC methods hmac-md5 and hmac-md5-96.
|
|
||||||
|
|
||||||
Version 0.4
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Fixed crash when trying to free sftp_dirhandle data from a filehandle struct.
|
|
||||||
|
|
||||||
Fixed leak in sftp_open_ex(), handle->handle not freed in handle_close().
|
|
||||||
|
|
||||||
Fixed leak in sftp_symlink_ex(), result for READLINK and REALPATH not freed unless there was an error.
|
|
||||||
|
|
||||||
Added libssh2_banner_set(), specify an arbitrary banner to send on introduction.
|
|
||||||
|
|
||||||
Version 0.3
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Fixed libssh2_channel_read_ex(). Packet loop initialized BEFORE transport polled for new packets (should have been after).
|
|
||||||
|
|
||||||
Fixed blocking issues in scp_send()/scp_recv().
|
|
||||||
|
|
||||||
Fixed degree of indirection in macerror callback.
|
|
||||||
|
|
||||||
Changed packet read mechanism to use a fixed buffer and avoid unnecessary alloc/free calls. (especially while non-block looping)
|
|
||||||
|
|
||||||
Added channel close callback.
|
|
||||||
|
|
||||||
Added SFTP support (Using its own header file: libssh2_sftp.h)
|
|
||||||
|
|
||||||
Version 0.2
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Changed extended data ignorance mechanism:
|
|
||||||
libssh2_channel_ignore_extended_data() changed to libssh2_channel_handle_extended_data()
|
|
||||||
Macro introduced for backward compatability during beta phase.
|
|
||||||
*** THE LIBSSH2_CHANNEL_IGNORE_EXTENDED_DATA() MACRO WILL BE REMOVED PRIOR TO 1.0 RELEASE ***
|
|
||||||
libssh2_channel_handle_extended_data() may be passed one of three "ignore_mode" constants
|
|
||||||
LIBSSH2_CHANNEL_EXTENDED_DATA_NONE Default behavior, queue ED packets and return them with read_ex
|
|
||||||
LIBSSH2_CHANNEL_EXTENDED_DATA_IGNORE Equivalent to libssh2_channel_ignore_extended_data()
|
|
||||||
IGNORE will implicitly flush the extended data stream(s)
|
|
||||||
LIBSSH2_CHANNEL_EXTENDED_DATA_MERGE Calls to channel_read() will check both the standard data stream
|
|
||||||
and the extended data stream(s) for the first available packet
|
|
||||||
|
|
||||||
Changed libssh2_session_disconnect_ex() to return an error code when alloc fails
|
|
||||||
|
|
||||||
Added libssh2_channel_flush_ex() and basic macros: ..._flush() ..._flush_stderr()
|
|
||||||
flush_ex accepts either the streamid (0 for standard data, 1 for stderr) or one of the two following constants:
|
|
||||||
LIBSSH2_CHANNEL_FLUSH_ALL Flush all streams
|
|
||||||
LIBSSH2_CHANNEL_FLUSH_EXTENDED_DATA Flush all streams EXCEPT the standard data stream
|
|
||||||
|
|
||||||
Added libssh2_session_callback_set() for setting ignore/debug/disconnect/macerror callbacks
|
|
||||||
|
|
||||||
Added libssh2_session_method_pref() to selectively set methods and method preferences.
|
|
||||||
|
|
||||||
Added libssh2_session_methods() to determine what methods were negotiated.
|
|
||||||
|
|
||||||
Added libssh2_session_abstract() for retreiving &session->abstract
|
|
||||||
|
|
||||||
Added libssh2_session_last_error() for retreiving error codes/messages
|
|
||||||
|
|
||||||
Version 0.1
|
|
||||||
-----------
|
|
||||||
|
|
||||||
Initial Release:
|
|
||||||
KEX methods: diffie-hellman-group14-sha1, diffie-hellman-group-exchange-sha1, diffie-hellman-group1-sha1
|
|
||||||
Hostkey methods: ssh-rsa, ssh-dss
|
|
||||||
Cipher methods: aes256-cbc, rijndael-cbc@lysator.liu.se, aes192-cbc, aes128-cbc, blowfish-cbc, arcfour, cast128-cbc, 3des-cbc, none*
|
|
||||||
Compression methods: zlib, none
|
|
||||||
MAC methods: hmac-sha1, hmac-sha1-96, hmac-ripemd160, hmac-ripemd160@openssh.com none*
|
|
||||||
*Cipher/MAC "none" is disabled by default for security purposes,
|
|
||||||
Use --enable-crypt-none and/or --enable-mac-none with ./configure to enable
|
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
!include "win32/config.mk"
|
!include "win32/config.mk"
|
||||||
|
|
||||||
# SUBDIRS=src example\simple
|
# SUBDIRS=src example
|
||||||
SUBDIRS=src
|
SUBDIRS=src
|
||||||
|
|
||||||
all-sub:
|
all-sub:
|
||||||
|
@@ -1,40 +1,44 @@
|
|||||||
libssh2 1.2
|
libssh2 1.2.8
|
||||||
|
|
||||||
This release includes the following changes:
|
This release includes the following changes:
|
||||||
|
|
||||||
o we've switched to using git for source code control
|
o added libssh2_free, libssh2_channel_get_exit_signal and
|
||||||
o we're offering an alternative web site at http://libssh2.haxx.se/
|
libssh2_session_handshake
|
||||||
o the libssh2-devel mailing list moved to http://cool.haxx.se/
|
o SFTP read/write remade and now MUCH faster, especially on high latency
|
||||||
o libssh2_poll() and libssh2_poll_channel_read() are now deprecated
|
connections
|
||||||
o a range of libssh2_knownhost_*() functions were added to the API to work
|
o added new examples: ssh2_echo.c, sftp_append.c and sftp_write_sliding.c
|
||||||
with OpenSSH style known_hosts files etc
|
o userauth: derive publickey from private
|
||||||
o added libssh2_session_hostkey()
|
o NEWS: now generated from git
|
||||||
o added an X11 forwarding example
|
|
||||||
o the makefile now generate MSVS project files
|
|
||||||
|
|
||||||
This release includes the following bugfixes:
|
This release includes the following bugfixes:
|
||||||
|
|
||||||
o bad 0-return from libssh2_channel_read
|
o Support unlimited number of host names in a single line of the
|
||||||
o failure to "drain" the transport data caused badness
|
known_hosts file.
|
||||||
o memory leak in libssh2_sftp_shutdown()
|
o fix memory leak in userauth_keyboard_interactive()
|
||||||
o fixed stroll() #if condition
|
o fix memory leaks (two times cipher_data) for each sftp session
|
||||||
o build thread-safe on Solaris
|
o session_startup: manage server data before server identification
|
||||||
o error when including libssh2.h in two files on Windows fixed
|
o SCP: allow file names with bytes > 126
|
||||||
o custom memory function extra argument was wrong
|
o scp_recv: improved treatment of channel_read() returning zero
|
||||||
o transport now checks for and bail out on packets claing to be zero sized
|
o libssh2_userauth_authenticated: make it work as documented
|
||||||
o fixed a number of compiler warnings
|
o variable size cleanup: match internal variable sizes better with the sizes
|
||||||
o buildconf runs on Mac OS X
|
of the fields used on the wire
|
||||||
o public headers includable on their own
|
o channel_request_pty_size: fix reqPTY_state
|
||||||
o bad debugdump() caused SIGSEGV at times (when libssh2_trace() was used)
|
o sftp_symlink: return error if receive buffer too small
|
||||||
o possible data loss when send_existing() failed to send its buffer
|
o sftp_readdir: return error if buffer is too small
|
||||||
o passing FILE*s across DLL boundaries (OpenSSL) caused crashes on Windows
|
o libssh2_knownhost_readfile.3: clarify return value
|
||||||
|
o configure: stop using the deprecated AM_INIT_AUTOMAKE syntax
|
||||||
|
o Fixed Win32 makefile which was now broken at resource build
|
||||||
|
o kex_agree_hostkey: fix NULL pointer derefence
|
||||||
|
o _libssh2_ntohu64: fix conversion from network bytes to uint64
|
||||||
|
o ssize_t: proper typedef with MSVC compilers
|
||||||
|
o zlib: Add debug tracing of zlib errors
|
||||||
|
o decomp: increase decompression buffer sizes
|
||||||
|
|
||||||
This release would not have looked like this without help, code, reports and
|
This release would not have looked like this without help, code, reports and
|
||||||
advice from friends like these:
|
advice from friends like these:
|
||||||
|
|
||||||
Simon Josefsson, Neil Gierman, Alexander Lamaison, Peter Stuge,
|
Alexander Lamaison, Alfred Gebert, Guenter Knauf, Dan Fandrich,
|
||||||
Steven Van Ingelgem, Ben Kibbey, Francois Dupoux, Mark McPherson,
|
Daniel Stenberg, Jasmeet Bagga, Joey Degges, Mark Smith, Peter Stuge,
|
||||||
Guenter Knauf, Yang Tse, Tor Arntsen, Jussi Mononen, Olivier Hervieu,
|
Pierre Joye, Simon Josefsson, TJ Saunders, Tommy Lindgren
|
||||||
Paul Veldkamp
|
|
||||||
|
|
||||||
Thanks! (and sorry if I forgot to mention someone)
|
Thanks! (and sorry if I forgot to mention someone)
|
||||||
|
156
TODO
156
TODO
@@ -1,26 +1,38 @@
|
|||||||
Things TODO
|
Things TODO
|
||||||
===========
|
===========
|
||||||
|
|
||||||
|
* Fix the numerous malloc+copy operations for sending data, see "Buffering
|
||||||
|
Improvements" below for details
|
||||||
|
|
||||||
* make sure the windowing code adapts better to slow situations so that it
|
* make sure the windowing code adapts better to slow situations so that it
|
||||||
doesn't then use as much memory as today
|
doesn't then use as much memory as today. Possibly by an app-controllable
|
||||||
|
"Window mode"?
|
||||||
|
|
||||||
* Introduce a 'libssh2_socket_t' type for sockets in internal code
|
* Introduce a function that can free data that is returned allocated from the
|
||||||
|
lib, like when libssh2_session_last_error() is asked to return the string
|
||||||
* Provide a libssh2_scp_send() API for files larger than 4GB (32bit size)
|
with 'want_buf' set to non-zero.
|
||||||
|
|
||||||
* Convert the linked list code used all over to use the (new) generic linked
|
|
||||||
list code. See the _libssh2_list_*() functions in src/misc.c
|
|
||||||
|
|
||||||
* Add more info to the man pages.
|
* Add more info to the man pages.
|
||||||
|
|
||||||
* Decrease the number of mallocs. Everywhere.
|
* Decrease the number of mallocs. Everywhere. Will get easier once the
|
||||||
|
buffering improvements have been done.
|
||||||
|
|
||||||
* Use SO_NOSIGPIPE for Mac OS/BSD systems where MSG_NOSIGNAL doesn't exist/work
|
* Use SO_NOSIGPIPE for Mac OS/BSD systems where MSG_NOSIGNAL doesn't
|
||||||
|
exist/work
|
||||||
|
|
||||||
* Extend the test suite to actually test lots of aspects of libssh2
|
* Extend the test suite to actually test lots of aspects of libssh2
|
||||||
|
|
||||||
* Fix all compiler warnings (some can't be done without API changes)
|
* Fix all compiler warnings (some can't be done without API changes)
|
||||||
|
|
||||||
|
* Expose error messages sent by the server
|
||||||
|
|
||||||
|
* Make SFTP transfers ask for and send several packages at once so that it
|
||||||
|
doesn't have to send-waitforack-send-waitforack as much. This will be
|
||||||
|
easier/smoother if we implement the "New SFTP API" described below.
|
||||||
|
|
||||||
|
* select() is troublesome with libssh2 when using multiple channels over
|
||||||
|
the same session. See "New Transport API" below for more details.
|
||||||
|
|
||||||
At next SONAME bump
|
At next SONAME bump
|
||||||
===================
|
===================
|
||||||
|
|
||||||
@@ -38,8 +50,134 @@ At next SONAME bump
|
|||||||
libssh2_channel_receive_window_adjust()
|
libssh2_channel_receive_window_adjust()
|
||||||
libssh2_poll()
|
libssh2_poll()
|
||||||
libssh2_poll_channel_read()
|
libssh2_poll_channel_read()
|
||||||
|
libssh2_session_startup() (libssh2_session_handshake() is the replacement)
|
||||||
|
|
||||||
* Rename a few function:
|
* Rename a few function:
|
||||||
|
|
||||||
libssh2_hostkey_hash => libssh2_session_hostkey_hash
|
libssh2_hostkey_hash => libssh2_session_hostkey_hash
|
||||||
libssh2_banner_set => libssh2_session_banner_set
|
libssh2_banner_set => libssh2_session_banner_set
|
||||||
|
|
||||||
|
* change 'int' to 'libssh2_socket_t' in the public API for sockets.
|
||||||
|
|
||||||
|
* Use 'size_t' for string lengths in all functions.
|
||||||
|
|
||||||
|
* Add a comment field to struct libssh2_knownhost.
|
||||||
|
|
||||||
|
* remove the existing libssh2_knownhost_add() function and rename
|
||||||
|
libssh2_knownhost_addc to become the new libssh2_knownhost_add instead
|
||||||
|
|
||||||
|
* remove the existing libssh2_scp_send_ex() function and rename
|
||||||
|
libssh2_scp_send64 to become the new libssh2_scp_send instead.
|
||||||
|
|
||||||
|
* remove the existing libssh2_knownhost_check() functin and rename
|
||||||
|
libssh2_knownhost_checkp() to become the new libssh2_knownhost_check instead
|
||||||
|
|
||||||
|
Buffering Improvements
|
||||||
|
======================
|
||||||
|
|
||||||
|
transport_write
|
||||||
|
|
||||||
|
- If this function gets called with a total packet size that is larger than
|
||||||
|
32K, it should create more than one SSH packet so that it keeps the largest
|
||||||
|
one below 32K
|
||||||
|
|
||||||
|
sftp_write
|
||||||
|
|
||||||
|
- should not copy/allocate anything for the data, only create a header chunk
|
||||||
|
and pass on the payload data to channel_write "pointed to"
|
||||||
|
|
||||||
|
New Transport API
|
||||||
|
=================
|
||||||
|
|
||||||
|
THE PROBLEM
|
||||||
|
|
||||||
|
The problem in a nutshell is that when an application opens up multiple
|
||||||
|
channels over a single session, those are all using the same socket. If the
|
||||||
|
application is then using select() to wait for traffic (like any sensible app
|
||||||
|
does) and wants to act on the data when select() tells there is something to
|
||||||
|
for example read, what does an application do?
|
||||||
|
|
||||||
|
With our current API, you have to loop over all the channels and read from
|
||||||
|
them to see if they have data. This effectively makes blocking reads
|
||||||
|
impossible. If the app has many channels in a setup like this, it even becomes
|
||||||
|
slow. (The original API had the libssh2_poll_channel_read() and libssh2_poll()
|
||||||
|
to somewhat overcome this hurdle, but they too have pretty much the same
|
||||||
|
problems plus a few others.)
|
||||||
|
|
||||||
|
Traffic in the other direction is similarly limited: the app has to try
|
||||||
|
sending to all channels, even though some of them may very well not accept any
|
||||||
|
data at that point.
|
||||||
|
|
||||||
|
A SOLUTION
|
||||||
|
|
||||||
|
I suggest we introduce two new helper functions:
|
||||||
|
|
||||||
|
libssh2_transport_read()
|
||||||
|
|
||||||
|
- Read "a bunch" of data from the given socket and returns information to the
|
||||||
|
app about what channels that are now readable (ie they will not block when
|
||||||
|
read from). The function can be called over and over and it will repeatedly
|
||||||
|
return info about what channels that are readable at that moment.
|
||||||
|
|
||||||
|
libssh2_transport_write()
|
||||||
|
|
||||||
|
- Returns information about what channels that are writable, in the sense
|
||||||
|
that they have windows set from the remote side that allows data to get
|
||||||
|
sent. Writing to one of those channels will not block. Of course, the
|
||||||
|
underlying socket may only accept a certain amount of data, so at the first
|
||||||
|
short return, nothing more should be attempted to get sent until select()
|
||||||
|
(or equivalent) has been used on the master socket again.
|
||||||
|
|
||||||
|
I haven't yet figured out a sensible API for how these functions should return
|
||||||
|
that info, but if we agree on the general principles I guess we can work that
|
||||||
|
out.
|
||||||
|
|
||||||
|
VOLUNTARY
|
||||||
|
|
||||||
|
I wanted to mention that these two helper functions would not be mandatory
|
||||||
|
in any way. They would just be there for those who want them, and existing
|
||||||
|
programs can remain using the old functions only if they prefer to.
|
||||||
|
|
||||||
|
New SFTP API
|
||||||
|
============
|
||||||
|
|
||||||
|
PURPOSE
|
||||||
|
|
||||||
|
Provide API functions that explicitly tells at once that a (full) SFTP file
|
||||||
|
transfer is wanted, to allow libssh2 to leverage on that knowledge to speed
|
||||||
|
up things internally. It can for example do read ahead, buffer writes (merge
|
||||||
|
small writes into larger chunks), better tune the SSH window and more. This
|
||||||
|
sort of API is already provided for SCP transfers.
|
||||||
|
|
||||||
|
API
|
||||||
|
|
||||||
|
New functions:
|
||||||
|
|
||||||
|
LIBSSH2_SFTP_HANDLE *libssh2_sftp_send(SFTP_SESSION *sftp,
|
||||||
|
uint64_t filesize,
|
||||||
|
char *remote_path,
|
||||||
|
size_t remote_path_len,
|
||||||
|
long mode);
|
||||||
|
|
||||||
|
Tell libssh2 that a local file with a given size is about to get sent to
|
||||||
|
the SFTP server.
|
||||||
|
|
||||||
|
LIBSSH2_SFTP_HANDLE *libssh2_sftp_recv();
|
||||||
|
|
||||||
|
Tell libssh2 that a remote file is requested to get downloaded from the SFTP
|
||||||
|
server.
|
||||||
|
|
||||||
|
Only the setup of the file transfer is different from an application's point
|
||||||
|
of view. Depending on direction of the transfer(s), the following already
|
||||||
|
existing functions should then be used until the transfer is complete:
|
||||||
|
|
||||||
|
libssh2_sftp_read()
|
||||||
|
libssh2_sftp_write()
|
||||||
|
|
||||||
|
HOW TO USE
|
||||||
|
|
||||||
|
1. Setup the transfer using one of the two new functions.
|
||||||
|
|
||||||
|
2. Loop through the reading or writing of data.
|
||||||
|
|
||||||
|
3. Cleanup the transfer
|
||||||
|
@@ -297,7 +297,7 @@ dnl Internal macro for CURL_CONFIGURE_REENTRANT.
|
|||||||
|
|
||||||
AC_DEFUN([CURL_CHECK_NEED_REENTRANT_SYSTEM], [
|
AC_DEFUN([CURL_CHECK_NEED_REENTRANT_SYSTEM], [
|
||||||
case $host in
|
case $host in
|
||||||
*-*-solaris*)
|
*-*-solaris* | *-*-hpux*)
|
||||||
tmp_need_reentrant="yes"
|
tmp_need_reentrant="yes"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
|
17
buildconf
17
buildconf
@@ -2,26 +2,21 @@
|
|||||||
|
|
||||||
LIBTOOLIZE="libtoolize"
|
LIBTOOLIZE="libtoolize"
|
||||||
|
|
||||||
if [ "x`which $LIBTOOLIZE`" == "x" ];
|
if [ "x`which $LIBTOOLIZE`" = "x" ]; then
|
||||||
then
|
LIBTOOLIZE="glibtoolize"
|
||||||
LIBTOOLIZE="glibtoolize";
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "x`which $LIBTOOLIZE`" == "x" ];
|
if [ "x`which $LIBTOOLIZE`" = "x" ]; then
|
||||||
then
|
echo "Neither libtoolize nor glibtoolize could be found!"
|
||||||
echo "Neither libtoolize nor glibtoolize could be found!";
|
exit 1
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
${LIBTOOLIZE} --copy --automake --force
|
${LIBTOOLIZE} --copy --automake --force
|
||||||
${ACLOCAL:-aclocal} -I m4 $ACLOCAL_FLAGS
|
${ACLOCAL:-aclocal} -I m4 $ACLOCAL_FLAGS
|
||||||
${AUTOHEADER:-autoheader}
|
${AUTOHEADER:-autoheader}
|
||||||
# copy the private libssh2_config.h.in to the examples dir so that
|
# copy the private libssh2_config.h.in to the examples dir so that
|
||||||
# it can be included without pointing the include path to the private
|
# it can be included without pointing the include path to the private
|
||||||
# source dir
|
# source dir
|
||||||
cp src/libssh2_config.h.in example/simple/config.h.in
|
cp src/libssh2_config.h.in example/libssh2_config.h.in
|
||||||
${AUTOCONF:-autoconf}
|
${AUTOCONF:-autoconf}
|
||||||
${AUTOMAKE:-automake} --add-missing --copy
|
${AUTOMAKE:-automake} --add-missing --copy
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
# AC_PREREQ(2.57)
|
# AC_PREREQ(2.57)
|
||||||
AC_INIT(libssh2, [-], libssh2-devel@lists.sourceforge.net)
|
AC_INIT(libssh2, [-], libssh2-devel@cool.haxx.se)
|
||||||
AC_CONFIG_MACRO_DIR([m4])
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
AC_CONFIG_SRCDIR([src])
|
AC_CONFIG_SRCDIR([src])
|
||||||
AC_CONFIG_HEADER([src/libssh2_config.h])
|
AM_CONFIG_HEADER([src/libssh2_config.h example/libssh2_config.h])
|
||||||
AM_MAINTAINER_MODE
|
AM_MAINTAINER_MODE
|
||||||
|
|
||||||
dnl SED is needed by some of the tools
|
dnl SED is needed by some of the tools
|
||||||
@@ -16,7 +16,7 @@ fi
|
|||||||
|
|
||||||
dnl figure out the libssh2 version
|
dnl figure out the libssh2 version
|
||||||
VERSION=`$SED -ne 's/^#define LIBSSH2_VERSION *"\(.*\)"/\1/p' ${srcdir}/include/libssh2.h`
|
VERSION=`$SED -ne 's/^#define LIBSSH2_VERSION *"\(.*\)"/\1/p' ${srcdir}/include/libssh2.h`
|
||||||
AM_INIT_AUTOMAKE(libssh2,$VERSION)
|
AM_INIT_AUTOMAKE
|
||||||
AC_MSG_CHECKING([libssh2 version])
|
AC_MSG_CHECKING([libssh2 version])
|
||||||
AC_MSG_RESULT($VERSION)
|
AC_MSG_RESULT($VERSION)
|
||||||
|
|
||||||
@@ -41,6 +41,9 @@ case "$host" in
|
|||||||
;;
|
;;
|
||||||
*hpux*)
|
*hpux*)
|
||||||
;;
|
;;
|
||||||
|
*osf*)
|
||||||
|
CFLAGS="$CFLAGS -D_POSIX_PII_SOCKET"
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
@@ -108,6 +111,14 @@ if test "$ac_cv_libgcrypt" = "yes"; then
|
|||||||
fi
|
fi
|
||||||
AM_CONDITIONAL(LIBGCRYPT, test "$ac_cv_libgcrypt" = "yes")
|
AM_CONDITIONAL(LIBGCRYPT, test "$ac_cv_libgcrypt" = "yes")
|
||||||
|
|
||||||
|
# Not all OpenSSL have AES-CTR functions.
|
||||||
|
if test "$ac_cv_libssl" = "yes"; then
|
||||||
|
save_LDFLAGS="$LDFLAGS"
|
||||||
|
LDFLAGS="$LDFLAGS $LIBSSL"
|
||||||
|
AC_CHECK_FUNCS(EVP_aes_128_ctr)
|
||||||
|
LDFLAGS="$save_LDFLAGS"
|
||||||
|
fi
|
||||||
|
|
||||||
# Look for Libz
|
# Look for Libz
|
||||||
if test "$use_libz" != "no"; then
|
if test "$use_libz" != "no"; then
|
||||||
AC_LIB_HAVE_LINKFLAGS([z], [], [#include <zlib.h>])
|
AC_LIB_HAVE_LINKFLAGS([z], [], [#include <zlib.h>])
|
||||||
@@ -144,12 +155,12 @@ AC_MSG_CHECKING([whether to enable pedantic and debug compiler options])
|
|||||||
AC_ARG_ENABLE(debug,
|
AC_ARG_ENABLE(debug,
|
||||||
AC_HELP_STRING([--enable-debug],[Enable pedantic and debug options])
|
AC_HELP_STRING([--enable-debug],[Enable pedantic and debug options])
|
||||||
AC_HELP_STRING([--disable-debug],[Disable debug options]),
|
AC_HELP_STRING([--disable-debug],[Disable debug options]),
|
||||||
[ case "$enableval" in
|
[ case "$enable_debug" in
|
||||||
no)
|
no)
|
||||||
AC_MSG_RESULT(no)
|
AC_MSG_RESULT(no)
|
||||||
;;
|
;;
|
||||||
*) AC_MSG_RESULT(yes)
|
*) AC_MSG_RESULT(yes)
|
||||||
|
enable_debug=yes
|
||||||
CPPFLAGS="$CPPFLAGS -DLIBSSH2DEBUG"
|
CPPFLAGS="$CPPFLAGS -DLIBSSH2DEBUG"
|
||||||
CFLAGS="$CFLAGS -g"
|
CFLAGS="$CFLAGS -g"
|
||||||
|
|
||||||
@@ -159,6 +170,46 @@ AC_HELP_STRING([--disable-debug],[Disable debug options]),
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
],
|
],
|
||||||
|
enable_debug=no
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
)
|
||||||
|
|
||||||
|
dnl ************************************************************
|
||||||
|
dnl Enable hiding of internal symbols in library to reduce its size and
|
||||||
|
dnl speed dynamic linking of applications. This currently is only supported
|
||||||
|
dnl on gcc >= 4.0 and SunPro C.
|
||||||
|
dnl
|
||||||
|
AC_MSG_CHECKING([whether to enable hidden symbols in the library])
|
||||||
|
AC_ARG_ENABLE(hidden-symbols,
|
||||||
|
AC_HELP_STRING([--enable-hidden-symbols],[Hide internal symbols in library])
|
||||||
|
AC_HELP_STRING([--disable-hidden-symbols],[Leave all symbols with default visibility in library]),
|
||||||
|
[ case "$enableval" in
|
||||||
|
no)
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
AC_MSG_CHECKING([whether $CC supports it])
|
||||||
|
if test "$GCC" = yes ; then
|
||||||
|
if $CC --help --verbose 2>&1 | grep fvisibility= > /dev/null ; then
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
AC_DEFINE(LIBSSH2_API, [__attribute__ ((visibility ("default")))], [to make a symbol visible])
|
||||||
|
CFLAGS="$CFLAGS -fvisibility=hidden"
|
||||||
|
else
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
fi
|
||||||
|
|
||||||
|
else
|
||||||
|
dnl Test for SunPro cc
|
||||||
|
if $CC 2>&1 | grep flags >/dev/null && $CC -flags | grep xldscope= >/dev/null ; then
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
AC_DEFINE(LIBSSH2_API, [__global], [to make a symbol visible])
|
||||||
|
CFLAGS="$CFLAGS -xldscope=hidden"
|
||||||
|
else
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac ],
|
||||||
AC_MSG_RESULT(no)
|
AC_MSG_RESULT(no)
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -167,6 +218,7 @@ AC_HELP_STRING([--disable-debug],[Disable debug options]),
|
|||||||
AC_CHECK_HEADERS([errno.h fcntl.h stdio.h stdlib.h unistd.h sys/uio.h])
|
AC_CHECK_HEADERS([errno.h fcntl.h stdio.h stdlib.h unistd.h sys/uio.h])
|
||||||
AC_CHECK_HEADERS([sys/select.h sys/socket.h sys/ioctl.h sys/time.h])
|
AC_CHECK_HEADERS([sys/select.h sys/socket.h sys/ioctl.h sys/time.h])
|
||||||
AC_CHECK_HEADERS([arpa/inet.h netinet/in.h])
|
AC_CHECK_HEADERS([arpa/inet.h netinet/in.h])
|
||||||
|
AC_CHECK_HEADERS([sys/un.h])
|
||||||
|
|
||||||
case $host in
|
case $host in
|
||||||
*-*-cygwin* | *-*-cegcc*)
|
*-*-cygwin* | *-*-cegcc*)
|
||||||
@@ -177,7 +229,25 @@ case $host in
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
AC_CHECK_FUNCS(poll gettimeofday select strtoll)
|
case $host in
|
||||||
|
*darwin*|*interix*)
|
||||||
|
dnl poll() does not work on these platforms
|
||||||
|
dnl Interix: "does provide poll(), but the implementing developer must
|
||||||
|
dnl have been in a bad mood, because poll() only works on the /proc
|
||||||
|
dnl filesystem here"
|
||||||
|
dnl Mac OS X's poll has funny behaviors, like:
|
||||||
|
dnl not being able to do poll on no fildescriptors (10.3?)
|
||||||
|
dnl not being able to poll on some files (like anything in /dev)
|
||||||
|
dnl not having reliable timeout support
|
||||||
|
dnl inconsistent return of POLLHUP where other implementations give POLLIN
|
||||||
|
AC_MSG_NOTICE([poll use is disabled on this platform])
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
AC_CHECK_FUNCS(poll)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
AC_CHECK_FUNCS(gettimeofday select strtoll)
|
||||||
|
|
||||||
dnl Check for select() into ws2_32 for Msys/Mingw
|
dnl Check for select() into ws2_32 for Msys/Mingw
|
||||||
if test "$ac_cv_func_select" != "yes"; then
|
if test "$ac_cv_func_select" != "yes"; then
|
||||||
@@ -213,6 +283,20 @@ AC_CONFIG_FILES([Makefile
|
|||||||
src/Makefile
|
src/Makefile
|
||||||
tests/Makefile
|
tests/Makefile
|
||||||
example/Makefile
|
example/Makefile
|
||||||
example/simple/Makefile
|
docs/Makefile
|
||||||
docs/Makefile])
|
libssh2.pc])
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
|
|
||||||
|
AC_MSG_NOTICE([summary of build options:
|
||||||
|
|
||||||
|
version: ${VERSION}
|
||||||
|
Host type: ${host}
|
||||||
|
Install prefix: ${prefix}
|
||||||
|
Compiler: ${CC}
|
||||||
|
Compiler flags: ${CFLAGS}
|
||||||
|
Library types: Shared=${enable_shared}, Static=${enable_static}
|
||||||
|
Crypto library: openssl: ${ac_cv_libssl:-no} (AES-CTR: ${ac_cv_func_EVP_aes_128_ctr:-N/A}) libgcrypt: ${ac_cv_libgcrypt:-no}
|
||||||
|
Debug build: $enable_debug
|
||||||
|
Path to sshd: $ac_cv_path_SSHD (only for self-tests)
|
||||||
|
libz compression: $ac_cv_libz
|
||||||
|
])
|
0
docs/.cvsignore → docs/.gitignore
vendored
0
docs/.cvsignore → docs/.gitignore
vendored
@@ -3,41 +3,74 @@
|
|||||||
EXTRA_DIST = template.3
|
EXTRA_DIST = template.3
|
||||||
|
|
||||||
dist_man_MANS = \
|
dist_man_MANS = \
|
||||||
|
libssh2_agent_connect.3 \
|
||||||
|
libssh2_agent_disconnect.3 \
|
||||||
|
libssh2_agent_free.3 \
|
||||||
|
libssh2_agent_get_identity.3 \
|
||||||
|
libssh2_agent_init.3 \
|
||||||
|
libssh2_agent_list_identities.3 \
|
||||||
|
libssh2_agent_userauth.3 \
|
||||||
libssh2_banner_set.3 \
|
libssh2_banner_set.3 \
|
||||||
libssh2_base64_decode.3 \
|
libssh2_base64_decode.3 \
|
||||||
libssh2_channel_close.3 \
|
libssh2_channel_close.3 \
|
||||||
|
libssh2_channel_direct_tcpip.3 \
|
||||||
libssh2_channel_direct_tcpip_ex.3 \
|
libssh2_channel_direct_tcpip_ex.3 \
|
||||||
libssh2_channel_eof.3 \
|
libssh2_channel_eof.3 \
|
||||||
|
libssh2_channel_exec.3 \
|
||||||
|
libssh2_channel_flush.3 \
|
||||||
libssh2_channel_flush_ex.3 \
|
libssh2_channel_flush_ex.3 \
|
||||||
|
libssh2_channel_flush_stderr.3 \
|
||||||
libssh2_channel_forward_accept.3 \
|
libssh2_channel_forward_accept.3 \
|
||||||
libssh2_channel_forward_cancel.3 \
|
libssh2_channel_forward_cancel.3 \
|
||||||
|
libssh2_channel_forward_listen.3 \
|
||||||
libssh2_channel_forward_listen_ex.3 \
|
libssh2_channel_forward_listen_ex.3 \
|
||||||
libssh2_channel_free.3 \
|
libssh2_channel_free.3 \
|
||||||
libssh2_channel_get_exit_status.3 \
|
libssh2_channel_get_exit_status.3 \
|
||||||
|
libssh2_channel_get_exit_signal.3 \
|
||||||
libssh2_channel_handle_extended_data.3 \
|
libssh2_channel_handle_extended_data.3 \
|
||||||
libssh2_channel_handle_extended_data2.3 \
|
libssh2_channel_handle_extended_data2.3 \
|
||||||
|
libssh2_channel_ignore_extended_data.3 \
|
||||||
libssh2_channel_open_ex.3 \
|
libssh2_channel_open_ex.3 \
|
||||||
|
libssh2_channel_open_session.3 \
|
||||||
libssh2_channel_process_startup.3 \
|
libssh2_channel_process_startup.3 \
|
||||||
|
libssh2_channel_read.3 \
|
||||||
libssh2_channel_read_ex.3 \
|
libssh2_channel_read_ex.3 \
|
||||||
|
libssh2_channel_read_stderr.3 \
|
||||||
libssh2_channel_receive_window_adjust.3 \
|
libssh2_channel_receive_window_adjust.3 \
|
||||||
libssh2_channel_receive_window_adjust2.3 \
|
libssh2_channel_receive_window_adjust2.3 \
|
||||||
|
libssh2_channel_request_pty.3 \
|
||||||
libssh2_channel_request_pty_ex.3 \
|
libssh2_channel_request_pty_ex.3 \
|
||||||
|
libssh2_channel_request_pty_size.3 \
|
||||||
libssh2_channel_request_pty_size_ex.3 \
|
libssh2_channel_request_pty_size_ex.3 \
|
||||||
libssh2_channel_send_eof.3 \
|
libssh2_channel_send_eof.3 \
|
||||||
libssh2_channel_set_blocking.3 \
|
libssh2_channel_set_blocking.3 \
|
||||||
|
libssh2_channel_setenv.3 \
|
||||||
libssh2_channel_setenv_ex.3 \
|
libssh2_channel_setenv_ex.3 \
|
||||||
|
libssh2_channel_shell.3 \
|
||||||
|
libssh2_channel_subsystem.3 \
|
||||||
libssh2_channel_wait_closed.3 \
|
libssh2_channel_wait_closed.3 \
|
||||||
libssh2_channel_wait_eof.3 \
|
libssh2_channel_wait_eof.3 \
|
||||||
|
libssh2_channel_window_read.3 \
|
||||||
libssh2_channel_window_read_ex.3 \
|
libssh2_channel_window_read_ex.3 \
|
||||||
|
libssh2_channel_window_write.3 \
|
||||||
libssh2_channel_window_write_ex.3 \
|
libssh2_channel_window_write_ex.3 \
|
||||||
|
libssh2_channel_write.3 \
|
||||||
libssh2_channel_write_ex.3 \
|
libssh2_channel_write_ex.3 \
|
||||||
|
libssh2_channel_write_stderr.3 \
|
||||||
|
libssh2_channel_x11_req.3 \
|
||||||
libssh2_channel_x11_req_ex.3 \
|
libssh2_channel_x11_req_ex.3 \
|
||||||
|
libssh2_exit.3 \
|
||||||
|
libssh2_free.3 \
|
||||||
libssh2_free_host_entry.3 \
|
libssh2_free_host_entry.3 \
|
||||||
libssh2_host_entry_match.3 \
|
libssh2_host_entry_match.3 \
|
||||||
libssh2_hostkey_hash.3 \
|
libssh2_hostkey_hash.3 \
|
||||||
|
libssh2_init.3 \
|
||||||
libssh2_knownhost_add.3 \
|
libssh2_knownhost_add.3 \
|
||||||
|
libssh2_knownhost_addc.3 \
|
||||||
libssh2_knownhost_check.3 \
|
libssh2_knownhost_check.3 \
|
||||||
|
libssh2_knownhost_checkp.3 \
|
||||||
libssh2_knownhost_del.3 \
|
libssh2_knownhost_del.3 \
|
||||||
|
libssh2_knownhost_free.3 \
|
||||||
libssh2_knownhost_get.3 \
|
libssh2_knownhost_get.3 \
|
||||||
libssh2_knownhost_init.3 \
|
libssh2_knownhost_init.3 \
|
||||||
libssh2_knownhost_readfile.3 \
|
libssh2_knownhost_readfile.3 \
|
||||||
@@ -47,22 +80,28 @@ dist_man_MANS = \
|
|||||||
libssh2_new_host_entry.3 \
|
libssh2_new_host_entry.3 \
|
||||||
libssh2_poll.3 \
|
libssh2_poll.3 \
|
||||||
libssh2_poll_channel_read.3 \
|
libssh2_poll_channel_read.3 \
|
||||||
|
libssh2_publickey_add.3 \
|
||||||
libssh2_publickey_add_ex.3 \
|
libssh2_publickey_add_ex.3 \
|
||||||
libssh2_publickey_init.3 \
|
libssh2_publickey_init.3 \
|
||||||
libssh2_publickey_list_fetch.3 \
|
libssh2_publickey_list_fetch.3 \
|
||||||
libssh2_publickey_list_free.3 \
|
libssh2_publickey_list_free.3 \
|
||||||
|
libssh2_publickey_remove.3 \
|
||||||
libssh2_publickey_remove_ex.3 \
|
libssh2_publickey_remove_ex.3 \
|
||||||
libssh2_publickey_shutdown.3 \
|
libssh2_publickey_shutdown.3 \
|
||||||
libssh2_scp_recv.3 \
|
libssh2_scp_recv.3 \
|
||||||
|
libssh2_scp_send.3 \
|
||||||
libssh2_scp_send_ex.3 \
|
libssh2_scp_send_ex.3 \
|
||||||
|
libssh2_scp_send64.3 \
|
||||||
libssh2_session_abstract.3 \
|
libssh2_session_abstract.3 \
|
||||||
libssh2_session_block_directions.3 \
|
libssh2_session_block_directions.3 \
|
||||||
libssh2_session_callback_set.3 \
|
libssh2_session_callback_set.3 \
|
||||||
|
libssh2_session_disconnect.3 \
|
||||||
libssh2_session_disconnect_ex.3 \
|
libssh2_session_disconnect_ex.3 \
|
||||||
libssh2_session_flag.3 \
|
libssh2_session_flag.3 \
|
||||||
libssh2_session_free.3 \
|
libssh2_session_free.3 \
|
||||||
libssh2_session_get_blocking.3 \
|
libssh2_session_get_blocking.3 \
|
||||||
libssh2_session_hostkey.3 \
|
libssh2_session_hostkey.3 \
|
||||||
|
libssh2_session_init.3 \
|
||||||
libssh2_session_init_ex.3 \
|
libssh2_session_init_ex.3 \
|
||||||
libssh2_session_last_errno.3 \
|
libssh2_session_last_errno.3 \
|
||||||
libssh2_session_last_error.3 \
|
libssh2_session_last_error.3 \
|
||||||
@@ -70,29 +109,56 @@ dist_man_MANS = \
|
|||||||
libssh2_session_methods.3 \
|
libssh2_session_methods.3 \
|
||||||
libssh2_session_set_blocking.3 \
|
libssh2_session_set_blocking.3 \
|
||||||
libssh2_session_startup.3 \
|
libssh2_session_startup.3 \
|
||||||
|
libssh2_sftp_close.3 \
|
||||||
libssh2_sftp_close_handle.3 \
|
libssh2_sftp_close_handle.3 \
|
||||||
|
libssh2_sftp_closedir.3 \
|
||||||
|
libssh2_sftp_fsetstat.3 \
|
||||||
|
libssh2_sftp_fstat.3 \
|
||||||
libssh2_sftp_fstat_ex.3 \
|
libssh2_sftp_fstat_ex.3 \
|
||||||
|
libssh2_sftp_fstatvfs.3 \
|
||||||
libssh2_sftp_init.3 \
|
libssh2_sftp_init.3 \
|
||||||
libssh2_sftp_last_error.3 \
|
libssh2_sftp_last_error.3 \
|
||||||
|
libssh2_sftp_lstat.3 \
|
||||||
|
libssh2_sftp_mkdir.3 \
|
||||||
libssh2_sftp_mkdir_ex.3 \
|
libssh2_sftp_mkdir_ex.3 \
|
||||||
|
libssh2_sftp_open.3 \
|
||||||
libssh2_sftp_open_ex.3 \
|
libssh2_sftp_open_ex.3 \
|
||||||
|
libssh2_sftp_opendir.3 \
|
||||||
libssh2_sftp_read.3 \
|
libssh2_sftp_read.3 \
|
||||||
|
libssh2_sftp_readdir.3 \
|
||||||
libssh2_sftp_readdir_ex.3 \
|
libssh2_sftp_readdir_ex.3 \
|
||||||
|
libssh2_sftp_readlink.3 \
|
||||||
|
libssh2_sftp_realpath.3 \
|
||||||
|
libssh2_sftp_rename.3 \
|
||||||
libssh2_sftp_rename_ex.3 \
|
libssh2_sftp_rename_ex.3 \
|
||||||
|
libssh2_sftp_rewind.3 \
|
||||||
|
libssh2_sftp_rmdir.3 \
|
||||||
libssh2_sftp_rmdir_ex.3 \
|
libssh2_sftp_rmdir_ex.3 \
|
||||||
libssh2_sftp_seek.3 \
|
libssh2_sftp_seek.3 \
|
||||||
|
libssh2_sftp_seek64.3 \
|
||||||
|
libssh2_sftp_setstat.3 \
|
||||||
libssh2_sftp_shutdown.3 \
|
libssh2_sftp_shutdown.3 \
|
||||||
|
libssh2_sftp_stat.3 \
|
||||||
libssh2_sftp_stat_ex.3 \
|
libssh2_sftp_stat_ex.3 \
|
||||||
|
libssh2_sftp_statvfs.3 \
|
||||||
|
libssh2_sftp_symlink.3 \
|
||||||
libssh2_sftp_symlink_ex.3 \
|
libssh2_sftp_symlink_ex.3 \
|
||||||
libssh2_sftp_tell.3 \
|
libssh2_sftp_tell.3 \
|
||||||
libssh2_sftp_tell64.3 \
|
libssh2_sftp_tell64.3 \
|
||||||
|
libssh2_sftp_unlink.3 \
|
||||||
libssh2_sftp_unlink_ex.3 \
|
libssh2_sftp_unlink_ex.3 \
|
||||||
libssh2_sftp_write.3 \
|
libssh2_sftp_write.3 \
|
||||||
libssh2_trace.3 \
|
libssh2_trace.3 \
|
||||||
|
libssh2_trace_sethandler.3 \
|
||||||
libssh2_userauth_authenticated.3 \
|
libssh2_userauth_authenticated.3 \
|
||||||
|
libssh2_userauth_hostbased_fromfile.3 \
|
||||||
libssh2_userauth_hostbased_fromfile_ex.3 \
|
libssh2_userauth_hostbased_fromfile_ex.3 \
|
||||||
|
libssh2_userauth_keyboard_interactive.3 \
|
||||||
libssh2_userauth_keyboard_interactive_ex.3 \
|
libssh2_userauth_keyboard_interactive_ex.3 \
|
||||||
libssh2_userauth_list.3 \
|
libssh2_userauth_list.3 \
|
||||||
|
libssh2_userauth_password.3 \
|
||||||
libssh2_userauth_password_ex.3 \
|
libssh2_userauth_password_ex.3 \
|
||||||
|
libssh2_userauth_publickey.3 \
|
||||||
|
libssh2_userauth_publickey_fromfile.3 \
|
||||||
libssh2_userauth_publickey_fromfile_ex.3 \
|
libssh2_userauth_publickey_fromfile_ex.3 \
|
||||||
libssh2_version.3
|
libssh2_version.3
|
||||||
|
23
docs/libssh2_agent_connect.3
Normal file
23
docs/libssh2_agent_connect.3
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_connect 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_connect - connect to an ssh-agent
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_agent_connect(LIBSSH2_AGENT *agent);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Connect to an ssh-agent running on the system.
|
||||||
|
|
||||||
|
Call \fBlibssh2_agent_disconnect(3)\fP to close the connection after
|
||||||
|
you're doing using it.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if succeeded, or a negative value for error.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_init(3)
|
||||||
|
.BR libssh2_agent_disconnect(3)
|
||||||
|
|
20
docs/libssh2_agent_disconnect.3
Normal file
20
docs/libssh2_agent_disconnect.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_disconnect 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_disconnect - close a connection to an ssh-agent
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_agent_disconnect(LIBSSH2_AGENT *agent);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Close a connection to an ssh-agent.
|
||||||
|
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if succeeded, or a negative value for error.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_connect(3)
|
||||||
|
.BR libssh2_agent_free(3)
|
20
docs/libssh2_agent_free.3
Normal file
20
docs/libssh2_agent_free.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_free 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_free - free an ssh-agent handle
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
void libssh2_agent_free(LIBSSH2_AGENT *agent);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Free an ssh-agent handle. This function also frees the internal
|
||||||
|
collection of public keys.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
None.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_init(3)
|
||||||
|
.BR libssh2_agent_disconnect(3)
|
34
docs/libssh2_agent_get_identity.3
Normal file
34
docs/libssh2_agent_get_identity.3
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_get_identity 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_get_identity - get a public key off the collection of public keys managed by ssh-agent
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_agent_get_identity(LIBSSH2_AGENT *agent,
|
||||||
|
struct libssh2_agent_publickey **store,
|
||||||
|
struct libssh2_agent_publickey *prev);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIlibssh2_agent_get_identity(3)\fP allows an application to iterate
|
||||||
|
over all public keys in the collection managed by ssh-agent.
|
||||||
|
|
||||||
|
\fIstore\fP should point to a pointer that gets filled in to point to the
|
||||||
|
public key data.
|
||||||
|
|
||||||
|
\fIprev\fP is a pointer to a previous 'struct libssh2_agent_publickey'
|
||||||
|
as returned by a previous invoke of this function, or NULL to get the
|
||||||
|
first entry in the internal collection.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if everything is fine and information about a host was stored in
|
||||||
|
the \fIstore\fP struct.
|
||||||
|
|
||||||
|
Returns 1 if it reached the end of public keys.
|
||||||
|
|
||||||
|
Returns negative values for error
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_list_identities(3)
|
||||||
|
.BR libssh2_agent_userauth(3)
|
26
docs/libssh2_agent_init.3
Normal file
26
docs/libssh2_agent_init.3
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_init 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_init - init an ssh-agent handle
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
LIBSSH2_AGENT *libssh2_agent_init(LIBSSH2_SESSION *session);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Init an ssh-agent handle. Returns the handle to an internal
|
||||||
|
representation of an ssh-agent connection. After the successful
|
||||||
|
initialization, an application can call \fBlibssh2_agent_connect(3)\fP
|
||||||
|
to connect to a running ssh-agent.
|
||||||
|
|
||||||
|
Call \fBlibssh2_agent_free(3)\fP to free the handle again after you're
|
||||||
|
doing using it.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns a handle pointer or NULL if something went wrong. The returned handle
|
||||||
|
is used as input to all other ssh-agent related functions libssh2 provides.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_connect(3)
|
||||||
|
.BR libssh2_agent_free(3)
|
24
docs/libssh2_agent_list_identities.3
Normal file
24
docs/libssh2_agent_list_identities.3
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_list_identities 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_list_identities - request an ssh-agent to list of public keys.
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_agent_list_identities(LIBSSH2_AGENT *agent);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Request an ssh-agent to list of public keys, and stores them in the
|
||||||
|
internal collection of the handle. Call
|
||||||
|
\fIlibssh2_agent_get_identity(3)\fP to get a public key off the
|
||||||
|
collection.
|
||||||
|
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if succeeded, or a negative value for error.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_connect(3)
|
||||||
|
.BR libssh2_agent_get_identity(3)
|
||||||
|
|
29
docs/libssh2_agent_userauth.3
Normal file
29
docs/libssh2_agent_userauth.3
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daiki Ueno
|
||||||
|
.\"
|
||||||
|
.TH libssh2_agent_userauth 3 "23 Dec 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_agent_userauth - authenticate a session with a public key, with the help of ssh-agent
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_agent_userauth(LIBSSH2_AGENT *agent,
|
||||||
|
const char *username,
|
||||||
|
struct libssh2_agent_publickey *identity);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIagent\fP - ssh-agent handle as returned by
|
||||||
|
.BR libssh2_agent_init(3)
|
||||||
|
|
||||||
|
\fIusername\fP - Remote user name to authenticate as.
|
||||||
|
|
||||||
|
\fIidentity\fP - Public key to authenticate with, as returned by
|
||||||
|
.BR libssh2_agent_get_identity(3)
|
||||||
|
|
||||||
|
Attempt public key authentication with the help of ssh-agent.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if succeeded, or a negative value for error.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_agent_init(3)
|
||||||
|
.BR libssh2_agent_get_identity(3)
|
19
docs/libssh2_channel_direct_tcpip.3
Normal file
19
docs/libssh2_channel_direct_tcpip.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_direct_tcpip 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_direct_tcpip - convenience macro for \fIlibssh2_channel_direct_tcpip_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_direct_tcpip(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_direct_tcpip_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_direct_tcpip_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_direct_tcpip_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_direct_tcpip_ex(3)\fP
|
@@ -13,6 +13,7 @@ libssh2_channel_eof(LIBSSH2_CHANNEL *channel);
|
|||||||
|
|
||||||
Check if the remote host has sent an EOF status for the selected stream.
|
Check if the remote host has sent an EOF status for the selected stream.
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Returns 1 if the remote host has sent EOF, otherwise 0.
|
Returns 1 if the remote host has sent EOF, otherwise 0. Negative on
|
||||||
|
failure.
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_channel_close(3)
|
.BR libssh2_channel_close(3)
|
||||||
|
19
docs/libssh2_channel_exec.3
Normal file
19
docs/libssh2_channel_exec.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_exec 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_exec - convenience macro for \fIlibssh2_channel_process_startup(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_exec(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_process_startup(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_process_startup(3)\fP
|
19
docs/libssh2_channel_flush.3
Normal file
19
docs/libssh2_channel_flush.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_flush 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_flush - convenience macro for \fIlibssh2_channel_flush_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_flush(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_flush_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_flush_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_flush_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_flush_ex(3)\fP
|
19
docs/libssh2_channel_flush_stderr.3
Normal file
19
docs/libssh2_channel_flush_stderr.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_flush_stderr 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_flush_stderr - convenience macro for \fIlibssh2_channel_flush_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_flush_stderr(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_flush_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_flush_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_flush_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_flush_ex(3)\fP
|
19
docs/libssh2_channel_forward_listen.3
Normal file
19
docs/libssh2_channel_forward_listen.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_forward_listen 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_forward_listen - convenience macro for \fIlibssh2_channel_forward_listen_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_forward_listen(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_forward_listen_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_forward_listen_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_forward_listen_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_forward_listen_ex(3)\fP
|
36
docs/libssh2_channel_get_exit_signal.3
Normal file
36
docs/libssh2_channel_get_exit_signal.3
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
.\" $Id$
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_get_exit_signal 3 "4 Oct 2010" "libssh2 1.2.8" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_get_exit_signal - get the remote exit signal
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
libssh2_channel_get_exit_signal(LIBSSH2_CHANNEL *channel, char **exitsignal, size_t *exitsignal_len, char **errmsg, size_t *errmsg_len, char **langtag, size_t *langtag_len);
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIchannel\fP - Closed channel stream to retrieve exit signal from.
|
||||||
|
|
||||||
|
\fIexitsignal\fP - If not NULL, is populated by reference with the exit signal
|
||||||
|
(without leading "SIG"). Note that the string is stored in a newly allocated
|
||||||
|
buffer. If the remote program exited cleanly, the referenced string pointer
|
||||||
|
will be set to NULL.
|
||||||
|
|
||||||
|
\fIexitsignal_len\fP - If not NULL, is populated by reference with the length
|
||||||
|
of exitsignal.
|
||||||
|
|
||||||
|
\fIerrmsg\fP - If not NULL, is populated by reference with the error message
|
||||||
|
(if provided by remote server, if not it will be set to NULL). Note that the
|
||||||
|
string is stored in a newly allocated buffer.
|
||||||
|
|
||||||
|
\fIerrmsg_len\fP - If not NULL, is populated by reference with the length of errmsg.
|
||||||
|
|
||||||
|
\fIlangtag\fP - If not NULL, is populated by reference with the language tag
|
||||||
|
(if provided by remote server, if not it will be set to NULL). Note that the
|
||||||
|
string is stored in a newly allocated buffer.
|
||||||
|
|
||||||
|
\fIlangtag_len\fP - If not NULL, is populated by reference with the length of langtag.
|
||||||
|
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Numeric error code corresponding to the the Error Code constants.
|
19
docs/libssh2_channel_ignore_extended_data.3
Normal file
19
docs/libssh2_channel_ignore_extended_data.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_ignore_extended_data 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_ignore_extended_data - convenience macro for \fIlibssh2_channel_handle_extended_data(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_ignore_extended_data(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_handle_extended_data(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_handle_extended_data(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_handle_extended_data(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_handle_extended_data(3)\fP
|
19
docs/libssh2_channel_open_session.3
Normal file
19
docs/libssh2_channel_open_session.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_open_session 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_open_session - convenience macro for \fIlibssh2_channel_open_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_open_session(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_open_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_open_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_open_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_open_ex(3)\fP
|
19
docs/libssh2_channel_read.3
Normal file
19
docs/libssh2_channel_read.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_read 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_read - convenience macro for \fIlibssh2_channel_read_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_read(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_read_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_read_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_read_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_read_ex(3)\fP
|
@@ -35,6 +35,9 @@ macros.
|
|||||||
Actual number of bytes read or negative on failure. It returns
|
Actual number of bytes read or negative on failure. It returns
|
||||||
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
||||||
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
||||||
|
|
||||||
|
Note that a return value of zero (0) can in fact be a legitimate value and
|
||||||
|
only signals that no payload data was read. It is not an error.
|
||||||
.SH ERRORS
|
.SH ERRORS
|
||||||
\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
|
\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
|
||||||
|
|
||||||
|
19
docs/libssh2_channel_read_stderr.3
Normal file
19
docs/libssh2_channel_read_stderr.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_read_stderr 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_read_stderr - convenience macro for \fIlibssh2_channel_read_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_read_stderr(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_read_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_read_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_read_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_read_ex(3)\fP
|
19
docs/libssh2_channel_request_pty.3
Normal file
19
docs/libssh2_channel_request_pty.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_request_pty 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_request_pty - convenience macro for \fIlibssh2_channel_request_pty_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_request_pty(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_request_pty_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_request_pty_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_request_pty_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_request_pty_ex(3)\fP
|
19
docs/libssh2_channel_request_pty_size.3
Normal file
19
docs/libssh2_channel_request_pty_size.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_request_pty_size 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_request_pty_size - convenience macro for \fIlibssh2_channel_request_pty_size_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_request_pty_size(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_request_pty_size_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_request_pty_size_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_request_pty_size_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_request_pty_size_ex(3)\fP
|
19
docs/libssh2_channel_setenv.3
Normal file
19
docs/libssh2_channel_setenv.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_setenv 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_setenv - convenience macro for \fIlibssh2_channel_setenv_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_setenv(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_setenv_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_setenv_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_setenv_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_setenv_ex(3)\fP
|
19
docs/libssh2_channel_shell.3
Normal file
19
docs/libssh2_channel_shell.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_shell 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_shell - convenience macro for \fIlibssh2_channel_process_startup(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_shell(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_process_startup(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_process_startup(3)\fP
|
19
docs/libssh2_channel_subsystem.3
Normal file
19
docs/libssh2_channel_subsystem.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_subsystem 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_subsystem - convenience macro for \fIlibssh2_channel_process_startup(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_subsystem(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_process_startup(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_process_startup(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_process_startup(3)\fP
|
19
docs/libssh2_channel_window_read.3
Normal file
19
docs/libssh2_channel_window_read.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_window_read 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_window_read - convenience macro for \fIlibssh2_channel_window_read_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_window_read(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_window_read_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_window_read_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_window_read_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_window_read_ex(3)\fP
|
19
docs/libssh2_channel_window_write.3
Normal file
19
docs/libssh2_channel_window_write.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_window_write 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_window_write - convenience macro for \fIlibssh2_channel_window_write_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_window_write(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_window_write_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_window_write_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_window_write_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_window_write_ex(3)\fP
|
20
docs/libssh2_channel_write.3
Normal file
20
docs/libssh2_channel_write.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_write 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_write - convenience macro for \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define libssh2_channel_write(channel, buf, buflen) \\
|
||||||
|
libssh2_channel_write_ex((channel), 0, (buf), (buflen))
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_write_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_write_ex(3)\fP
|
@@ -4,16 +4,12 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_channel_write_ex - write data to a channel stream blocking
|
libssh2_channel_write_ex - write data to a channel stream blocking
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
|
|
||||||
ssize_t
|
ssize_t libssh2_channel_write_ex(LIBSSH2_CHANNEL *channel,
|
||||||
libssh2_channel_write_ex(LIBSSH2_CHANNEL *channel, int stream_id, char *buf, size_t buflen);
|
int stream_id, char *buf,
|
||||||
|
size_t buflen);
|
||||||
ssize_t
|
|
||||||
libssh2_channel_write(LIBSSH2_CHANNEL *channel, char *buf, size_t buflen);
|
|
||||||
|
|
||||||
ssize_t
|
|
||||||
libssh2_channel_write_stderr(LIBSSH2_CHANNEL *channel, char *buf, size_t buflen);
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
Write data to a channel stream. All channel streams have one standard I/O
|
Write data to a channel stream. All channel streams have one standard I/O
|
||||||
substream (stream_id == 0), and may have up to 2^32 extended data streams as
|
substream (stream_id == 0), and may have up to 2^32 extended data streams as
|
||||||
@@ -29,7 +25,12 @@ defines a stream ID of 1 to be the stderr substream.
|
|||||||
\fIbuflen\fP - size of the data to write
|
\fIbuflen\fP - size of the data to write
|
||||||
|
|
||||||
\fIlibssh2_channel_write(3)\fP and \fIlibssh2_channel_write_stderr(3)\fP are
|
\fIlibssh2_channel_write(3)\fP and \fIlibssh2_channel_write_stderr(3)\fP are
|
||||||
macros.
|
convenience macros for this function.
|
||||||
|
|
||||||
|
\fIlibssh2_channel_write_ex(3)\fP will use as much as possible of the buffer
|
||||||
|
and put it into a single SSH protocol packet. This means that to get maximum
|
||||||
|
performance when sending larger files, you should try to always pass in at
|
||||||
|
least 32K of data to this function.
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Actual number of bytes written or negative on failure.
|
Actual number of bytes written or negative on failure.
|
||||||
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
||||||
|
20
docs/libssh2_channel_write_stderr.3
Normal file
20
docs/libssh2_channel_write_stderr.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_write_stderr 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_write_stderr - convenience macro for \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define libssh2_channel_write_stderr(channel, buf, buflen) \\
|
||||||
|
libssh2_channel_write_ex((channel), SSH_EXTENDED_DATA_STDERR, (buf), (buflen))
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_write_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_write_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_write_ex(3)\fP
|
19
docs/libssh2_channel_x11_req.3
Normal file
19
docs/libssh2_channel_x11_req.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_channel_x11_req 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_channel_x11_req - convenience macro for \fIlibssh2_channel_x11_req_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_channel_x11_req(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_channel_x11_req_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_channel_x11_req_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_channel_x11_req_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_channel_x11_req_ex(3)\fP
|
14
docs/libssh2_exit.3
Normal file
14
docs/libssh2_exit.3
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
.TH libssh2_exit 3 "19 Mar 2010" "libssh2 1.2.5" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_exit - global library deinitialization
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
void
|
||||||
|
libssh2_exit(void);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Exit the libssh2 functions and free's all memory used internal.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.5
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_init(3)
|
19
docs/libssh2_free.3
Normal file
19
docs/libssh2_free.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.TH libssh2_exit 3 "13 Oct 2010" "libssh2 1.2.8" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_free - deallocate libssh2 memory
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
void
|
||||||
|
libssh2_free(LIBSSH2_SESSION *session, void *ptr);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Deallocate memory allocated by earlier call to libssh2 functions. It
|
||||||
|
uses the memory allocation callbacks provided by the application, if
|
||||||
|
any. Otherwise, this will just call free().
|
||||||
|
|
||||||
|
This function is mostly useful under Windows when libssh2 is linked to
|
||||||
|
one run-time library and the application to another.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.8
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_session_init_ex(3)
|
20
docs/libssh2_init.3
Normal file
20
docs/libssh2_init.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.TH libssh2_init 3 "19 Mar 2010" "libssh2 1.2.5" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_init - global library initialization
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define LIBSSH2_INIT_NO_CRYPTO 0x0001
|
||||||
|
|
||||||
|
int
|
||||||
|
libssh2_init(int flags);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
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.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 if succeeded, or a negative value for error.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.5
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_exit(3)
|
@@ -1,10 +1,11 @@
|
|||||||
|
|
||||||
.\" Copyright (c) 2009 by Daniel Stenberg
|
.\" Copyright (c) 2009, 2010 by Daniel Stenberg
|
||||||
.\"
|
.\"
|
||||||
.TH libssh2_knownhost_add 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
.TH libssh2_knownhost_add 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_knownhost_add - add a known host
|
libssh2_knownhost_add - add a known host
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
|
|
||||||
int libssh2_knownhost_add(LIBSSH2_KNOWNHOSTS *hosts,
|
int libssh2_knownhost_add(LIBSSH2_KNOWNHOSTS *hosts,
|
||||||
@@ -13,6 +14,11 @@ int libssh2_knownhost_add(LIBSSH2_KNOWNHOSTS *hosts,
|
|||||||
int typemask,
|
int typemask,
|
||||||
struct libssh2_knownhost **store);
|
struct libssh2_knownhost **store);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
We discourage use of this function as of libssh2 1.2.5. Instead we strongly
|
||||||
|
urge users to use \fIlibssh2_knownhost_addc(3)\fP instead, which as a more
|
||||||
|
complete API. \fIlibssh2_knownhost_add(3)\fP is subject for removal in a
|
||||||
|
future release.
|
||||||
|
|
||||||
Adds a known host to the collection of known hosts identified by the 'hosts'
|
Adds a known host to the collection of known hosts identified by the 'hosts'
|
||||||
handle.
|
handle.
|
||||||
|
|
||||||
@@ -51,8 +57,10 @@ this pointer.
|
|||||||
Returns a regular libssh2 error code, where negative values are error codes
|
Returns a regular libssh2 error code, where negative values are error codes
|
||||||
and 0 indicates success.
|
and 0 indicates success.
|
||||||
.SH AVAILABILITY
|
.SH AVAILABILITY
|
||||||
Added in libssh2 1.2
|
Added in libssh2 1.2, deprecated since libssh2 1.2.5. Use
|
||||||
|
\fIlibssh2_knownhost_addc(3)\fP instead!
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_knownhost_init(3)
|
.BR libssh2_knownhost_init(3)
|
||||||
.BR libssh2_knownhost_free(3)
|
.BR libssh2_knownhost_free(3)
|
||||||
.BR libssh2_knownhost_check(3)
|
.BR libssh2_knownhost_check(3)
|
||||||
|
.BR libssh2_knownhost_addc(3)
|
||||||
|
68
docs/libssh2_knownhost_addc.3
Normal file
68
docs/libssh2_knownhost_addc.3
Normal file
@@ -0,0 +1,68 @@
|
|||||||
|
|
||||||
|
.\" Copyright (c) 2009, 2010 by Daniel Stenberg
|
||||||
|
.\"
|
||||||
|
.TH libssh2_knownhost_add 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_knownhost_add - add a known host
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_knownhost_addc(LIBSSH2_KNOWNHOSTS *hosts,
|
||||||
|
char *host, char *salt,
|
||||||
|
char *key, size_t keylen,
|
||||||
|
const char *comment, size_t commentlen,
|
||||||
|
int typemask,
|
||||||
|
struct libssh2_knownhost **store);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Adds a known host to the collection of known hosts identified by the 'hosts'
|
||||||
|
handle.
|
||||||
|
|
||||||
|
\fIhost\fP is a pointer the host name in plain text or hashed. If hashed, it
|
||||||
|
must be provided base64 encoded. The host name can be the IP numerical address
|
||||||
|
of the host or the full name.
|
||||||
|
|
||||||
|
If you want to add a key for a specific port number for the given host, you
|
||||||
|
must provide the host name like '[host]:port' with the actual characters '['
|
||||||
|
and ']' enclosing the host name and a colon separating the host part from the
|
||||||
|
port number. For example: \&"[host.example.com]:222".
|
||||||
|
|
||||||
|
\fIsalt\fP is a pointer to the salt used for the host hashing, if the host is
|
||||||
|
provided hashed. If the host is provided in plain text, salt has no meaning.
|
||||||
|
The salt has to be provided base64 encoded with a trailing zero byte.
|
||||||
|
|
||||||
|
\fIkey\fP is a pointer to the key for the given host.
|
||||||
|
|
||||||
|
\fIkeylen\fP is the total size in bytes of the key pointed to by the \fIkey\fP
|
||||||
|
argument
|
||||||
|
|
||||||
|
\fIcomment\fP is a pointer to a comment for the key.
|
||||||
|
|
||||||
|
\fIcommentlen\fP is the total size in bytes of the comment pointed to by the \fIcomment\fP argument
|
||||||
|
|
||||||
|
\fItypemask\fP is a bitmask that specifies format and info about the data
|
||||||
|
passed to this function. Specificly, it details what format the host name is,
|
||||||
|
what format the key is and what key type it is.
|
||||||
|
|
||||||
|
The host name is given as one of the following types:
|
||||||
|
LIBSSH2_KNOWNHOST_TYPE_PLAIN, LIBSSH2_KNOWNHOST_TYPE_SHA1 or
|
||||||
|
LIBSSH2_KNOWNHOST_TYPE_CUSTOM.
|
||||||
|
|
||||||
|
The key is encoded using one of the following encodings:
|
||||||
|
LIBSSH2_KNOWNHOST_KEYENC_RAW or LIBSSH2_KNOWNHOST_KEYENC_BASE64.
|
||||||
|
|
||||||
|
The key is using one of these algorithms:
|
||||||
|
LIBSSH2_KNOWNHOST_KEY_RSA1, LIBSSH2_KNOWNHOST_KEY_SSHRSA or
|
||||||
|
LIBSSH2_KNOWNHOST_KEY_SSHDSS.
|
||||||
|
|
||||||
|
\fIstore\fP should point to a pointer that gets filled in to point to the
|
||||||
|
known host data after the addition. NULL can be passed if you don't care about
|
||||||
|
this pointer.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns a regular libssh2 error code, where negative values are error codes
|
||||||
|
and 0 indicates success.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.5
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_knownhost_init(3)
|
||||||
|
.BR libssh2_knownhost_free(3)
|
||||||
|
.BR libssh2_knownhost_check(3)
|
@@ -8,7 +8,8 @@ libssh2_knownhost_check - check a host+key against the list of known hosts
|
|||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
|
|
||||||
int libssh2_knownhost_check(LIBSSH2_KNOWNHOSTS *hosts,
|
int libssh2_knownhost_check(LIBSSH2_KNOWNHOSTS *hosts,
|
||||||
char *host, char *key, size_t keylen,
|
const char *host,
|
||||||
|
const char *key, size_t keylen,
|
||||||
int typemask,
|
int typemask,
|
||||||
struct libssh2_knownhost **knownhost);
|
struct libssh2_knownhost **knownhost);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
63
docs/libssh2_knownhost_checkp.3
Normal file
63
docs/libssh2_knownhost_checkp.3
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009-2010 by Daniel Stenberg
|
||||||
|
.\"
|
||||||
|
.TH libssh2_knownhost_check 3 "1 May 2010" "libssh2 1.2.6" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_knownhost_checkp - check a host+key against the list of known hosts
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int libssh2_knownhost_checkp(LIBSSH2_KNOWNHOSTS *hosts,
|
||||||
|
const char *host, int port,
|
||||||
|
const char *key, size_t keylen,
|
||||||
|
int typemask,
|
||||||
|
struct libssh2_knownhost **knownhost);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Checks a host and its associated key against the collection of known hosts,
|
||||||
|
and returns info back about the (partially) matched entry.
|
||||||
|
|
||||||
|
\fIhost\fP is a pointer the host name in plain text. The host name can be the
|
||||||
|
IP numerical address of the host or the full name.
|
||||||
|
|
||||||
|
\fIport\fP is the port number used by the host (or a negative number
|
||||||
|
to check the generic host). If the port number is given, libssh2 will
|
||||||
|
check the key for the specific host + port number combination in
|
||||||
|
addition to the plain host name only check.
|
||||||
|
|
||||||
|
\fIkey\fP is a pointer to the key for the given host.
|
||||||
|
|
||||||
|
\fIkeylen\fP is the total size in bytes of the key pointed to by the \fIkey\fP
|
||||||
|
argument
|
||||||
|
|
||||||
|
\fItypemask\fP is a bitmask that specifies format and info about the data
|
||||||
|
passed to this function. Specificly, it details what format the host name is,
|
||||||
|
what format the key is and what key type it is.
|
||||||
|
|
||||||
|
The host name is given as one of the following types:
|
||||||
|
LIBSSH2_KNOWNHOST_TYPE_PLAIN or LIBSSH2_KNOWNHOST_TYPE_CUSTOM.
|
||||||
|
|
||||||
|
The key is encoded using one of the following encodings:
|
||||||
|
LIBSSH2_KNOWNHOST_KEYENC_RAW or LIBSSH2_KNOWNHOST_KEYENC_BASE64.
|
||||||
|
|
||||||
|
\fIknownhost\fP if set to non-NULL, it must be a pointer to a 'struct
|
||||||
|
libssh2_knownhost' pointer that gets filled in to point to info about a known
|
||||||
|
host that matches or partially matches.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
\fIlibssh2_knownhost_check(3)\fP returns info about how well the provided
|
||||||
|
host + key pair matched one of the entries in the list of known hosts.
|
||||||
|
|
||||||
|
LIBSSH2_KNOWNHOST_CHECK_FAILURE - something prevented the check to be made
|
||||||
|
|
||||||
|
LIBSSH2_KNOWNHOST_CHECK_NOTFOUND - no host match was found
|
||||||
|
|
||||||
|
LIBSSH2_KNOWNHOST_CHECK_MATCH - hosts and keys match.
|
||||||
|
|
||||||
|
LIBSSH2_KNOWNHOST_CHECK_MISMATCH - host was found, but the keys didn't match!
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.6
|
||||||
|
.SH EXAMPLE
|
||||||
|
See the ssh2_exec.c example as provided in the tarball.
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_knownhost_init(3)
|
||||||
|
.BR libssh2_knownhost_free(3)
|
||||||
|
.BR libssh2_knownhost_add(3)
|
20
docs/libssh2_knownhost_free.3
Normal file
20
docs/libssh2_knownhost_free.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\"
|
||||||
|
.\" Copyright (c) 2009 by Daniel Stenberg
|
||||||
|
.\"
|
||||||
|
.TH libssh2_knownhost_free 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_knownhost_free - free a collection of known hosts
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
void libssh2_knownhost_free(LIBSSH2_KNOWNHOSTS *hosts);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
Free a collection of known hosts.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
None.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_knownhost_init(3)
|
||||||
|
.BR libssh2_knownhost_add(3)
|
||||||
|
.BR libssh2_knownhost_check(3)
|
@@ -11,6 +11,9 @@ LIBSSH2_KNOWNHOSTS *libssh2_knownhost_init(LIBSSH2_SESSION *session);
|
|||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
Init a collection of known hosts for this session. Returns the handle to an
|
Init a collection of known hosts for this session. Returns the handle to an
|
||||||
internal representation of a known host collection.
|
internal representation of a known host collection.
|
||||||
|
|
||||||
|
Call \fBlibssh2_knownhost_free(3)\fP to free the collection again after you're
|
||||||
|
doing using it.
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Returns a handle pointer or NULL if something went wrong. The returned handle
|
Returns a handle pointer or NULL if something went wrong. The returned handle
|
||||||
is used as input to all other known host related functions libssh2 provides.
|
is used as input to all other known host related functions libssh2 provides.
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
.\"
|
.\"
|
||||||
.\" Copyright (c) 2009 by Daniel Stenberg
|
.\" Copyright (c) 2009-2011 by Daniel Stenberg
|
||||||
.\"
|
.\"
|
||||||
.TH libssh2_knownhost_readfile 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
.TH libssh2_knownhost_readfile 3 "28 May 2009" "libssh2 1.2" "libssh2 manual"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
@@ -19,8 +19,8 @@ collection of known hosts.
|
|||||||
\fILIBSSH2_KNOWNHOST_FILE_OPENSSH\fP is the only currently supported
|
\fILIBSSH2_KNOWNHOST_FILE_OPENSSH\fP is the only currently supported
|
||||||
format. This file is normally found named ~/.ssh/known_hosts
|
format. This file is normally found named ~/.ssh/known_hosts
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Returns a regular libssh2 error code, where negative values are error codes
|
Returns a negative value, a regular libssh2 error code for errors, or a
|
||||||
and 0 indicates success.
|
positive number as number of parsed known hosts in the file.
|
||||||
.SH AVAILABILITY
|
.SH AVAILABILITY
|
||||||
Added in libssh2 1.2
|
Added in libssh2 1.2
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
|
@@ -35,7 +35,7 @@ and 0 indicates success.
|
|||||||
|
|
||||||
If the provided buffer is deemed too small to fit the data libssh2 wants to
|
If the provided buffer is deemed too small to fit the data libssh2 wants to
|
||||||
store in it, LIBSSH2_ERROR_BUFFER_TOO_SMALL will be returned. The application
|
store in it, LIBSSH2_ERROR_BUFFER_TOO_SMALL will be returned. The application
|
||||||
is then adviced to call the function again with a larger buffer. The
|
is then advised to call the function again with a larger buffer. The
|
||||||
\fIoutlen\fP size will then hold the requested size.
|
\fIoutlen\fP size will then hold the requested size.
|
||||||
.SH AVAILABILITY
|
.SH AVAILABILITY
|
||||||
Added in libssh2 1.2
|
Added in libssh2 1.2
|
||||||
|
@@ -8,7 +8,9 @@ libssh2_poll - poll for activity on a socket, channel or listener
|
|||||||
|
|
||||||
int libssh2_poll(LIBSSH2_POLLFD *fds, unsigned int nfds, long timeout);
|
int libssh2_poll(LIBSSH2_POLLFD *fds, unsigned int nfds, long timeout);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
This function is deprecated. Do note use.
|
This function is deprecated. Do note use. We encourage users to instead use
|
||||||
|
the \fIpoll(3)\fP or \fIselect(3)\fP functions to check for socket activity or
|
||||||
|
when specific sockets are ready to get recevied from or send to.
|
||||||
|
|
||||||
Poll for activity on a socket, channel, listener, or any combination of these
|
Poll for activity on a socket, channel, listener, or any combination of these
|
||||||
three types. The calling semantics for this function generally match
|
three types. The calling semantics for this function generally match
|
||||||
|
19
docs/libssh2_publickey_add.3
Normal file
19
docs/libssh2_publickey_add.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_publickey_add 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_publickey_add - convenience macro for \fIlibssh2_publickey_add_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_publickey_add(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_publickey_add_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_publickey_add_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_publickey_add_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_publickey_add_ex(3)\fP
|
19
docs/libssh2_publickey_remove.3
Normal file
19
docs/libssh2_publickey_remove.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_publickey_remove 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_publickey_remove - convenience macro for \fIlibssh2_publickey_remove_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_publickey_remove(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_publickey_remove_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_publickey_remove_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_publickey_remove_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_publickey_remove_ex(3)\fP
|
@@ -13,7 +13,8 @@ libssh2_scp_recv(LIBSSH2_SESSION *session, const char *path, struct stat *sb);
|
|||||||
\fIsession\fP - Session instance as returned by
|
\fIsession\fP - Session instance as returned by
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
\fIpath\fP - Full path and filename of file to transfer
|
\fIpath\fP - Full path and filename of file to transfer. That is the remote
|
||||||
|
file name.
|
||||||
|
|
||||||
\fIsb\fP - Populated with remote file's size, mode, mtime, and atime
|
\fIsb\fP - Populated with remote file's size, mode, mtime, and atime
|
||||||
|
|
||||||
|
19
docs/libssh2_scp_send.3
Normal file
19
docs/libssh2_scp_send.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_scp_send 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_scp_send - convenience macro for \fIlibssh2_scp_send_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_scp_send(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_scp_send_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_scp_send_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_scp_send_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_scp_send_ex(3)\fP
|
49
docs/libssh2_scp_send64.3
Normal file
49
docs/libssh2_scp_send64.3
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
.\" $Id: libssh2_scp_send_ex.3,v 1.3 2009/03/17 10:34:27 bagder Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_scp_send64 3 "17 Apr 2010" "libssh2 1.2.6" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_scp_send64 - Send a file via SCP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
LIBSSH2_CHANNEL *
|
||||||
|
libssh2_scp_send64(LIBSSH2_SESSION *session, const char *path, int mode,
|
||||||
|
libssh2_uint64_t size, time_t mtime, time_t atime);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIsession\fP - Session instance as returned by
|
||||||
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
|
\fIpath\fP - Full path and filename of file to transfer to. That is the remote
|
||||||
|
file name.
|
||||||
|
|
||||||
|
\fImode\fP - File access mode to create file with
|
||||||
|
|
||||||
|
\fIsize\fP - Size of file being transmitted (Must be known ahead of
|
||||||
|
time). Note that this needs to be passed on as variable type
|
||||||
|
libssh2_uint64_t. This type is 64 bit on modern operating systems and
|
||||||
|
compilers.
|
||||||
|
|
||||||
|
\fImtime\fP - mtime to assign to file being created
|
||||||
|
|
||||||
|
\fIatime\fP - atime to assign to file being created (Set this and
|
||||||
|
mtime to zero to instruct remote host to use current time).
|
||||||
|
|
||||||
|
Send a file to the remote host via SCP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Pointer to a newly allocated LIBSSH2_CHANNEL instance, or NULL on errors.
|
||||||
|
|
||||||
|
.SH ERRORS
|
||||||
|
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SCP_PROTOCOL\fP -
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_EAGAIN\fP - Marked for non-blocking I/O but the call would
|
||||||
|
block.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
This function was added in libssh2 1.2.6 and is meant to replace the former
|
||||||
|
\fIlibssh2_scp_send_ex(3)\fP function.
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_channel_open_ex(3)
|
@@ -4,15 +4,21 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_scp_send_ex - Send a file via SCP
|
libssh2_scp_send_ex - Send a file via SCP
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
|
|
||||||
LIBSSH2_CHANNEL *
|
LIBSSH2_CHANNEL *
|
||||||
libssh2_scp_send_ex(LIBSSH2_SESSION *session, const char *path, int mode, size_t size, long mtime, long atime);
|
libssh2_scp_send_ex(LIBSSH2_SESSION *session, const char *path, int mode,
|
||||||
|
size_t size, long mtime, long atime);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
This function has been deemed deprecated since libssh2 1.2.6. See
|
||||||
|
\fIlibssh2_scp_send64(3)\fP.
|
||||||
|
|
||||||
\fIsession\fP - Session instance as returned by
|
\fIsession\fP - Session instance as returned by
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
\fIpath\fP - Full path and filename of file to transfer
|
\fIpath\fP - Full path and filename of file to transfer to. That is the remote
|
||||||
|
file name.
|
||||||
|
|
||||||
\fImode\fP - File access mode to create file with
|
\fImode\fP - File access mode to create file with
|
||||||
|
|
||||||
@@ -37,6 +43,8 @@ Pointer to a newly allocated LIBSSH2_CHANNEL instance, or NULL on errors.
|
|||||||
|
|
||||||
\fILIBSSH2_ERROR_EAGAIN\fP - Marked for non-blocking I/O but the call would
|
\fILIBSSH2_ERROR_EAGAIN\fP - Marked for non-blocking I/O but the call would
|
||||||
block.
|
block.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
This function was marked deprecated in libssh2 1.2.6 as
|
||||||
|
\fIlibssh2_scp_send64(3)\fP has been introduced to replace this function.
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_channel_open_ex(3)
|
.BR libssh2_channel_open_ex(3)
|
||||||
|
@@ -4,12 +4,16 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_session_callback_set - set a callback function
|
libssh2_session_callback_set - set a callback function
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
|
|
||||||
void *
|
void *libssh2_session_callback_set(LIBSSH2_SESSION *session,
|
||||||
libssh2_session_callback_set(LIBSSH2_SESSION *session, int cbtype, void *callback);
|
int cbtype, void *callback);
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
Sets a custom callback handler for a previously initialized session
|
||||||
|
object. Callbacks are triggered by the receipt of special packets at the
|
||||||
|
Transport layer. To disable a callback, set it to NULL.
|
||||||
|
|
||||||
\fIsession\fP - Session instance as returned by
|
\fIsession\fP - Session instance as returned by
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
@@ -17,14 +21,20 @@ libssh2_session_callback_set(LIBSSH2_SESSION *session, int cbtype, void *callbac
|
|||||||
|
|
||||||
\fIcallback\fP - Pointer to custom callback function. The prototype for
|
\fIcallback\fP - Pointer to custom callback function. The prototype for
|
||||||
this function must match the associated callback declaration macro.
|
this function must match the associated callback declaration macro.
|
||||||
|
.SH CALLBACK TYPES
|
||||||
Sets a custom callback handler for a previously initialized session
|
.IP LIBSSH2_CALLBACK_IGNORE
|
||||||
object. Callbacks are triggered by the receipt of special packets at
|
Called when a SSH_MSG_IGNORE message is received
|
||||||
the Transport layer. To disable a callback, set it to NULL.
|
.IP LIBSSH2_CALLBACK_DEBUG
|
||||||
|
Called when a SSH_MSG_DEBUG message is received
|
||||||
|
.IP LIBSSH2_CALLBACK_DISCONNECT
|
||||||
|
Called when a SSH_MSG_DISCONNECT message is received
|
||||||
|
.IP LIBSSH2_CALLBACK_MACERROR
|
||||||
|
Called when a mismatched MAC has been detected in the transport layer. If the
|
||||||
|
function returns 0, the packet will be accepted nonetheless.
|
||||||
|
.IP LIBSSH2_CALLBACK_X11
|
||||||
|
Called when an X11 connection has been accepted
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Pointer to previous callback handler. Returns NULL if no
|
Pointer to previous callback handler. Returns NULL if no prior callback
|
||||||
prior callback handler was set.
|
handler was set or the callback type was unknown.
|
||||||
|
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
19
docs/libssh2_session_disconnect.3
Normal file
19
docs/libssh2_session_disconnect.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_session_disconnect 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_session_disconnect - convenience macro for \fIlibssh2_session_disconnect_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_session_disconnect(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_session_disconnect_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_session_disconnect_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_session_disconnect_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_session_disconnect_ex(3)\fP
|
@@ -5,11 +5,21 @@
|
|||||||
libssh2_session_flag - TODO
|
libssh2_session_flag - TODO
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
int
|
int
|
||||||
libssh2_session_flag(LIBSSH2_SESSION * session, int flag, int value);
|
libssh2_session_flag(LIBSSH2_SESSION *session, int flag, int value);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
This function has no purpose and no documented flags can be set nor read.
|
Set options for the created session. \fIflag\fP is the option to set, while
|
||||||
|
\fIvalue\fP is typically set to 1 or 0 to enable or disable the option.
|
||||||
|
.SH FLAGS
|
||||||
|
.IP LIBSSH2_FLAG_SIGPIPE
|
||||||
|
If set, libssh2 will not attempt to block SIGPIPEs but will let them trigger
|
||||||
|
from the underlying socket layer.
|
||||||
|
.IP LIBSSH2_FLAG_COMPRESS
|
||||||
|
If set - before the connection negotiation is performed - libssh2 will try to
|
||||||
|
negotiate compression enabling for this connection. By default libssh2 will
|
||||||
|
not attempt to use compression.
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
0
|
Returns regular libssh2 error code.
|
||||||
.SH ERRORS
|
.SH AVAILABILITY
|
||||||
Its mere existence is an error
|
This function has existed since the age of dawn. LIBSSH2_FLAG_COMPRESS was
|
||||||
|
added in version 1.2.8.
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
|
@@ -9,7 +9,7 @@ libssh2_session_free - frees resources associated with a session instance
|
|||||||
int
|
int
|
||||||
libssh2_session_free(LIBSSH2_SESSION *session);
|
libssh2_session_free(LIBSSH2_SESSION *session);
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
Frees resources associated with a session instance. Typically called after
|
Frees all resources associated with a session instance. Typically called after
|
||||||
.BR libssh2_session_disconnect_ex(3)
|
.BR libssh2_session_disconnect_ex(3)
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Return 0 on success or negative on failure. It returns
|
Return 0 on success or negative on failure. It returns
|
||||||
|
42
docs/libssh2_session_handshake.3
Normal file
42
docs/libssh2_session_handshake.3
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
.\" $Id: libssh2_session_handshake.3,v 1.7 2009/03/16 23:25:14 bagder Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_session_handshake 3 "7 Oct 2010" "libssh2 1.2.8" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_session_handshake - perform the SSH handshake
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
libssh2_session_handshake(LIBSSH2_SESSION *session, libssh2_socket_t socket);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIsession\fP - Session instance as returned by
|
||||||
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
|
\fIsocket\fP - Connected socket descriptor. Typically a TCP connection
|
||||||
|
though the protocol allows for any reliable transport and the library will
|
||||||
|
attempt to use any berkeley socket.
|
||||||
|
|
||||||
|
Begin transport layer protocol negotiation with the connected host.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 on success, negative on failure.
|
||||||
|
.SH ERRORS
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_NONE\fP - The socket is invalid.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_BANNER_SEND\fP - Unable to send banner to remote host.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_KEX_FAILURE\fP - >Encryption key exchange with the remote
|
||||||
|
host failed.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_DISCONNECT\fP - The socket was disconnected.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_PROTO\fP - An invalid SSH protocol response was received on
|
||||||
|
the socket.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_EAGAIN\fP - Marked for non-blocking I/O but the call would block.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in 1.2.8
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_session_free(3)
|
||||||
|
.BR libssh2_session_init_ex(3)
|
19
docs/libssh2_session_init.3
Normal file
19
docs/libssh2_session_init.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_session_init 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_session_init - convenience macro for \fIlibssh2_session_init_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_session_init(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_session_init_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_session_init_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_session_init_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_session_init_ex(3)\fP
|
@@ -13,17 +13,17 @@ libssh2_session_methods(LIBSSH2_SESSION *session, int method_type);
|
|||||||
\fIsession\fP - Session instance as returned by
|
\fIsession\fP - Session instance as returned by
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
\fImethod_type\fP - One of the Method Type constants.
|
\fImethod_type\fP - one of the method type constants: LIBSSH2_METHOD_KEX,
|
||||||
|
LIBSSH2_METHOD_HOSTKEY, LIBSSH2_METHOD_CRYPT_CS, LIBSSH2_METHOD_CRYPT_SC,
|
||||||
Return the actual method negotiated for a particular transport parameter.
|
LIBSSH2_METHOD_MAC_CS, LIBSSH2_METHOD_MAC_SC, LIBSSH2_METHOD_COMP_CS,
|
||||||
|
LIBSSH2_METHOD_COMP_SC, LIBSSH2_METHOD_LANG_CS, LIBSSH2_METHOD_LANG_SC.
|
||||||
|
|
||||||
|
Returns the actual method negotiated for a particular transport parameter.
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Negotiated method or NULL if the session has not yet been started.
|
Negotiated method or NULL if the session has not yet been started.
|
||||||
|
|
||||||
.SH ERRORS
|
.SH ERRORS
|
||||||
\fILIBSSH2_ERROR_INVAL\fP - The requested method type was invalid.
|
\fILIBSSH2_ERROR_INVAL\fP - The requested method type was invalid.
|
||||||
|
|
||||||
\fILIBSSH2_ERROR_METHOD_NONE\fP -
|
\fILIBSSH2_ERROR_METHOD_NONE\fP - no method has been set
|
||||||
|
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
@@ -8,8 +8,10 @@ libssh2_session_startup - begin transport layer
|
|||||||
|
|
||||||
int
|
int
|
||||||
libssh2_session_startup(LIBSSH2_SESSION *session, int socket);
|
libssh2_session_startup(LIBSSH2_SESSION *session, int socket);
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
Starting in libssh2 version 1.2.8 this function is considered deprecated. Use
|
||||||
|
\fIlibssh2_session_handshake(3)\fP instead.
|
||||||
|
|
||||||
\fIsession\fP - Session instance as returned by
|
\fIsession\fP - Session instance as returned by
|
||||||
.BR libssh2_session_init_ex(3)
|
.BR libssh2_session_init_ex(3)
|
||||||
|
|
||||||
|
19
docs/libssh2_sftp_close.3
Normal file
19
docs/libssh2_sftp_close.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_close 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_close - convenience macro for \fIlibssh2_sftp_close_handle(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_close(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_close_handle(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_close_handle(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_close_handle(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_close_handle(3)\fP
|
19
docs/libssh2_sftp_closedir.3
Normal file
19
docs/libssh2_sftp_closedir.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_closedir 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_closedir - convenience macro for \fIlibssh2_sftp_close_handle(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_closedir(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_close_handle(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_close_handle(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_close_handle(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_close_handle(3)\fP
|
19
docs/libssh2_sftp_fsetstat.3
Normal file
19
docs/libssh2_sftp_fsetstat.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_fsetstat 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_fsetstat - convenience macro for \fIlibssh2_sftp_fstat_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_fsetstat(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_fstat_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_fstat_ex(3)\fP
|
19
docs/libssh2_sftp_fstat.3
Normal file
19
docs/libssh2_sftp_fstat.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_fstat 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_fstat - convenience macro for \fIlibssh2_sftp_fstat_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_fstat(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_fstat_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_fstat_ex(3)\fP
|
@@ -2,32 +2,88 @@
|
|||||||
.\"
|
.\"
|
||||||
.TH libssh2_sftp_fstat_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual"
|
.TH libssh2_sftp_fstat_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_fstat_ex - get or set attributes on a file handle
|
libssh2_sftp_fstat_ex - get or set attributes on an SFTP file handle
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
int
|
int
|
||||||
libssh2_sftp_fstat_ex(LIBSSH2_SFTP_HANDLE *handle, LIBSSH2_SFTP_ATTRIBUTES *attrs, int setstat)
|
libssh2_sftp_fstat_ex(LIBSSH2_SFTP_HANDLE *handle,
|
||||||
|
LIBSSH2_SFTP_ATTRIBUTES *attrs, int setstat)
|
||||||
int
|
|
||||||
libssh2_sftp_fstat(LIBSSH2_SFTP_HANDLE *handle, LIBSSH2_SFTP_ATTRIBUTES *attrs)
|
|
||||||
|
|
||||||
int
|
|
||||||
libssh2_sftp_fsetstat(LIBSSH2_SFTP_HANDLE *handle, LIBSSH2_SFTP_ATTRIBUTES *attrs)
|
|
||||||
|
|
||||||
|
#define libbssh2_sftp_fstat(handle, attrs) \\
|
||||||
|
libssh2_sftp_fstat_ex((handle), (attrs), 0)
|
||||||
|
#define libssh2_sftp_fsetstat(handle, attrs) \\
|
||||||
|
libssh2_sftp_fstat_ex((handle), (attrs), 1)
|
||||||
|
.fi
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
\fIhandle\fP - SFTP File Handle as returned by
|
\fIhandle\fP - SFTP File Handle as returned by
|
||||||
.BR libssh2_sftp_open_ex(3)
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
|
||||||
\fIattrs\fP - Pointer to attribute structure to set file metadata
|
\fIattrs\fP - Pointer to an LIBSSH2_SFTP_ATTRIBUTES structure to set file
|
||||||
from or into depending on the value of setstat.
|
metadata from or into depending on the value of setstat.
|
||||||
|
|
||||||
\fIsetstat\fP - When non-zero, the file's metadata will be updated
|
\fIsetstat\fP - When non-zero, the file's metadata will be updated
|
||||||
with the data found in attrs according to the values of attrs->flags
|
with the data found in attrs according to the values of attrs->flags
|
||||||
and other relevant member attributes.
|
and other relevant member attributes.
|
||||||
|
|
||||||
Get or Set statbuf type data for a given LIBSSH2_SFTP_HANDLE instance.
|
Get or Set statbuf type data for a given LIBSSH2_SFTP_HANDLE instance.
|
||||||
|
.SH DATA TYPES
|
||||||
|
LIBSSH2_SFTP_ATTRIBUTES is a typedefed struct that is defined as below
|
||||||
|
|
||||||
|
.nf
|
||||||
|
struct _LIBSSH2_SFTP_ATTRIBUTES {
|
||||||
|
|
||||||
|
/* If flags & ATTR_* bit is set, then the value in this
|
||||||
|
* struct will be meaningful Otherwise it should be ignored
|
||||||
|
*/
|
||||||
|
unsigned long flags;
|
||||||
|
|
||||||
|
/* size of file, in bytes */
|
||||||
|
libssh2_uint64_t filesize;
|
||||||
|
|
||||||
|
/* numerical representation of the user and group owner of
|
||||||
|
* the file
|
||||||
|
*/
|
||||||
|
unsigned long uid, gid;
|
||||||
|
|
||||||
|
/* bitmask of permissions */
|
||||||
|
unsigned long permissions;
|
||||||
|
|
||||||
|
/* access time and modified time of file */
|
||||||
|
unsigned long atime, mtime;
|
||||||
|
};
|
||||||
|
.fi
|
||||||
|
|
||||||
|
You will find a full set of defines and macros to identify flags and
|
||||||
|
permissions on the \fBlibssh2_sftp.h\fP header file, but some of the
|
||||||
|
most common ones are:
|
||||||
|
|
||||||
|
To check for specific user permissions, the set of defines are in the
|
||||||
|
pattern LIBSSH2_SFTP_S_I<action><who> where <action> is R, W or X for
|
||||||
|
read, write and excutable and <who> is USR, GRP and OTH for user,
|
||||||
|
group and other. So, you check for a user readable file, use the bit
|
||||||
|
\fILIBSSH2_SFTP_S_IRUSR\fP while you want to see if it is executable
|
||||||
|
for other, you use \fILIBSSH2_SFTP_S_IXOTH\fP and so on.
|
||||||
|
|
||||||
|
To check for specific file types, you would previously (before libssh2
|
||||||
|
1.2.5) use the standard posix S_IS***() macros, but since 1.2.5
|
||||||
|
libssh2 offers its own set of macros for this functionality:
|
||||||
|
.IP LIBSSH2_SFTP_S_ISLNK
|
||||||
|
Test for a symbolic link
|
||||||
|
.IP LIBSSH2_SFTP_S_ISREG
|
||||||
|
Test for a regular file
|
||||||
|
.IP LIBSSH2_SFTP_S_ISDIR
|
||||||
|
Test for a directory
|
||||||
|
.IP LIBSSH2_SFTP_S_ISCHR
|
||||||
|
Test for a character special file
|
||||||
|
.IP LIBSSH2_SFTP_S_ISBLK
|
||||||
|
Test for a block special file
|
||||||
|
.IP LIBSSH2_SFTP_S_ISFIFO
|
||||||
|
Test for a pipe or FIFO special file
|
||||||
|
.IP LIBSSH2_SFTP_S_ISSOCK
|
||||||
|
Test for a socket
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Return 0 on success or negative on failure. It returns
|
Return 0 on success or negative on failure. It returns
|
||||||
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
||||||
@@ -42,5 +98,9 @@ LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
|||||||
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
||||||
received on the socket, or an SFTP operation caused an errorcode to
|
received on the socket, or an SFTP operation caused an errorcode to
|
||||||
be returned by the server.
|
be returned by the server.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
This function has been around since forever, but most of the
|
||||||
|
LIBSSH2_SFTP_S_* defines were introduced in libssh2 0.14 and the
|
||||||
|
LIBSSH2_SFTP_S_IS***() macros were introduced in libssh2 1.2.5.
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_sftp_open_ex(3)
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
1
docs/libssh2_sftp_fstatvfs.3
Normal file
1
docs/libssh2_sftp_fstatvfs.3
Normal file
@@ -0,0 +1 @@
|
|||||||
|
.so man3/libssh2_sftp_statvfs.3
|
@@ -17,7 +17,7 @@ libssh2_sftp_last_error(LIBSSH2_SFTP *sftp);
|
|||||||
Returns the last error code produced by the SFTP layer. Note that this only
|
Returns the last error code produced by the SFTP layer. Note that this only
|
||||||
returns a sensible error code if libssh2 returned LIBSSH2_ERROR_SFTP_PROTOCOL
|
returns a sensible error code if libssh2 returned LIBSSH2_ERROR_SFTP_PROTOCOL
|
||||||
in a previous call. Using \fBlibssh2_sftp_last_error(3)\fP without a
|
in a previous call. Using \fBlibssh2_sftp_last_error(3)\fP without a
|
||||||
preceeding SFTP protocol error, it will return an unspecified value.
|
preceding SFTP protocol error, it will return an unspecified value.
|
||||||
|
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Current error code state of the SFTP instance.
|
Current error code state of the SFTP instance.
|
||||||
|
19
docs/libssh2_sftp_lstat.3
Normal file
19
docs/libssh2_sftp_lstat.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_lstat 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_lstat - convenience macro for \fIlibssh2_sftp_stat_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_lstat(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_stat_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_stat_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_stat_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_stat_ex(3)\fP
|
19
docs/libssh2_sftp_mkdir.3
Normal file
19
docs/libssh2_sftp_mkdir.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_mkdir 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_mkdir - convenience macro for \fIlibssh2_sftp_mkdir_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_mkdir(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_mkdir_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_mkdir_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_mkdir_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_mkdir_ex(3)\fP
|
19
docs/libssh2_sftp_open.3
Normal file
19
docs/libssh2_sftp_open.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_open 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_open - convenience macro for \fIlibssh2_sftp_open_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_open(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_open_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_open_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_open_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_open_ex(3)\fP
|
@@ -4,31 +4,45 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_open - open filehandle for file on SFTP.
|
libssh2_sftp_open - open filehandle for file on SFTP.
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
LIBSSH2_SFTP_HANDLE *
|
LIBSSH2_SFTP_HANDLE *
|
||||||
libssh2_sftp_open_ex(LIBSSH2_SFTP *sftp, const char *filename, unsigned int filename_len, unsigned long flags, long mode, int open_type);
|
libssh2_sftp_open_ex(LIBSSH2_SFTP *sftp, const char *filename,
|
||||||
|
unsigned int filename_len, unsigned long flags,
|
||||||
LIBSSH2_SFTP_HANDLE *
|
long mode, int open_type);
|
||||||
libssh2_sftp_open(LIBSSH2_SFTP *sftp, const char *filename, unsigned long flags, long mode);
|
|
||||||
|
|
||||||
LIBSSH2_SFTP_HANDLE *
|
|
||||||
libssh2_sftp_opendir(LIBSSH2_SFTP *sftp, const char *path);
|
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
\fIsftp\fP - SFTP instance as returned by
|
\fIsftp\fP - SFTP instance as returned by \fIlibssh2_sftp_init(3)\fP
|
||||||
.BR libssh2_sftp_init(3)
|
|
||||||
|
|
||||||
\fIfilename\fP - Remote file/directory resource to open
|
\fIfilename\fP - Remote file/directory resource to open
|
||||||
|
|
||||||
\fIfilename_len\fP - Length of filename
|
\fIfilename_len\fP - Length of filename
|
||||||
|
|
||||||
\fIflags\fP - Any (reasonable) combination of the LIBSSH2_FXF_* constants
|
\fIflags\fP - Any reasonable combination of the LIBSSH2_FXF_* constants:
|
||||||
corresponding fopen modes.
|
.RS
|
||||||
|
.IP LIBSSH2_FXF_READ
|
||||||
|
Open the file for reading.
|
||||||
|
.IP LIBSSH2_FXF_WRITE
|
||||||
|
Open the file for writing. If both this and LIBSSH2_FXF_READ are specified,
|
||||||
|
the file is opened for both reading and writing.
|
||||||
|
.IP LIBSSH2_FXF_APPEND
|
||||||
|
Force all writes to append data at the end of the file.
|
||||||
|
.IP LIBSSH2_FXF_CREAT,
|
||||||
|
If this flag is specified, then a new file will be created if one does not
|
||||||
|
already exist (if LIBSSH2_FXF_TRUNC is specified, the new file will be
|
||||||
|
truncated to zero length if it previously exists)
|
||||||
|
.IP LIBSSH2_FXF_TRUNC
|
||||||
|
Forces an existing file with the same name to be truncated to zero length when
|
||||||
|
creating a file by specifying LIBSSH2_FXF_CREAT. LIBSSH2_FXF_CREAT MUST also
|
||||||
|
be specified if this flag is used.
|
||||||
|
.IP LIBSSH2_FXF_EXCL
|
||||||
|
Causes the request to fail if the named file already exists.
|
||||||
|
LIBSSH2_FXF_CREAT MUST also be specified if this flag is used.
|
||||||
|
|
||||||
|
.RE
|
||||||
\fImode\fP - POSIX file permissions to assign if the file is being newly
|
\fImode\fP - POSIX file permissions to assign if the file is being newly
|
||||||
created.
|
created. See the LIBSSH2_SFTP_S_* convenience defines in <libssh2_sftp.h>
|
||||||
|
|
||||||
\fIopen_type\fP - Either of LIBSSH2_SFTP_OPENFILE (to open a file) or
|
\fIopen_type\fP - Either of LIBSSH2_SFTP_OPENFILE (to open a file) or
|
||||||
LIBSSH2_SFTP_OPENDIR (to open a directory).
|
LIBSSH2_SFTP_OPENDIR (to open a directory).
|
||||||
|
19
docs/libssh2_sftp_opendir.3
Normal file
19
docs/libssh2_sftp_opendir.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_opendir 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_opendir - convenience macro for \fIlibssh2_sftp_open_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_opendir(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_open_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_open_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_open_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_open_ex(3)\fP
|
19
docs/libssh2_sftp_readdir.3
Normal file
19
docs/libssh2_sftp_readdir.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_readdir 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_readdir - convenience macro for \fIlibssh2_sftp_readdir_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_readdir(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_readdir_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_readdir_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_readdir_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_readdir_ex(3)\fP
|
@@ -4,16 +4,19 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_readdir_ex - read directory data from an SFTP handle
|
libssh2_sftp_readdir_ex - read directory data from an SFTP handle
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
int
|
int
|
||||||
libssh2_sftp_readdir_ex(LIBSSH2_SFTP_HANDLE *handle, char *buffer, size_t buffer_maxlen, char *longentry, size_t longentry_maxlen, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
libssh2_sftp_readdir_ex(LIBSSH2_SFTP_HANDLE *handle,
|
||||||
|
char *buffer, size_t buffer_maxlen,
|
||||||
int
|
char *longentry, size_t longentry_maxlen,
|
||||||
libssh2_sftp_readdir(LIBSSH2_SFTP_HANDLE *handle, char *buffer, size_t buffer_maxlen, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
Reads a block of data from a LIBSSH2_SFTP_HANDLE and returns file entry
|
||||||
|
information for the next entry, if any.
|
||||||
|
|
||||||
\fIhandle\fP - is the SFTP File Handle as returned by
|
\fIhandle\fP - is the SFTP File Handle as returned by
|
||||||
.BR libssh2_sftp_open_ex(3)
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
|
||||||
@@ -25,25 +28,26 @@ filename is longer than the space provided by buffer_maxlen it will be
|
|||||||
truncated to fit.
|
truncated to fit.
|
||||||
|
|
||||||
\fIlongentry\fP - is a pointer to a pre-allocated buffer of at least
|
\fIlongentry\fP - is a pointer to a pre-allocated buffer of at least
|
||||||
\fIlongentry_maxlen\fP bytes to read data into.
|
\fIlongentry_maxlen\fP bytes to read data into. The format of the `longname'
|
||||||
|
field is unspecified by SFTP protocol. It MUST be suitable for use in the
|
||||||
|
output of a directory listing command (in fact, the recommended operation for
|
||||||
|
a directory listing command is to simply display this data).
|
||||||
|
|
||||||
\fIlongentry_maxlen\fP - is the length of longentry in bytes. If the length
|
\fIlongentry_maxlen\fP - is the length of longentry in bytes. If the length of
|
||||||
of the full directory entry is longer than the space provided by
|
the full directory entry is longer than the space provided by
|
||||||
longentry_maxlen it will be truncated to fit.
|
\fIlongentry_maxlen\fP it will be truncated to fit.
|
||||||
|
|
||||||
\fIattrs\fP - is a pointer to LIBSSH2_SFTP_ATTRIBUTES storage to populate
|
\fIattrs\fP - is a pointer to LIBSSH2_SFTP_ATTRIBUTES storage to populate
|
||||||
statbuf style data into.
|
statbuf style data into.
|
||||||
|
|
||||||
Read a block of data from a LIBSSH2_SFTP_HANDLE. This method is modeled
|
|
||||||
after the POSIX
|
|
||||||
.BR readdir(2)
|
|
||||||
however, it uses a variable sized directory entry (filename) buffer and
|
|
||||||
returns statbuf type data in the same call.
|
|
||||||
|
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Number of bytes actually populated into buffer, or negative on failure. It
|
Number of bytes actually populated into buffer (not counting the terminating
|
||||||
returns LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
zero), or negative on failure. It returns LIBSSH2_ERROR_EAGAIN when it would
|
||||||
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
otherwise block. While LIBSSH2_ERROR_EAGAIN is a negative number, it isn't
|
||||||
|
really a failure per se.
|
||||||
|
.SH BUG
|
||||||
|
Passing in a too small buffer for 'buffer' or 'longentry' when receiving data
|
||||||
|
only results in libssh2 1.2.7 or earlier to not copy the entire data amount,
|
||||||
|
and it is not possible for the application to tell when it happens!
|
||||||
.SH ERRORS
|
.SH ERRORS
|
||||||
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
||||||
|
|
||||||
@@ -54,6 +58,10 @@ LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
|||||||
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
||||||
received on the socket, or an SFTP operation caused an errorcode to be
|
received on the socket, or an SFTP operation caused an errorcode to be
|
||||||
returned by the server.
|
returned by the server.
|
||||||
|
|
||||||
|
From 1.2.8, LIBSSH2_ERROR_BUFFER_TOO_SMALL is returned if any of the
|
||||||
|
given 'buffer' or 'longentry' buffers are too small to fit the requested
|
||||||
|
object name.
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_sftp_open_ex(3),
|
.BR libssh2_sftp_open_ex(3),
|
||||||
.BR libssh2_sftp_close_handle(3)
|
.BR libssh2_sftp_close_handle(3)
|
||||||
|
21
docs/libssh2_sftp_readlink.3
Normal file
21
docs/libssh2_sftp_readlink.3
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_readlink 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_readlink - convenience macro for \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define libssh2_sftp_readlink(sftp, path, target, maxlen) \\
|
||||||
|
libssh2_sftp_symlink_ex((sftp), (path), strlen(path), (target), (maxlen), \\
|
||||||
|
LIBSSH2_SFTP_READLINK)
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_symlink_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_symlink_ex(3)\fP
|
21
docs/libssh2_sftp_realpath.3
Normal file
21
docs/libssh2_sftp_realpath.3
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_realpath 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_realpath - convenience macro for \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define libssh2_sftp_realpath(sftp, path, target, maxlen) \\
|
||||||
|
libssh2_sftp_symlink_ex((sftp), (path), strlen(path), (target), (maxlen), \\
|
||||||
|
LIBSSH2_SFTP_REALPATH)
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_symlink_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_symlink_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_symlink_ex(3)\fP
|
19
docs/libssh2_sftp_rename.3
Normal file
19
docs/libssh2_sftp_rename.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_rename 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_rename - convenience macro for \fIlibssh2_sftp_rename_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_rename(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_rename_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_rename_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_rename_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_rename_ex(3)\fP
|
19
docs/libssh2_sftp_rewind.3
Normal file
19
docs/libssh2_sftp_rewind.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_rewind 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_rewind - convenience macro for \fIlibssh2_sftp_seek64(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_rewind(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_seek64(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_seek64(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_seek64(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_seek64(3)\fP
|
20
docs/libssh2_sftp_rmdir.3
Normal file
20
docs/libssh2_sftp_rmdir.3
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_rmdir 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_rmdir - convenience macro for \fIlibssh2_sftp_rmdir_ex(3)\fP
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
#define libssh2_sftp_rmdir(sftp, path) \\
|
||||||
|
libssh2_sftp_rmdir_ex((sftp), (path), strlen(path))
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_rmdir_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_rmdir_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_rmdir_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_rmdir_ex(3)\fP
|
@@ -4,30 +4,26 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_rmdir_ex - remove an SFTP directory
|
libssh2_sftp_rmdir_ex - remove an SFTP directory
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
int
|
int libssh2_sftp_rmdir_ex(LIBSSH2_SFTP *sftp, const char *path,
|
||||||
libssh2_sftp_rmdir_ex(LIBSSH2_SFTP *sftp, const char *path, unsigned int path_len);
|
unsigned int path_len);
|
||||||
|
|
||||||
int
|
|
||||||
libssh2_sftp_rmdir_ex(LIBSSH2_SFTP *sftp, const char *path);
|
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
Remove a directory from the remote file system.
|
||||||
|
|
||||||
\fIsftp\fP - SFTP instance as returned by
|
\fIsftp\fP - SFTP instance as returned by
|
||||||
.BR libssh2_sftp_init(3)
|
.BR libssh2_sftp_init(3)
|
||||||
|
|
||||||
\fIsourcefile\fP - Full path of the existing directory to remove.
|
\fIsourcefile\fP - Full path of the existing directory to remove.
|
||||||
|
|
||||||
\fIsourcefile_len\fP - Length of the full path of the existing directory to remove.
|
\fIsourcefile_len\fP - Length of the full path of the existing directory to
|
||||||
|
remove.
|
||||||
Remove a directory from the remote file system.
|
|
||||||
|
|
||||||
.SH RETURN VALUE
|
.SH RETURN VALUE
|
||||||
Return 0 on success or negative on failure. It returns
|
Return 0 on success or negative on failure. It returns
|
||||||
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
||||||
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
||||||
|
|
||||||
.SH ERRORS
|
.SH ERRORS
|
||||||
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
||||||
|
|
||||||
@@ -38,6 +34,5 @@ LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
|||||||
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
||||||
received on the socket, or an SFTP operation caused an errorcode to
|
received on the socket, or an SFTP operation caused an errorcode to
|
||||||
be returned by the server.
|
be returned by the server.
|
||||||
|
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_sftp_init(3)
|
.BR libssh2_sftp_init(3)
|
||||||
|
@@ -4,16 +4,14 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_seek - set the read/write position indicator within a file
|
libssh2_sftp_seek - set the read/write position indicator within a file
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
void
|
void libssh2_sftp_seek(LIBSSH2_SFTP_HANDLE *handle, size_t offset);
|
||||||
libssh2_sftp_seek(LIBSSH2_SFTP_HANDLE *handle, size_t offset);
|
|
||||||
|
|
||||||
void
|
|
||||||
libssh2_sftp_seek64(LIBSSH2_SFTP_HANDLE *handle, libssh2_uint64_t offset);
|
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
Deprecated function. Use \fIlibssh2_sftp_seek64(3)\fP instead!
|
||||||
|
|
||||||
\fIhandle\fP - SFTP File Handle as returned by
|
\fIhandle\fP - SFTP File Handle as returned by
|
||||||
.BR libssh2_sftp_open_ex(3)
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
|
||||||
@@ -24,7 +22,6 @@ Note that libssh2 implements file pointers as a localized concept to make
|
|||||||
file access appear more POSIX like. No packets are exchanged with the server
|
file access appear more POSIX like. No packets are exchanged with the server
|
||||||
during a seek operation. The localized file pointer is simply used as a
|
during a seek operation. The localized file pointer is simply used as a
|
||||||
convenience offset during read/write operations.
|
convenience offset during read/write operations.
|
||||||
.SH AVAILABILITY
|
|
||||||
libssh2_sftp_seek64(3) was added in 1.0
|
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_sftp_open_ex(3)
|
.BR libssh2_sftp_open_ex(3),
|
||||||
|
.BR libssh2_sftp_seek64(3)
|
||||||
|
31
docs/libssh2_sftp_seek64.3
Normal file
31
docs/libssh2_sftp_seek64.3
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
.\" $Id: libssh2_sftp_seek.3,v 1.5 2009/03/17 10:34:27 bagder Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_seek64 3 "22 Dec 2008" "libssh2 1.0" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_seek64 - set the read/write position within a file
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
|
void libssh2_sftp_seek64(LIBSSH2_SFTP_HANDLE *handle,
|
||||||
|
libssh2_uint64_t offset);
|
||||||
|
.SH DESCRIPTION
|
||||||
|
\fIhandle\fP - SFTP File Handle as returned by
|
||||||
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
|
||||||
|
\fIoffset\fP - Number of bytes from the beginning of file to seek to.
|
||||||
|
|
||||||
|
Move the file handle's internal pointer to an arbitrary location. libssh2
|
||||||
|
implements file pointers as a localized concept to make file access appear
|
||||||
|
more POSIX like. No packets are exchanged with the server during a seek
|
||||||
|
operation. The localized file pointer is simply used as a convenience offset
|
||||||
|
during read/write operations.
|
||||||
|
|
||||||
|
You MUST NOT seek during writing or reading a file with SFTP, as the internals
|
||||||
|
use outstanding packets and changing the "file position" during transit will
|
||||||
|
results in badness.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in 1.0
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_sftp_open_ex(3)
|
19
docs/libssh2_sftp_setstat.3
Normal file
19
docs/libssh2_sftp_setstat.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_setstat 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_setstat - convenience macro for \fIlibssh2_sftp_stat_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_setstat(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_stat_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_stat_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_stat_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_stat_ex(3)\fP
|
19
docs/libssh2_sftp_stat.3
Normal file
19
docs/libssh2_sftp_stat.3
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
.\" $Id: template.3,v 1.4 2007/06/13 16:41:33 jehousley Exp $
|
||||||
|
.\"
|
||||||
|
.TH libssh2_sftp_stat 3 "20 Feb 2010" "libssh2 1.2.4" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_stat - convenience macro for \fIlibssh2_sftp_fstat_ex(3)\fP calls
|
||||||
|
.SH SYNOPSIS
|
||||||
|
#include <libssh2.h>
|
||||||
|
|
||||||
|
libssh2_sftp_stat(arguments)
|
||||||
|
|
||||||
|
.SH DESCRIPTION
|
||||||
|
This is a macro defined in a public libssh2 header file that is using the
|
||||||
|
underlying function \fIlibssh2_sftp_fstat_ex(3)\fP.
|
||||||
|
.SH RETURN VALUE
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH ERRORS
|
||||||
|
See \fIlibssh2_sftp_fstat_ex(3)\fP
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR \fIlibssh2_sftp_fstat_ex(3)\fP
|
@@ -4,49 +4,64 @@
|
|||||||
.SH NAME
|
.SH NAME
|
||||||
libssh2_sftp_stat_ex - get status about an SFTP file
|
libssh2_sftp_stat_ex - get status about an SFTP file
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
#include <libssh2.h>
|
#include <libssh2.h>
|
||||||
#include <libssh2_sftp.h>
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
int
|
int libssh2_sftp_stat_ex(LIBSSH2_SFTP *sftp, const char *path,
|
||||||
libssh2_sftp_stat_ex(LIBSSH2_SFTP *sftp, const char *path, unsigned int path_len, int stat_type, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
unsigned int path_len, int stat_type,
|
||||||
|
LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
||||||
int
|
|
||||||
libssh2_sftp_stat(LIBSSH2_SFTP *sftp, const char *path, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
|
||||||
|
|
||||||
int
|
|
||||||
libssh2_sftp_lstat(LIBSSH2_SFTP *sftp, const char *path, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
|
||||||
|
|
||||||
int
|
|
||||||
libssh2_sftp_setstat(LIBSSH2_SFTP *sftp, const char *path, LIBSSH2_SFTP_ATTRIBUTES *attrs);
|
|
||||||
|
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
\fIsftp\fP - SFTP instance as returned by
|
\fIsftp\fP - SFTP instance as returned by
|
||||||
.BR libssh2_sftp_init(3)
|
.BR libssh2_sftp_init(3)
|
||||||
|
|
||||||
\fIpath\fP - Remote filesystem object to stat/lstat/setstat.
|
\fIpath\fP - Remote filesystem object to stat/lstat/setstat.
|
||||||
|
|
||||||
\fIpath_len\fP - Lenght of the name of the remote filesystem object
|
\fIpath_len\fP - Length of the name of the remote filesystem object
|
||||||
to stat/lstat/setstat.
|
to stat/lstat/setstat.
|
||||||
|
|
||||||
\fIstat_type\fP - One of the three constants specifying the type of
|
\fIstat_type\fP - One of the three constants specifying the type of
|
||||||
stat operation to perform.
|
stat operation to perform:
|
||||||
|
|
||||||
\fIattrs\fP - Pointer to attribute structure to set file metadata
|
.br
|
||||||
from or into depending on the value of stat_type.
|
\fBLIBSSH2_SFTP_STAT\fP: performs stat(2) operation
|
||||||
|
.br
|
||||||
|
\fBLIBSSH2_SFTP_LSTAT\fP: performs lstat(2) operation
|
||||||
|
.br
|
||||||
|
\fBLIBSSH2_SFTP_SETSTAT\fP: performs operation to set stat info on file
|
||||||
|
|
||||||
Get or Set statbuf type data on a remote filesystem object. When
|
\fIattrs\fP - Pointer to a \fBLIBSSH2_SFTP_ATTRIBUTES\fP structure to set file
|
||||||
getting statbuf data,
|
metadata from or into depending on the value of stat_type.
|
||||||
|
|
||||||
|
Get or Set statbuf type data on a remote filesystem object. When getting
|
||||||
|
statbuf data,
|
||||||
.BR libssh2_sftp_stat(3)
|
.BR libssh2_sftp_stat(3)
|
||||||
will follow all symlinks, while
|
will follow all symlinks, while
|
||||||
.BR libssh2_sftp_lstat(3)
|
.BR libssh2_sftp_lstat(3)
|
||||||
will return data about the object encountered, even if that object
|
will return data about the object encountered, even if that object
|
||||||
happens to be a symlink.
|
happens to be a symlink.
|
||||||
|
|
||||||
.SH RETURN VALUE
|
The LIBSSH2_SFTP_ATTRIBUTES struct looks like this:
|
||||||
Return 0 on success or negative on failure. It returns
|
|
||||||
LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
|
||||||
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
|
||||||
|
|
||||||
|
.nf
|
||||||
|
struct LIBSSH2_SFTP_ATTRIBUTES {
|
||||||
|
/* If flags & ATTR_* bit is set, then the value in this struct will be
|
||||||
|
* meaningful Otherwise it should be ignored
|
||||||
|
*/
|
||||||
|
unsigned long flags;
|
||||||
|
|
||||||
|
libssh2_uint64_t filesize;
|
||||||
|
unsigned long uid;
|
||||||
|
unsigned long gid;
|
||||||
|
unsigned long permissions;
|
||||||
|
unsigned long atime;
|
||||||
|
unsigned long mtime;
|
||||||
|
};
|
||||||
|
.fi
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 on success or negative on failure. It returns LIBSSH2_ERROR_EAGAIN
|
||||||
|
when it would otherwise block. While LIBSSH2_ERROR_EAGAIN is a negative
|
||||||
|
number, it isn't really a failure per se.
|
||||||
.SH ERRORS
|
.SH ERRORS
|
||||||
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
||||||
|
|
||||||
@@ -57,6 +72,5 @@ LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
|||||||
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
||||||
received on the socket, or an SFTP operation caused an errorcode to
|
received on the socket, or an SFTP operation caused an errorcode to
|
||||||
be returned by the server.
|
be returned by the server.
|
||||||
|
|
||||||
.SH SEE ALSO
|
.SH SEE ALSO
|
||||||
.BR libssh2_sftp_init(3)
|
.BR libssh2_sftp_init(3)
|
||||||
|
79
docs/libssh2_sftp_statvfs.3
Normal file
79
docs/libssh2_sftp_statvfs.3
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
.TH libssh2_sftp_statvfs 3 "22 May 2010" "libssh2 1.2.6" "libssh2 manual"
|
||||||
|
.SH NAME
|
||||||
|
libssh2_sftp_statvfs, libssh2_sftp_fstatvfs - get file system statistics
|
||||||
|
.SH SYNOPSIS
|
||||||
|
.nf
|
||||||
|
#include <libssh2.h>
|
||||||
|
#include <libssh2_sftp.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
libssh2_sftp_statvfs(LIBSSH2_SFTP *sftp, const char *path,
|
||||||
|
size_t path_len, LIBSSH2_SFTP_STATVFS *st);
|
||||||
|
|
||||||
|
int
|
||||||
|
libssh2_sftp_fstatvfs(LIBSSH2_SFTP_HANDLE *handle,
|
||||||
|
LIBSSH2_SFTP_STATVFS *st)
|
||||||
|
.fi
|
||||||
|
.SH DESCRIPTION
|
||||||
|
These functions provide statvfs(2)-like operations and require
|
||||||
|
statvfs@openssh.com and fstatvfs@openssh.com extension support on the server.
|
||||||
|
|
||||||
|
\fIsftp\fP - SFTP instance as returned by
|
||||||
|
.BR libssh2_sftp_init(3)
|
||||||
|
|
||||||
|
\fIhandle\fP - SFTP File Handle as returned by
|
||||||
|
.BR libssh2_sftp_open_ex(3)
|
||||||
|
|
||||||
|
\fIpath\fP - full path of any file within the mounted file system.
|
||||||
|
|
||||||
|
\fIpath_len\fP - length of the full path.
|
||||||
|
|
||||||
|
\fIst\fP - Pointer to a LIBSSH2_SFTP_STATVFS structure to place file system
|
||||||
|
statistics into.
|
||||||
|
|
||||||
|
.SH DATA TYPES
|
||||||
|
LIBSSH2_SFTP_STATVFS is a typedefed struct that is defined as below
|
||||||
|
|
||||||
|
.nf
|
||||||
|
struct _LIBSSH2_SFTP_STATVFS {
|
||||||
|
libssh2_uint64_t f_bsize; /* file system block size */
|
||||||
|
libssh2_uint64_t f_frsize; /* fragment size */
|
||||||
|
libssh2_uint64_t f_blocks; /* size of fs in f_frsize units */
|
||||||
|
libssh2_uint64_t f_bfree; /* # free blocks */
|
||||||
|
libssh2_uint64_t f_bavail; /* # free blocks for non-root */
|
||||||
|
libssh2_uint64_t f_files; /* # inodes */
|
||||||
|
libssh2_uint64_t f_ffree; /* # free inodes */
|
||||||
|
libssh2_uint64_t f_favail; /* # free inodes for non-root */
|
||||||
|
libssh2_uint64_t f_fsid; /* file system ID */
|
||||||
|
libssh2_uint64_t f_flag; /* mount flags */
|
||||||
|
libssh2_uint64_t f_namemax; /* maximum filename length */
|
||||||
|
};
|
||||||
|
.fi
|
||||||
|
|
||||||
|
It is unspecified whether all members of the returned struct have meaningful
|
||||||
|
values on all file systems.
|
||||||
|
|
||||||
|
The field \fIf_flag\fP is a bit mask. Bits are defined as follows:
|
||||||
|
.IP LIBSSH2_SFTP_ST_RDONLY
|
||||||
|
Read-only file system.
|
||||||
|
.IP LIBSSH2_SFTP_ST_NOSUID
|
||||||
|
Set-user-ID/set-group-ID bits are ignored by \fBexec\fP(3).
|
||||||
|
|
||||||
|
.SH RETURN VALUE
|
||||||
|
Returns 0 on success or negative on failure. If used in non-blocking mode, it
|
||||||
|
returns LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
|
||||||
|
LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
|
||||||
|
.SH ERRORS
|
||||||
|
\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP -
|
||||||
|
|
||||||
|
\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
|
||||||
|
received on the socket, or an SFTP operation caused an errorcode to be returned
|
||||||
|
by the server.
|
||||||
|
.SH AVAILABILITY
|
||||||
|
Added in libssh2 1.2.6
|
||||||
|
.SH SEE ALSO
|
||||||
|
.BR libssh2_sftp_open_ex(3)
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user