I'm trying to use SSH External (from Trevor Devore github). If this code :
Code: Select all
on loginCheck
   local sUsername, sPassword, shost, sport, ssh_session, resultado, indice
   -- delete stack "rnacrockfordExternalWrapper"
   set the visible of the templateStack to false
   set the name of the templateStack to "rnacrockfordExternalWrapper"
   set the externals of the templateStack to "/home/myuserr/livecode/libs/ssh/binaries/livessh.so"
  create stack
start using stack "rnacrockfordExternalWrapper"
   put "userlogin" into sUsername
   put "passwordlogin" into sPassword
   put "sshhostip" into shost
   put "sshserverport" into sport
   put "Found these external functions" & cr & cr & the externalfunctions of stack "rnacrockfordExternalWrapper" into field "datos_ext"
   put ssh_new() into ssh_session
    ssh_options_set ssh_session, "host", shost
   ssh_options_set ssh_session, "port", sport
   ssh_connect ssh_session
   /*put ssh_userauth_password(ssh_session, sUsername, sPassword) into authResult*/
   put ssh_userauth_password(ssh_session, sUsername, sPassword) into resultado
   livessh_run_command ssh_session, "ls", "outVar"
   /* put outVar into field "LogField"*/
    ssh_disconnect ssh_session
   ssh_free ssh_session
end loginCheck
card "login": execution error at line 23 (Function: error in function handler) near "ssh_new", char 8
When running the ssh external github demo connection.livecode (sorry, my account hsa no rights to put web links) it works without problem.
I searched for a while in forums and the net without positive result (I think that ssh external is a very precious addon to livecode, but it's not well documented and seems that is not heavily used). This error is driving me mad 'cause all my livecode project is based in the ssh communication. Anyone could help me to understand the error root? Many thanks in advance, really.