-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Passing PSCredentials to New-SFClient #1
Comments
Committed new version (1.1) that addresses this issue. |
Hi, PS C:\WINDOWS\system32> $sfCred = Get-Credential PS C:\WINDOWS\system32> $sfLogin = New-SfClient -Name "$workDir$sfShortAccountName" -Credential $sfCred
Mauricio |
Hi Mauricio, bad argument handling in our part: when using -Credentials, you have to provide -Account as well. -Account is the subdomain - i.e., the prefix for your sharefile account. If you use "acme.sharefile.com" as your web site, then "acme" is the subdomain. I've just tested it in my account using 1.3, and it reproduces your issue when -Account is not provided; but works when it does. Hopefully that'll work for you as well! Thanks! |
Hi Juliano, Ouch… seeing it right now in get-help new-sfclient on example two Thank you on your quick reaction! From: julianomaldaner [mailto:notifications@github.com] Hi Mauricio, bad argument handling in our part: when using -Credentials, you have to provide -Account as well. -Account is the subdomain - i.e., the prefix for your sharefile account. If you use "acme.sharefile.com" as your web site, then "acme" is the subdomain. I've just tested it in my account using 1.3, and it reproduces your issue when -Account is not provided; but works when it does. Hopefully that'll work for you as well! Thanks! — |
* commit '497ad696bc574f26ac2e4af90a07311d246c1508': Make .gitignore work Correctly dispose of the platform file info object Upgrade Client SDK
Hi,
following code does not work
$sfUsername = $Lab."Login Name"
$sfPassword = convertto-securestring -String $Lab.Password -AsPlainText -Force
$sfCred = New-Object -typename System.Management.Automation.PSCredential -argumentlist $sfUsername, $sfpassword
$sfLogin = New-SfClient -Account $Lab.Account.Substring(0,9) -Credential $SFcred
looks like New-SFClient does not accept the PSCredentials object.
Even if working with
$SFCred = Get-Credentials
it does display the Webform for logging in
FYI:
$Lab is a CSV I'm importing as I need to work with 20 Accounts
Cheers,
Mauricio
The text was updated successfully, but these errors were encountered: