Secure Your Java App with OAuth 2.0 in 5 Minutes

Brian Demers

Hey Naresh!
I’ve never used Snowflake, but based on the docs: https://docs.snowflake.com/…
It looks like it’s just an OAuth 2.0 Resource Server, which we have a lot of examples of.

The easiest way is probably setup Spring Cloud gateway, for testing.
This post sets up Spring Cloud Gateway https://developer.okta.com/… (instead of the legacy application, you would just point to your Snowflake db app)

However, I’m guessing your DB access should be a service account vs the end user. My recommendations for that is likely framework specific. For example if you were using Spring Boot and making requests with a RestTemplate or WebClient, you could just inject an authorizied client: https://www.youtube.com/wat…

Can you give us a few more details on your app and the frameworks you are using?