On 03/04/2011 12:16 PM, Aris Adamantiadis wrote:
Le 04/03/11 12:09, Pierre-Yves Fontaniere a écrit :
My program simply :
- Initialize a session.
- Verify the remote server/key matching.
- Test if pubkey authentication is ok for the remote server.
- Create a private key from the file.
- Calculate public key from the private key.
- Offer this pubkey to the remote server.
- Try to authenticate with this pubkey. And it failed here.
Hi Pierre-Yves,
Could you copy/paste the relevant part of your code ? It would help to
understand what can go wrong.
I went a little further in debugging and found that "packet_decrypt" in
crypt.c returns a -1 before any logging on a malloc error trying to
allocate a buffer of 0 bytes.
In the AIX documentation, i found that :
"If the size requested is 0, *malloc* returns NULL in normal
circumstances. However, if the program was compiled with the defined
*_LINUX_SOURCE_COMPAT* macro, *malloc* returns a valid pointer to a
space of size 0."
So : libssh requires a valid pointer or not ? :)
Pierre-yves