Skip to main content

Snowflake Storage Connection - Key Pair Authentication Guide

Write! supports Key Pair authentication for Snowflake Storage Connections, providing a more secure alternative to traditional username and password authentication. This method uses RSA private key authentication to establish secure connections with your Snowflake instance.

Key Pair Authentication Pre-Configuration

Before you start configuring Key Pair authentication for Write!, do the following:

  • Generate an RSA key pair (public and private keys).

  • Configure the public key in your Snowflake user account.

  • Make sure that your private key is securely stored.

For more details regarding pre-configuration, see Snowflake documentation here.

Key Pair Authentication Configuration

To configure the Snowflake Key Pair Authentication for Write!, you need to complete configuration divided into three steps:

  1. Select authentication method.

  2. Configure private key.

  3. Test your connection.

Select Authentication Method

When creating or editing a Snowflake Storage Connection, you can select the authentication method by following this instruction:

  1. Navigate to WMC > Management Area > Storage Connections.

  2. Press the + New Connection button to create a new connection or edit an existing storage connection with a Snowflake Connector.

  3. After configuring the connection, locate the Authentication dropdown field.

  4. Select one of the following options:

    • Username / Password - Traditional authentication method.

    • Key Pair - RSA private key authentication (recommended for enhanced security).

When you select the Key Pair option, you can proceed to configuring private key.

Configure Private Key

After selecting the Key Pair option as the authentication method, two additional fields appear:

  • Private Key (Required).

  • Private Key Passphrase (Optional).

You need to enter your RSA Private Key in PEM format. The key must:

  • Begin with -----BEGIN PRIVATE KEY----- or -----BEGIN RSA PRIVATE KEY-----.

  • End with -----END PRIVATE KEY----- or -----END RSA PRIVATE KEY-----.

  • Include the complete key content with headers and footers.

  • Preserve all line breaks.

Copy

Example

-----BEGIN PRIVATE KEY-----
MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQC...
[additional key content with line breaks preserved]
...
-----END PRIVATE KEY-----

The Private Key Passphrase is needed only if your private key is encrypted. Leave the field empty if you’re using an unencrypted private key.

Test Your Connection

After entering your authentication details:

  1. Click the Test Connection button.

  2. The system will validate that your credentials can successfully authenticate with Snowflake.

  3. If successful, Save your Storage Connection configuration.

Important Security Considerations

For maximum security follow the below rules:

  • Keep your private key secure: Never share your private key or store it in unsecured locations,

  • Use encrypted keys when possible: Consider encrypting your private key with a passphrase for additional security,

  • Limit key access: Ensure only authorized personnel have access to private keys,

Editing Existing Connections

When editing a Storage Connection that already uses Key Pair authentication:

  • The Private Key field displays Use server side saved key! as a placeholder.

  • You aren’t required to re-enter the private key when modifying other connection properties (for example, database name, warehouse).

  • Only enter a new private key if you need to update the authentication credentials.

Best Practices

These are the best practices insightsoftware recommends you apply when you use the Key Pair Authentication feature.

  • Rotate keys regularly: Implement a key rotation schedule for enhanced security.

  • Use separate keys for different environments: Don't share keys between development, staging, and production.

  • Monitor key usage: Track authentication attempts and access patterns.

  • Document key ownership: Maintain records of which keys are assigned to which users and systems.

Common Issues

In this section, you can find information on what to do when you face common issues related to Key Pair authentication.

Issue: Authentication Failed

  • Verify the private key format matches the requirements above.

  • Ensure the corresponding public key is properly configured in Snowflake.

  • Check that the private key passphrase is correct (if applicable).

Issue: Invalid Key Format

  • Confirm the key includes proper headers and footers.

  • Ensure all line breaks are preserved when pasting the key.

  • Verify you're using an RSA key in PEM format.

Issue: Connection Timeout

  • Verify your Snowflake instance is accessible.

  • Check network connectivity and firewall settings.

  • Ensure the Snowflake user account is active and has appropriate permissions.

Getting Help

If you continue to experience issues:

  1. Verify your key pair configuration in Snowflake.

  2. Test the connection using Snowflake's native tools.

  3. If you still have issues after performing instructions from steps 1 and 2, contact your system administrator or support team for assistance.

Additional Resources

To successfully complete the configuration of Key Pair Authentication for Snowflake Storage Connections, use the following resources:

Was this article helpful?

We're sorry to hear that.