Topic "password in log"

Author Message
tattdogg
[View user's profile]

Joined: 2016-04-22
Posts: 9
Location: Minsk, Belarus
Is there any way not to show password in logs?
Quote:
winscp> open "sftp://logn:password@127.0.0.1:22" -hostkey="ssh-rsa 2048 ..." -timeout=15
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
What log is that?
tattdogg
[View user's profile]

Joined: 2016-04-22
Posts: 9
Location: Minsk, Belarus
martin wrote:
What log is that?

Code:
session.OutputDataReceived += SessionOnOutputDataReceived;
...
private void SessionOnOutputDataReceived(object sender, OutputDataReceivedEventArgs args)
{
     Logger.Trace(args.Data);
}
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
So, it's your log file. Filter the password before writing the entry to the log.
tattdogg
[View user's profile]

Joined: 2016-04-22
Posts: 9
Location: Minsk, Belarus
martin wrote:
So, it's your log file. Filter the password before writing the entry to the log.

This is what I do right now. I just wondering if I could use some property to exclude the password from your output stream.
The password can be stolen from the memory stream that way... Is it possible to add this functionality in next versions of package?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
This request has been added to the tracker:
https://winscp.net/tracker/show_bug.cgi?id=1475

I'm sending you an email with a development version of WinSCP to the address you have used to register on this forum.
tattdogg
[View user's profile]

Joined: 2016-04-22
Posts: 9
Location: Minsk, Belarus
thank you
tattdogg
[View user's profile]

Joined: 2016-04-22
Posts: 9
Location: Minsk, Belarus
Will it work with a PrivateKeyPassphrase?
Code:
sessionOptions.PrivateKeyPassphrase = "abc";
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License