Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Teach Snowflake Engine to properly support _pwd query params #575

Open
theory opened this issue Apr 23, 2021 · 1 comment
Open

Teach Snowflake Engine to properly support _pwd query params #575

theory opened this issue Apr 23, 2021 · 1 comment
Labels

Comments

@theory
Copy link
Collaborator

theory commented Apr 23, 2021

This works for the SNOWSQL client, however the string needs to be in the Engine string or it returns the error: "cannot marshal private file". Additionally, sqitch is printing the passphrase in plaintext in its logs. Example:

$ sqitch deploy --registry ${REGISTRY} --verify -s ENV=$ENV "db:snowflake://${SNOWSQL_ACCOUNT}.snowflakecomputing.com/sqitch?Driver=Snowflake;warehouse=Deployment;authenticator=SNOWFLAKE_JWT;uid=SVC_DEPLOY;priv_key_file=/ssh/snowflake_svc_deploy.p8;role=ACCOUNTADMIN;priv_key_file_pwd=${PASSPHRASE};database=SQITCH"
Deploying changes to db:snowflake://zea07112.us-east-1.snowflakecomputing.com/sqitch?Driver=Snowflake;warehouse=Deployment;authenticator=SNOWFLAKE_JWT;uid=SVC_DEPLOY;priv_key_file=/ssh/snowflake_svc_deploy.p8;role=ACCOUNTADMIN;priv_key_file_pwd=my%20secret%20passphrase;database=SQITCH
  + AddDataEngETLRole ...... ok
  + AddDataEngETLWarehose .. ok

Originally posted by @jperkelens in #318 (comment)

@theory theory added the engine label Apr 23, 2021
@theory
Copy link
Collaborator Author

theory commented Apr 23, 2021

We should teach the Snowflake engine to redact any _pwd param values in target URI displays, and ideally support reading them from the SnowSQL config file and environment variables so that they don't have to be in the URI at all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant