cancel
Showing results for 
Search instead for 
Did you mean: 

SFTP

pavanikoduri
Level 3
Hi,

I would like to get/post a file from sftp server, so is there any object available from blue prism? or any best method.

Thanks Pavani



------------------------------
pavani koduri
RPA Consulatant
Pearson
Europe/London
------------------------------
1 BEST ANSWER

Helpful Answers

Way ahead of you on that. I'm attaching a file - rename the extension from .txt to .bprelease.

This is built off of WinSCP and Renci SSHNet. The VBO expects the following files to reside within c:\bp (A general-use directory we have on our bots, you can change this as-needed):
-Renci.SshNet.dll
-Renci.SshNet.xml
-WinSCP.exe
-WinSCPnet.dll

Edit:
Looking back on this, I'm recalling that this was abandoned mid-development. Everything should work fine, save for the rsa 2048 stages. Those have most of the groundwork done, and just need the host key to be integrated.

Edit2:
It looks like to get the host key to work, you'll need to add the following to the sessionOptions section of the code stages
.SshHostKeyFingerprint = "ssh-rsa "+hostKey

------------------------------
Ami Barrett
Lead RPA Software Developer
Solai & Cameron
Richardson, TX
------------------------------

View answer in original post

8 REPLIES 8

GaneshRaj
Level 2
Hi

You could launch command prompt from Blueprism process. Install WinSCP on the robot VDI and pass a script to perform operations from your SFTP location.

The following link has more details about how to script SFTP operations. https://winscp.net/eng/docs/scripting

------------------------------
GANESHRAJ JEEVARAJ
Automation Developer
Aviva
Europe/London
------------------------------

Thanks, Ganeshraj..i am using the python script which is easier than this process, so I am asking the BP whether they have any integration or not? Thanks

------------------------------
pavani koduri
RPA Consulatant
Pearson
Europe/London
------------------------------

Hi Pavani,

I'm not aware of an existing SFTP integration. At least there aren't any on the DX. I have kicked around the idea of building one on top of WinSCP. Just haven't had the time.

------------------------------
Eric Wilson
Director, Partner Integrations for Digital Exchange
Blue Prism
------------------------------

Way ahead of you on that. I'm attaching a file - rename the extension from .txt to .bprelease.

This is built off of WinSCP and Renci SSHNet. The VBO expects the following files to reside within c:\bp (A general-use directory we have on our bots, you can change this as-needed):
-Renci.SshNet.dll
-Renci.SshNet.xml
-WinSCP.exe
-WinSCPnet.dll

Edit:
Looking back on this, I'm recalling that this was abandoned mid-development. Everything should work fine, save for the rsa 2048 stages. Those have most of the groundwork done, and just need the host key to be integrated.

Edit2:
It looks like to get the host key to work, you'll need to add the following to the sessionOptions section of the code stages
.SshHostKeyFingerprint = "ssh-rsa "+hostKey

------------------------------
Ami Barrett
Lead RPA Software Developer
Solai & Cameron
Richardson, TX
------------------------------

Hi!

I was developing a VBO solution for file transfer using winscp.dll and SFTP protocol and I am looking at this solution you shared. Excellent  @AmiBarrett Good Job!!

Regards



------------------------------
Jhogel Ponne
Senior RPA
Ernst & Young
America/Panama
------------------------------

Ami Barrett,

could you help me in the use of this vbo, the following message has been presented.

6799.png6800.png

Code:

Dim clsRequest As System.Net.FtpWebRequest = _
DirectCast(WebRequest.Create(FTPTargetFile), FtpWebRequest)
clsRequest.Credentials = New NetworkCredential(FTPUsername, FTPPassword)
clsRequest.Method = WebRequestMethods.Ftp.ListDirectory

Dim reader As New StreamReader(clsRequest.GetResponse().GetResponseStream())
Dim line = reader.ReadLine()
Dim lines As New DataTable

lines.Columns.Add("fileName")

Do Until line Is Nothing
lines.Rows.Add(line)
line=reader.ReadLine()
Loop

Files = lines



------------------------------
Tiago silva
------------------------------

Try removing the ftp:\\ from the address.

------------------------------
Ami Barrett
Solution Architect
Karsun Solutions
Plano TX
------------------------------

Where To find Renci.SshNet.xml .Kindly help us