Fetch wont send or receive any cookies šŸŖ

Today I think I have fixed a bug that has niggled away at me for ages. šŸŖ A severe case of ā€˜works on my machineā€™ I have some code that consumes an external API that once authenticated would then, later on, make another API call to fetch the end users recent images. This worked greatā€¦ Except for some users who reported they once logged on would not see their images. However, for the longest time,...

Continue Reading

The imported project was not found

On my Ubuntu disco dingo laptop, There was a bug affecting VS Codeā€™s IntelliSense that I had just been putting up with for a good few days. The imported project ā€œ/usr/lib/mono/xbuild/15.0/Microsoft.Common.propsā€ was not found There was no such problem on macOS or Windows however as I like to write code on my Linux daily driver laptop it became harder and harder to ignore. Itā€™s a bug that I raised over on GitHub and while the...

Continue Reading

Forcing HTTP to HTTPS redirect on IIS via Amazon Elastic Load Balancers

Today I replaced an ageing asp.net web forms web application with a new static site which for now is just a landing page with a contact form and in doing so needed to force any insecure HTTP requests to HTTPS. A bit of a gotcha was an error on the redirect and the issue was the HTTP_X_FORWARDED_PROTO header also needed to be forwarded along with the redirect. For example : <conditions logicalGrouping="MatchAny"> <add input="{HTTP_X_FORWARDED_PROTO}" pattern="^http$"...

Continue Reading

Host ASP.NET Core on Windows with IIS

A recent push to production broke an ASP.NET Core application I have running and it took me a while to find out the underlying problem. The error was 502 - Web server received an invalid response while acting as a gateway or proxy server with nothing obvious in the logs that helped me. First I published a last known good version of my application by creating a new branch in git and resetting it to...

Continue Reading

Ubuntu 18.10 and the .net framework sdk 2.2 gives a package not found error

This is something I have had to do before so I am blogging here for next time. I have just upgraded my laptop from Ubuntu 18.04 to 18.10 so that I could check out the latest Gnome desktop environment and one of my first tasks was to update the .net framework to the latest 2.2 sdk. However despite following the instructions from here: https://dotnet.microsoft.com/download/linux-package-manager/ubuntu18-04/sdk-2.2.102 wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb sudo dpkg -i packages-microsoft-prod.deb sudo add-apt-repository universe sudo...

Continue Reading