Skip to content

Setup Xamarin behind Firewall

Hardik Mistry edited this page Nov 15, 2018 · 1 revision

Trying to install Xamarin behind a firewall or an enterprise network

Visual Studio does not provision a way to enable proxy setting before or while running the installer

NOTE: For some of you this tip may be unauthorised and may violate your company's enterprise guide-lines as an employee, we advise you to seek appropriate approvals from your company's IT team before you proceed.

This will affect those who cannot use but the company's wire/wi-fi connection which will filter packets before they come to your PC or Laptop, if you have a choice to use personal internet connection, chances are you'll never need to do this, however on regular occasions, you'll want to update Xamarin or other parts of Visual Studio and if you are connected via your company's wire/wi-fi connection, you'll need to bypass the proxy somehow.

Due to this limitation, even if you are running the installer with administrative privileges, 3rd party SDKs and additional components required to successfully code, build and run Xamarin apps will not be installed, essentially, you will be able to install core (regular Visual Studio) Visual Studio with convential project types etc but 3rd party SDKs etc wont be installed due to which you will not be able to code, build and run Xamarin apps.

Things you'll need

  • An account with administrative rights (your own account or an alternative account)

  • Your proxy configuration, in most of the cases it will be: ip-address:port-number (example: 192.x.x.x:4040)

  • Fiddler (A free web proxy and debugging tool, if you are web developer, chances are you are already using it, if not, download and install your free copy here: http://www.telerik.com/download/fiddler)

  • Visual Studio installer (.iso or .exe to start the Visual Studio installer) (download your copy here: https://www.visualstudio.com/downloads/)

Steps

  • Install Fiddler and start it (in most of the cases it will start once it gets installed, however you may need to start it by clicking the start button and searching for Fiddler and then selecting the relevant icon)

    • When you start Fiddler first time, you may get a prompt with buttons Yes, No or Cancel, trust us, as of now simply select Cancel button
  • Select Tools menu

    • Select Options option

      • Select Gateway tab

        • Select Manual Proxy Configuration radio button

          • Enter your proxy ip-address:port in the first text box and click Ok button
  • Select Rules menu

    • Select Automatically Authenticate option (enabling this option, will stop asking for your username and password every time you run Fiddler)
  • Now minimise Fiddler and run Visual Studio installer

  • Install as usual (You may refer to this guide to help ensure you select the right options: https://github.com/MumbaiHackerspace/Visage/wiki/Setup-Xamarin-on-Windows

  • If done just right, you should be able to install Xamarin and related SDKs on a machine behind firewall or enterprise network

  • If you face any challenges, we suggest you to file an issue.