Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: S3 Bucket connection via .net c#

I assume that your access key does not have permissions to list buckets, right?
plasticide

S3 Bucket connection via .net c#

I've successfully enabled a connection to an S3 bucket using WinSCP.exe.
However I cannot get the c# version to work.
I am using WinSCP Version 5.15.2. C# Visual Studio 2013.
I generated the code automatically to enable use in a c# application.
SessionOptions sessionOptions = new SessionOptions
{
Protocol = Protocol.S3,
HostName = "s3.eu-west-1.amazonaws.com",
UserName = "XXXX",
Password = "XXXX",
};

This doesn't generate anything to do with the remote directory bucket?

Then when the session connection is attempted I get the following error message generated.
Access Denied
Extra Details: RequestId: 556B925701BC1E08, HostId: x3CHiVnicskSuUfMbiE3QMpoP5OTyI14CXTYDWM4xxxx/a5GCruowQPdP6DuDH31w6zRoidxxxx=
Connection failed.
at WinSCP.SessionLogReader.Read(LogReadFlags flags)
at WinSCP.ElementLogReader.Read(LogReadFlags flags)
at WinSCP.SessionElementLogReader.Read(LogReadFlags flags)
at WinSCP.CustomLogReader.TryWaitForNonEmptyElement(String localName, LogReadFlags flags)
at WinSCP.CustomLogReader.WaitForNonEmptyElement(String localName, LogReadFlags flags)
at WinSCP.CustomLogReader.WaitForNonEmptyElementAndCreateLogReader(String localName, LogReadFlags flags)
at WinSCP.CustomLogReader.WaitForGroupAndCreateLogReader()
at WinSCP.Session.WaitForGroup()
at WinSCP.Session.Open(SessionOptions sessionOptions)
at RealTimeInformation.Nre.NreScheduledData.Service.GetDirectoryListing() in c:\Dev\xxx.cs:line 89
2019-06-25 15:03:38.4717,Info,info.Data.Service.Start,No files could be downloaded - connection failed.,