Bernabee Gonzalez
05/09/2024, 6:31 PMFTP_CANNOT_ESTABLISH_CONNECTION
Bernabee Gonzalez
05/09/2024, 6:31 PM{
type: "error.SuiteScriptError",
name: "FTP_CANNOT_ESTABLISH_CONNECTION",
message: "Could not establish connection to No more authentication methods available.",
id: "",
stack: [
"Error\n at Object.execute (/SuiteScripts/SDB-TR-INIT-CONNECT-SFPT.js:25:38)"
],
cause: {
type: "internal error",
code: "FTP_CANNOT_ESTABLISH_CONNECTION",
details: "Could not establish connection to No more authentication methods available.",
userEvent: null,
stackTrace: [
"Error\n at Object.execute (/SuiteScripts/SDB-TR-INIT-CONNECT-SFPT.js:25:38)"
],
notifyOff: false
},
notifyOff: false,
userFacing: true
}
Corey Schwoebel
05/09/2024, 6:44 PMBernabee Gonzalez
05/09/2024, 6:47 PMconst execute = (scriptContext) => {
const scriptObj = runtime.getCurrentScript();
// let connection = GetSFTPConnection(scriptObj);
var username ='test-dev';
var url = 'test-test';
var hostKey = 'AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBELYopkHc6vi++AqprGSo00zclDui4Ywj08QrnZgkLOF9v8PX8nlNErFMpnq9XyDGhYTKcWK/NtmeHYJIeQ89XM=';
var passwordGuid = '7c7ad4b42ef8482db8e7febb9aaf815e';
var directory = '/';
var port = 22;
var objConnextion = sftp.createConnection({
username: username,
passwordGuid: passwordGuid,
url: url,
directory: directory,
hostKey: hostKey,
port: port,
});
log.debug('objConnextion', objConnextion);
// if (!connection) return [];
// let listFiles = connection.list({
// path: "",
// sort: sftp.Sort.DATE_DESC,
// });
}
Bernabee Gonzalez
05/09/2024, 6:48 PMCorey Schwoebel
05/09/2024, 6:54 PMBernabee Gonzalez
05/09/2024, 7:05 PMBernabee Gonzalez
05/09/2024, 7:05 PMbattk
05/09/2024, 7:17 PMCorey Schwoebel
05/09/2024, 7:17 PMCorey Schwoebel
05/09/2024, 7:21 PMBernabee Gonzalez
05/09/2024, 7:26 PMCharan
06/20/2024, 8:52 PMlet connection = sftp.createConnection({
username: 'test_sftp_user_12345',
secret: 'custsecret_files_password',
url: '<http://test.files.com|test.files.com>',
hostKey: creds.hostKeys["<http://files.com|files.com>"]
});
Charan
06/20/2024, 8:53 PMBernabee Gonzalez
06/20/2024, 8:54 PM