-
Notifications
You must be signed in to change notification settings - Fork 903
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
Auth cred for downloads #1021
Comments
Actually are there any tests for the helper functions? I thought there was but just looked again and couldn't find any...... |
Added comments for document generation.
right on - PR would be great! |
Add credential option to the Install-ChocolateyPackage API and pass the cred object down to the relevant web calls.
Added comments for document generation.
Added comments for document generation.
Add credential option to the Install-ChocolateyPackage API and pass the cred object down to the relevant web calls.
Added comments for document generation.
Add credential option to the Install-ChocolateyPackage API and pass the cred object down to the relevant web calls.
Added comments for document generation.
Fixed version mentioned in comment header
Add credential option to the Install-ChocolateyPackage API and pass the cred object down to the relevant web calls.
Added comments for document generation.
Add credential option to the Install-ChocolateyPackage API and pass the cred object down to the relevant web calls.
Added comments for document generation.
Updated version number of comment/header.
Removed debug used during dev
Extends the variaboue helper APIs that call Get-ChocolateyWebFile to take a authentication credential and then pass that credential to the various web calls. This allows us to download resources from webservers that require authentication. The credential eventually gets used in a System.Net.HttpWebRequest object and thus can be either a NetworkCredential or a CredentialCache object. The previous behaviour was just to use the default credentials which is generally the windows user credential, which is often unsuitable.
Extends the variaboue helper APIs that call Get-ChocolateyWebFile to take a authentication credential and then pass that credential to the various web calls. This allows us to download resources from webservers that require authentication. The credential eventually gets used in a System.Net.HttpWebRequest object and thus can be either a NetworkCredential or a CredentialCache object. The previous behaviour was just to use the default credentials which is generally the windows user credential, which is often unsuitable.
Extends the variaboue helper APIs that call Get-ChocolateyWebFile to take a authentication credential and then pass that credential to the various web calls. This allows us to download resources from webservers that require authentication. The credential eventually gets used in a System.Net.HttpWebRequest object and thus can be either a NetworkCredential or a CredentialCache object. The previous behaviour was just to use the default credentials which is generally the windows user credential, which is often unsuitable.
This has been part of Hacktoberfest for a year? I'm confused. |
@ryanwebjackson It was from last year. Because the PR was already opened the Hacktoberfest tag was not removed. |
Hi, The PR for this issue has been closed due to inactivity over several years. Would bei great if someone can answer this. Thanks! |
The issue is still open so can be used for a new PR. |
Download-relevant Chocolatey Helper functions are extended with a "Credentials" parameter to enable downloads over HTTP(S) that require authentication. The parameter is then attached to the Microsoft System.Net.HttpWebRequest object to perform the download. Before this change it was not possible to pass credentials for downloads
Very simply, when I call Install-ChocolateyPackage with a URL to download, I'd like to also pass to it a System.Net.ICredentials to the call so that I can use a download URL rather requires authentication.
The change is dead simple, just pass the credential object down the call chain until you hand it off to the System.Net.HttpWebRequest object. My question is what have I missed?
This is the conversation I had about it some time ago with Rob:
Consequently I've forked and committed my changes to https://github.com/Spitzbub/choco/tree/authcred, though I'm still working on them (adding documentation and unit tests)
The text was updated successfully, but these errors were encountered: