Integrate Web App with Azure Virtual Network by Point-to-Site VPN

It is a common scenario that we want to use VNet Integration to enable our web app access a database or other services running on a virtual machine in an Azure virtual network. With VNet Integration, we don’t need to expose a public endpoint for applications on the virtual machine but can use the private…

1

Take Care of Thread Safe when Creating EventHubClient Object with Java SDK

Recently, I have worked on a weird azure app service issue. The app service just randomly returns 502.3 status code, and the win32 error code is 0x80072EFD. Normally speaking, for a Java web application, this is a bad gateway issue and the win32 error code means HttpPlatformHandler is not able to connect to Tomcat, because…

0

Manage Azure CDN Endpoint in Node.js

The Azure Content Delivery Network (CDN) offers a global solution for delivering high-bandwidth content that is hosted in Azure or any other location. Using the CDN, we can cache publicly available objects loaded from Azure blob storage, a web application, virtual machine, application folder, or other HTTP/HTTPS location. The major advantages of using the CDN…

0

Access Azure CosmosDB in TypeScript

Azure Cosmos DB is a globally distributed, multi-model database hosted in Azure. It provides turn-key global distribution, elastic scaling of throughput and storage worldwide, single-digit millisecond latencies at the 99th percentile, five well-defined consistency levels, and guaranteed high availability, all backed by industry-leading SLAs. Azure Cosmos DB automatically indexes data without requiring you to deal…

4

JavaScript Unit Test Intergration in VSTS Build Pipeline

VSTS supports any kinds of JavaScript test runner as long as it can be invoked via command line, we can either use Chutzpah with PhantomJS or karma with most popular browsers in its build pipeline. This article will demonstrate how to integrate karma unit test into VSTS and notice that any other test runner just…

0

How to Separate Tomcat Logging Per Instance in Azure Web App

Azure web app supports multiple instances of Java application host in Tomcat. While based on Tomcat’s default logging setting, all the instances’ log will be archived to same file, this could bring difficulty to check what’s going on in each different instance. This article is about how to separate the log files per instance. Basically,…

1

ASP.NET Core and 502 Bad Gateway Response

502 bad gateway error response is not like traditional 500 error which is mostly a code problem, this make it even difficult to troubleshoot the root cause and I also see quite a few confuse from developers that why there is 502 error in ASP.NET Core production environment. Basically, the HTTP 502 Bad Gateway server…

0

Experience Weird Access Violation? Maybe a Race Condition Problem

Recently, I am working on a native memory crash issue because of access violation. I have seen a lot of access violation which are caused by heap corruption before, while this issue looks so weird which even make me feel it could be a hardware (CPU) problem. Finally, I am able to confirm it is…

0

How to Support Windows Authentication for ASP.NET Core in IIS

When we are debugging and testing Windows Authentication based ASP.NET Core application in development environment, it is very straightforward. We can just use Windows Authentication based template to create the application without any code change. The launchSettings.json contains the following section to enable windows authentication and disable anonymous authentication. “iisSettings”: { “windowsAuthentication”: true, “anonymousAuthentication”: false,…

11

Docker Compose ASP.NET Core to Nano Image with Windows Container

In this article, I would like to demonstrate how to deploy an ASP.NET Core application with SQL Server dependency to nano server by docker. To support .NET Core in docker, Microsoft has published both of linux and windows server 2016 nano images in docker hub, you can reach them in dotnet repository. If this is…

0

How to Fix “Access to OData is disabled” when Calling Graph API

Microsoft Graph and Office 365 Unified API are widely used to make development based on Office 365, while when calling calendar related API, you may experience “Access to OData is disabled” failure shown below. client-request-id: 4812d5c0-7a5d-4416-ae8b-5f9cefa873a5 content-type: application/json cache-control: private request-id: 4812d5c0-7a5d-4416-ae8b-5f9cefa873a5 Status Code: 403 { “error”: { “code”: “ErrorAccessDenied”, “message”: “Access to OData is…

1

Debug ASP.NET Core via lldb on Ubuntu

I have been using Windbg and SOS for several years and they are really good tools to perform .Net deep debugging. With the newly released cross platform .NET Core, is there a similar way to make the same? Surely Windbg and SOS don’t apply to this scenario. Fortunately, the .NET Core team has been porting the…

1

A Look at Cookie Authentication in Katana

Katana provides cookie middleware to serialize user principal into an encrypted cookie and the cookie is used to validate the authenticated user in subsequent request. This post will take a look at Katana’s cookie authentication implementation and see the machine key’s role in this procedure. The sample used in this post is one ASP.NET MVC5…

1

Figure Out the Line of Code When PowerShell Hangs

When executing Powershell script, there could be slowness or hang issue. In order to solve this kind of problems, what can we do? Ideally, we can just add more log and run the script again to reproduce the problem. While, in some condition, the script is just running in production environment and the log is…

0

Kerberos Constrained Delegation with ASP.NET

Some security issue may involve kerberos delegation, I have to capture network monitor to check the trace. Therefore, I am going to document the step to configure constrained kerberos delegation with ASP.NET application. The demo environment is in a single contoso.com domain. There are four computers(2012R2): dc: the domain controller for contoso.com dev: the development…

0