Dejan's Web Log

Server-side, client-side, code snippets, scripts, automation, best practices, proven approaches, tips & tricks...

Differences in Time Zone Formats in .NET Core on Windows and Linux host

Overcoming TimeZoneInfo load problem on different operating systems in .NET Core
 
0
Recently I was working on converting DateTime value to a different time zone because the servers are running in a different time zone than the database where data is stored. Storing DateTime values in UTC time zone is the best practice, so simple DateTime.ToUniversalTime method call solves the problem ... read more

Loading RSA key pair from PEM files in .NET Core with C#

BouncyCastle wrapper for loading RSA keys from PEM files instead of XML files
0
Recently I wrote and article about using asymmetric keys for token based authentication in ASP.NET Core. As I was setting up the RSA keys to test the demo appliation I kept running to some challanges that did not make thigs going so smooth Challenge number 1 - OpenSSL ... read more

Token based authentication and Identity framework in ASP.NET Core - Part 3

Setting up asymmetric key token based authentication in ASP.NET Core application on top of Identity Framework
 
0
Recently I wrote about setting up .NET Core Identity Framework and Token based authentication in ASP.NET Core using symmetric key signing. The downside of this approach is that both identity and resource server share the same key for signing and validating the token ... read more

Token based authentication and Identity framework in ASP.NET Core - Part 2

Setting up token based authentication in ASP.NET Core application on top of Identity Framework
 
0
In article Token based authentication and Identity framework in ASP.NET Core - Part 1 I described how to setup identity library for storing user accounts. Now we are going to setup ASP.NET Core Web API project to issue the token for authenticated users so they can access protected resources. Identity Web API instance will be separated from from the resource Web API, so we'll have eventually two and possibly in future more resource services which will all use single identity server fr authentication and issuing access tokens. ... read more

Remote PowerShell Core session to a Linux host from Windows machine

Remote sessions using OpenSSH from Windows to Linux host
 
0
Starting from January 2018, Microsft has made PowerShell Core 6, a cross-platform tool available not only to Windows users which was the case so far with previous versions, but to Linux and Mac users as well. Since it was tool for Windows only, it had it's own ways for remoting using WinRM unlike Linux operating systems which primarily rely on SSH. Windows is great for editing and development, I find it really comfortable to work on with so many tools and platform available ... read more

JavaScript

read more

Umbraco CMS

read more

.NET

read more

SQL/T-SQL

read more