When installing Chocolatey: "The remote server returned an error: (403) Forbidden"
Asked Answered
A

2

5

enter image description here

I am not sure what this problem says. Please Help me to figure out this issue.. Thanks in Advance..

Acid answered 12/12, 2017 at 14:43 Comment(0)
P
6

(403) Forbidden Issue

From the error text, it states "(403) Forbidden" is the issue. Fortunately for you, that particular issue is covered directly in the FAQs (https://docs.chocolatey.org/en-us/faqs) of the install page, which links you over to Troubleshooting (https://chocolatey.org/docs/troubleshooting#im-getting-a-403-unauthorized-issue-attempting-to-install-chocolatey).

Details

For full answer clarity, linked information above will be provided here, but be sure to check the links above for the most correct and up to date answer.

It could be one of a few things:

  • You have a proxy that you need to configure
  • It is being blocked in your organization
  • We broke something (this is the least likely reason, everyone would be running into this issue and it would be fixed immediately)
  • CloudFlare has blocked your IP due to reasons
  • The Chocolatey Community Team may have blocked access due to abuse (many package installs over 30 days) see excessive use for details

You can use a tool like Fiddler (choco install for this would not be helpful in your case) to help determine what is going on.

How To Fix

Go to Project Honeypot and put in your IP address - http://www.projecthoneypot.org/search_ip.php. Check to see if your IP is flagged here, this is what Cloudflare uses to determine if you are banned (typically it means you have malware that is sending spam emails).

If you determine it is CloudFlare blocking your IP (which is the issue 98% of the time), we may be able to get you whitelisted for Chocolatey:

  • Go to https://chocolatey.org/contact (NOTE: If you are completely blocked from accessing the site, contact Chocolatey folks through Gitter instead)
  • Select "Website" in "Send message to" drop down
  • Let us know what's going on along with your IP address so we can unblock you.
  • Oh, and be sure to run some antivirus scans and remove any found malware (and maybe find a better antivirus scanner).

Once this has been completed, you should have access to install Chocolatey and/or packages from the community repository.

Photolysis answered 12/12, 2017 at 18:12 Comment(5)
Thanks a lot.. But the troubleshooting page is not helpful in my case.Acid
All of this information is included on the troubleshooting case, and we've updated it to look more what you see here. In your case specifically, you still need to reach out to "Website" on the contact form with your IP address so this can get resolved.Photolysis
One case in FAQ is that the dl site being blocked by my organization, so is it possible for choco install to show where exactly it is downloading the package from, ferventcoder? I skimmed through its options, and the only thing that vaguely related to it is --debug, but that's not helping for this case.Pollypollyanna
@Pollypollyanna Chocolatey by default will show you already where it is downloading binaries/installers from if they are not inside the package, all you need to do is view the script when the option comes up (provided you haven't used -y).Photolysis
@Pollypollyanna the Chocolatey log file ($env:ChocolateyInstall\logs) is very detailed and will also contain that information. In case you did actually mean nupkg file when you stated "package" (that's the only thing we associate with that term for ease of understanding), then that will be the package source, which is also in the logs.Photolysis
P
1

One case in FAQ is that the dl site being blocked by my organization, and it turns out to be true:

enter image description here

zscaler is being "helpful" again, and thinking nircmd is Trojan this time; last time it was Groovy that was blocked for me, sigh...

Pollypollyanna answered 21/6, 2021 at 17:43 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.