Follow sqlserver-dba.com

Subscribe to RSS feed  Follow @jackvamvas - Twitter

*Use the Comments section for questions

SQLServer-DBA.com Links

Dba_db2_button

dba-ninja.com

SQL Server DBA Jobs

Hashicorp Vault curl for VBA

02 August,2022 by Tom Collins

Question: We have a number of  MS Access front ends using DSN connections through ODBC to a PostgreSQL database. All works fine.   There is a now a new requirement to no store the PostgreSQL ids in the applications but to store them in Hashiccorp vault. 

Based on some research , there are quite a few methods to connect to Hashicorp , extract the password and use the information for connecting. One area I'm struggling to establish an approach is with Hashicorp Vault connections from legacy code based on VBA. What's a good approach?

Answer:  A good starting point is the api-docs on libraries on  Hashicorp Vault . This details libraries maintained for a range of development libraries both Official & Community including: Go,Ruby,Ansible, C#, C+ , Clojure, Elixir, Erlang , Go, Haskell , Java , Kotlin, Node.js, PHP, Powershell, Python , R , Rust 

For VBA specifically - I'm not able to identify any libraries for Hashicorp Vault  , but there is functionality within VBA which mimics the curl equivalent. 

A curl  example 

 

curl \
    -H "X-Vault-Token: f3b09679-3001-009d-2b80-9c306ab81aa6" \
    -X GET \
    http://127.0.0.1:8200/v1/ns1/ns2/secret/foo

 

Equivalent VBA methodology could adopt the  WinHttp.WinHttpRequest.

 

Read more on Hashicorp 

 How to drop login on AWS RDS SQL Server without sysadmin using Hashicorp Vault

A simple guide to Hashicorp and SQL Server Secrets Engine


Author: Tom Collins (http://www.sqlserver-dba.com)


Share:

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment on Hashicorp Vault curl for VBA


sqlserver-dba.com | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact|Copyright & Disclaimer