Azure AD authentication provider for AWS Athena

Official AWS Athena JDBC driver supports authentication via Windows Active Directory by using ADFS 3.0. Unfortunately, at the time of writing, it does not support Azure AD.

By looking at the official JDBC driver, we can see that ADFS authentication provider is relatively simple.
It orchestrates forms based authentication with ADFS in order to get the SAML token required for authorization with AWS.

Since I prefer to use the service vs maintaining ADFS on premise, I created a similar authentication provider for Azure AD. You can find it on GitHub.

It has been tested on my environments and it looks to be working as expected.

If Microsoft decides to change some form input ids, things might break. If you find it boken, try opening an Issue.
I will do my best to keep it alive until AWS starts supporting the scenario.

Obviously, I'm assuming that Azure AD is set up as identity provider for your AWS account.

Hope it works for you to!