Skip to content
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

Error upgrading vnc-viewer cask #170753

Open
6 tasks done
andrioli opened this issue Apr 5, 2024 · 5 comments
Open
6 tasks done

Error upgrading vnc-viewer cask #170753

andrioli opened this issue Apr 5, 2024 · 5 comments

Comments

@andrioli
Copy link

andrioli commented Apr 5, 2024

Verification

Description of issue

Error when downloading https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg from vnc-viewer version 7.10.0 Cask.

Looks that they included some cookie based protection/captcha to ensure a human in doing the download.

Open the above URL in incognito mode that the following page will appear:
image

Command that failed

brew upgrade

Output of command with --verbose --debug

==> Casks with 'auto_updates true' or 'version :latest' will not be upgraded; pass `--greedy` to upgrade them.
==> Upgrading 1 outdated package:
/usr/local/Homebrew/Library/Homebrew/brew.rb (Cask::CaskLoader::FromPathLoader): loading /usr/local/Caskroom/vnc-viewer/.metadata/7.9.0/20240126003103.154/Casks/vnc-viewer.json
vnc-viewer 7.9.0 -> 7.10.0
==> Started upgrade process for Cask vnc-viewer
==> Upgrading vnc-viewer
==> Printing caveats
==> Cask::Installer#fetch
/usr/bin/env /usr/local/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.16-109-g567386a\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 12.7.4\)\ curl/8.4.0 --header Accept-Language:\ en --retry 3 --fail --location --silent --head https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
/usr/bin/env /usr/local/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.16-109-g567386a\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 12.7.4\)\ curl/8.4.0 --header Accept-Language:\ en --retry 3 --fail --location --silent --head --request GET https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
==> Downloading https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
/usr/bin/env /usr/local/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.16-109-g567386a\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 12.7.4\)\ curl/8.4.0 --header Accept-Language:\ en --retry 3 --fail --location --silent --head https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
/usr/bin/env /usr/local/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.16-109-g567386a\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 12.7.4\)\ curl/8.4.0 --header Accept-Language:\ en --retry 3 --fail --location --silent --head --request GET https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
/usr/bin/env /usr/local/Homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.16-109-g567386a\ \(Macintosh\;\ Intel\ Mac\ OS\ X\ 12.7.4\)\ curl/8.4.0 --header Accept-Language:\ en --fail --retry 3 --remote-time --output /Users/myuser/Library/Caches/Homebrew/downloads/4fe8ac75fc4b60b321497ac24fbc42ea1f77510e2650c00907ddc13286547782--VNC-Viewer-7.10.0-MacOSX-universal.dmg.incomplete --location https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0  2111    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 405
==> Purging files for version 7.10.0 of Cask vnc-viewer
Error: vnc-viewer: Download failed on Cask 'vnc-viewer' with message: Download failed: https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg

Output of brew doctor and brew config

brew doctor is only reporting some deprecated/disabled installed casks/formulae

Here is my `brew config` output:


HOMEBREW_VERSION: 4.2.16-109-g567386a
ORIGIN: https://github.com/Homebrew/brew
HEAD: 567386a13ead16e510d228e93b0d43c1677e9d0b
Last commit: 2 hours ago
Core tap HEAD: dada5cac392850a05ae02538da3a44654ac493ee
Core tap last commit: 24 minutes ago
Core tap JSON: 05 Apr 19:18 UTC
Core cask tap HEAD: 060f29cc23ffc49f666ee2b97ce2f5225ef392af
Core cask tap last commit: 21 minutes ago
Core cask tap JSON: 05 Apr 19:18 UTC
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 4
HOMEBREW_SORBET_RUNTIME: set
Homebrew Ruby: 3.1.4 => /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/3.1.4/bin/ruby
CPU: quad-core 64-bit kabylake
Clang: 14.0.0 build 1400
Git: 2.44.0 => /usr/local/bin/git
Curl: 8.4.0 => /usr/bin/curl
macOS: 12.7.4-x86_64
CLT: 14.2.0.0.1.1668646533
Xcode: N/A


### Output of `brew tap`

```shell
homebrew/bundle
homebrew/cask
homebrew/cask-fonts
homebrew/cask-versions
homebrew/core
homebrew/services
@andrioli
Copy link
Author

andrioli commented Apr 5, 2024

Looks that they are using Amazon WAF. Since this was made on purpose from Real VNC side, there is any workaround to ignore the upgrade of this cask from my side?

@akkis
Copy link

akkis commented Apr 11, 2024

I have the same issue on my brand new macbook pro. Probably they'll fix it. The only difference is the brew tap output. Mine reads:

ddev/ddev
teamookla/speedtest

@gauravahuja
Copy link

I did the following workaround to upgrade vnc-viewer.

  1. Run brew upgrade -v
  2. Find the location where brew would have downloaded the vnc-viewer image. The filename should have the extension incomplete
  3. Manually download vnc-viewer from the url and move it to the location from the logs but without the incomplete extension.
  4. Run brew upgrade -v to finish the upgrade

In my case the location was /Users/gaurav/Library/Caches/Homebrew/downloads/4fe8ac75fc4b60b321497ac24fbc42ea1f77510e2650c00907ddc13286547782--VNC-Viewer-7.10.0-MacOSX-universal.dmg.incomplete. So I manually dowloaded and moved it to the location but without the incomplete extension

==> Upgrading vnc-viewer
==> Downloading https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg
/usr/bin/env /opt/homebrew/Library/Homebrew/shims/shared/curl --disable --cookie /dev/null --globoff --show-error --user-agent Homebrew/4.2.18\ \(Macintosh\;\ arm64\ Mac\ OS\ X\ 14.4.1\)\ curl/8.4.0 --header Accept-Language:\ en --fail --retry 3 --remote-time --output /Users/gaurav/Library/Caches/Homebrew/downloads/4fe8ac75fc4b60b321497ac24fbc42ea1f77510e2650c00907ddc13286547782--VNC-Viewer-7.10.0-MacOSX-universal.dmg.incomplete --location https://downloads.realvnc.com/download/file/viewer.files/VNC-Viewer-7.10.0-MacOSX-universal.dmg

@andrioli
Copy link
Author

I didn't found any workaround, so I uninstalled the cask and installed the application manually.

@krehel
Copy link
Member

krehel commented Apr 19, 2024

We may unfortunately have to drop this from Homebrew if the WAF is preventing normal access. Tagging @Homebrew/cask for opinions or if there's a prior art to dealing with this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants