I also tried to use libssh as a backend (rather than libssh2), and I'm getting a segfault. Here's the backtrace:
#0 0x0000000000000071 in ?? () #1 0x00007ffff689c41a in EVP_MD_CTX_cleanup () from /lib/x86_64-linux-gnu/libcrypto.so.1.0.0 #2 0x00007ffff68068d7 in HMAC_CTX_cleanup () from /lib/x86_64-linux-gnu/libcrypto.so.1.0.0 #3 0x00007ffff7b82191 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #4 0x00007ffff7b7fc13 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #5 0x00007ffff7b806f6 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #6 0x00007ffff7b7f638 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #7 0x00007ffff7b7a15e in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #8 0x00007ffff7b7f056 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #9 0x00007ffff7b87b7d in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #10 0x00007ffff7b880e3 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #11 0x00007ffff7b90662 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #12 0x00007ffff7b8d0ac in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #13 0x00007ffff7b8e009 in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #14 0x00007ffff7b8e0dd in ?? () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #15 0x00007ffff7b7aae4 in ssh_connect () from /usr/lib/x86_64-linux-gnu/libssh.so.4 #16 0x00005555555e6bfe in myssh_statemach_act () #17 0x00005555555e9c96 in myssh_multi_statemach () #18 0x00005555555c1266 in multi_runsingle () #19 0x00005555555c2414 in curl_multi_perform () #20 0x00005555555bc204 in curl_easy_perform () #21 0x00005555555b9fb3 in main () at router_fw_dump.cpp:83 I'm using libcurl 7.58. 2018-07-03 17:28 GMT-03:00 Martin Galvan <[email protected]>: > Hi all, > > I have a Cisco switch that I'm trying to copy files from through SCP. > While I'm using libcurl, essentially what I'm doing is: > > curl -v scp://cisco/flash:/someFile -u user:pass -k > > The output is: > > * TCP_NODELAY set > * Connected to 172.16.0.190 (172.16.0.190) port 22 (#0) > * SSH MD5 fingerprint: dcabc9f67a498c9faafdc7cfe5673274 > * SSH authentication methods available: keyboard-interactive,password > * Initialized password authentication > * Authentication complete > * SSH CONNECT phase done > * Failed to recv file > * Connection #0 to host 172.16.0.190 left intact > curl: (78) Failed to recv file > > Using regular SCP works fine. However, the switch's SSH implementation > is ancient, and I have to pass > -oKexAlgorithms=+diffie-hellman-group1-sha1 to scp for the connection > to work. I don't think this is the problem, though, because of the > "SSH CONNECT phase done" message. > > I saw that Mike Gibson was having this same problem back in 2013. It > looks like his issue was on the -p option used by libssh2: > > https://curl.haxx.se/mail/lib-2013-08/0125.html > > However, he didn't post any updates. Doing scp -p doesn't work (I get > an error saying "-p -r -d options not supported"), so maybe I'm having > the same issue as he did. The switch isn't showing any logs related to > SCP as Mike's did, though. > > From that thread, the solution seems to be to somehow make > curl/libcurl not use -p. How can I do this? ------------------------------------------------------------------- Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.html
